Class SplashScreen

java.lang.Object
nl.colorize.multimedialib.scene.SplashScreen
All Implemented Interfaces:
Scene

public class SplashScreen extends Object implements Scene
Displays a loading screen with a progress bar while the renderer is loading media files asynchronously. The loading screen is configurable, but is limited to shapes and colors. Images and fonts cannot be used, because they require media files themselves. Once all media assets have been loaded, the splash screen will automatically transition to the next scene.
  • Constructor Details

  • Method Details

    • start

      public void start(SceneContext context)
      Description copied from interface: Scene
      Initialization logic that should be performed when the scene is started. Note that this method is called *every* time the scene is started, not just the first time.

      This method is optional, the default implementation does nothing.

      Specified by:
      start in interface Scene
    • attachProgressBar

      protected void attachProgressBar(SceneContext context)
    • update

      public void update(SceneContext context, float deltaTime)
      Description copied from interface: Scene
      Called during every frame update for as long as the scene is active. deltaTime indicates the elapsed time since the last frame, in seconds.
      Specified by:
      update in interface Scene
    • getMediaAssets

      public MediaAssetStore getMediaAssets()
    • getNextScene

      public Supplier<Scene> getNextScene()
    • getLoading

      public List<LoadStatus> getLoading()
    • getDelay

      public Timer getDelay()
    • getBarWidth

      public int getBarWidth()
    • getBarHeight

      public int getBarHeight()
    • getScreenBackgroundColor

      public ColorRGB getScreenBackgroundColor()
    • getBarBorderColor

      public ColorRGB getBarBorderColor()
    • getBarBorderStroke

      public int getBarBorderStroke()
    • getBarBackgroundColor

      public ColorRGB getBarBackgroundColor()
    • getBarBackgroundAlpha

      public int getBarBackgroundAlpha()
    • getBarForegroundColor

      public ColorRGB getBarForegroundColor()
    • setDelay

      public void setDelay(Timer delay)
    • setBarWidth

      public void setBarWidth(int barWidth)
    • setBarHeight

      public void setBarHeight(int barHeight)
    • setScreenBackgroundColor

      public void setScreenBackgroundColor(ColorRGB screenBackgroundColor)
    • setBarBorderColor

      public void setBarBorderColor(ColorRGB barBorderColor)
    • setBarBorderStroke

      public void setBarBorderStroke(int barBorderStroke)
    • setBarBackgroundColor

      public void setBarBackgroundColor(ColorRGB barBackgroundColor)
    • setBarBackgroundAlpha

      public void setBarBackgroundAlpha(int barBackgroundAlpha)
    • setBarForegroundColor

      public void setBarForegroundColor(ColorRGB barForegroundColor)