Class OwnCubemap

java.lang.Object
com.badlogic.gdx.graphics.GLTexture
gaiasky.util.gdx.OwnCubemap
All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable

public class OwnCubemap extends com.badlogic.gdx.graphics.GLTexture
  • Nested Class Summary Link icon

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
    Enum to identify each side of a Cubemap
  • Field Summary Link icon

    Fields
    Modifier and Type
    Field
    Description
    protected com.badlogic.gdx.graphics.CubemapData
     

    Fields inherited from class com.badlogic.gdx.graphics.GLTexture Link icon

    anisotropicFilterLevel, glHandle, glTarget, magFilter, minFilter, uWrap, vWrap
  • Constructor Summary Link icon

    Constructors
    Constructor
    Description
    OwnCubemap(int width, int height, int depth, com.badlogic.gdx.graphics.Pixmap.Format format)
    Construct a Cubemap with Pixmaps for each side of the specified size.
    OwnCubemap(com.badlogic.gdx.files.FileHandle positiveX, com.badlogic.gdx.files.FileHandle negativeX, com.badlogic.gdx.files.FileHandle positiveY, com.badlogic.gdx.files.FileHandle negativeY, com.badlogic.gdx.files.FileHandle positiveZ, com.badlogic.gdx.files.FileHandle negativeZ)
    Construct a Cubemap with the specified texture files for the sides, does not generate mipmaps.
    OwnCubemap(com.badlogic.gdx.files.FileHandle positiveX, com.badlogic.gdx.files.FileHandle negativeX, com.badlogic.gdx.files.FileHandle positiveY, com.badlogic.gdx.files.FileHandle negativeY, com.badlogic.gdx.files.FileHandle positiveZ, com.badlogic.gdx.files.FileHandle negativeZ, boolean useMipMaps)
    Construct a Cubemap with the specified texture files for the sides, optionally generating mipmaps.
    OwnCubemap(com.badlogic.gdx.graphics.CubemapData data)
    Construct a Cubemap based on the given CubemapData.
    OwnCubemap(com.badlogic.gdx.graphics.CubemapData data, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
     
    OwnCubemap(com.badlogic.gdx.graphics.Pixmap positiveX, com.badlogic.gdx.graphics.Pixmap negativeX, com.badlogic.gdx.graphics.Pixmap positiveY, com.badlogic.gdx.graphics.Pixmap negativeY, com.badlogic.gdx.graphics.Pixmap positiveZ, com.badlogic.gdx.graphics.Pixmap negativeZ)
    Construct a Cubemap with the specified Pixmaps for the sides, does not generate mipmaps.
    OwnCubemap(com.badlogic.gdx.graphics.Pixmap positiveX, com.badlogic.gdx.graphics.Pixmap negativeX, com.badlogic.gdx.graphics.Pixmap positiveY, com.badlogic.gdx.graphics.Pixmap negativeY, com.badlogic.gdx.graphics.Pixmap positiveZ, com.badlogic.gdx.graphics.Pixmap negativeZ, boolean useMipMaps)
    Construct a Cubemap with the specified Pixmaps for the sides, optionally generating mipmaps.
    OwnCubemap(com.badlogic.gdx.graphics.TextureData positiveX, com.badlogic.gdx.graphics.TextureData negativeX, com.badlogic.gdx.graphics.TextureData positiveY, com.badlogic.gdx.graphics.TextureData negativeY, com.badlogic.gdx.graphics.TextureData positiveZ, com.badlogic.gdx.graphics.TextureData negativeZ)
    Construct a Cubemap with the specified TextureData's for the sides
    OwnCubemap(com.badlogic.gdx.graphics.TextureData positiveX, com.badlogic.gdx.graphics.TextureData negativeX, com.badlogic.gdx.graphics.TextureData positiveY, com.badlogic.gdx.graphics.TextureData negativeY, com.badlogic.gdx.graphics.TextureData positiveZ, com.badlogic.gdx.graphics.TextureData negativeZ, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
     
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    static void
    clearAllCubemaps(com.badlogic.gdx.Application app)
    Clears all managed cubemaps.
    void
    Disposes all resources associated with the cubemap
    com.badlogic.gdx.graphics.CubemapData
     
    int
     
    int
     
    static String
     
    static int
     
    int
     
    static void
    invalidateAllCubemaps(com.badlogic.gdx.Application app)
    Invalidate all managed cubemaps.
    boolean
     
    void
    load(com.badlogic.gdx.graphics.CubemapData data)
    Sets the sides of this cubemap to the specified CubemapData.
    void
    load(com.badlogic.gdx.graphics.CubemapData data, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
     
    protected void
     
    static void
    setAssetManager(com.badlogic.gdx.assets.AssetManager manager)
    Sets the AssetManager.

    Methods inherited from class com.badlogic.gdx.graphics.GLTexture Link icon

    bind, bind, delete, getAnisotropicFilter, getMagFilter, getMaxAnisotropicFilterLevel, getMinFilter, getTextureObjectHandle, getUWrap, getVWrap, setAnisotropicFilter, setFilter, setWrap, unsafeSetAnisotropicFilter, unsafeSetAnisotropicFilter, unsafeSetFilter, unsafeSetFilter, unsafeSetWrap, unsafeSetWrap, uploadImageData, uploadImageData

    Methods inherited from class java.lang.Object Link icon

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details Link icon

    • data Link icon

      protected com.badlogic.gdx.graphics.CubemapData data
  • Constructor Details Link icon

    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.CubemapData data)
      Construct a Cubemap based on the given CubemapData.
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.CubemapData data, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.files.FileHandle positiveX, com.badlogic.gdx.files.FileHandle negativeX, com.badlogic.gdx.files.FileHandle positiveY, com.badlogic.gdx.files.FileHandle negativeY, com.badlogic.gdx.files.FileHandle positiveZ, com.badlogic.gdx.files.FileHandle negativeZ)
      Construct a Cubemap with the specified texture files for the sides, does not generate mipmaps.
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.files.FileHandle positiveX, com.badlogic.gdx.files.FileHandle negativeX, com.badlogic.gdx.files.FileHandle positiveY, com.badlogic.gdx.files.FileHandle negativeY, com.badlogic.gdx.files.FileHandle positiveZ, com.badlogic.gdx.files.FileHandle negativeZ, boolean useMipMaps)
      Construct a Cubemap with the specified texture files for the sides, optionally generating mipmaps.
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.Pixmap positiveX, com.badlogic.gdx.graphics.Pixmap negativeX, com.badlogic.gdx.graphics.Pixmap positiveY, com.badlogic.gdx.graphics.Pixmap negativeY, com.badlogic.gdx.graphics.Pixmap positiveZ, com.badlogic.gdx.graphics.Pixmap negativeZ)
      Construct a Cubemap with the specified Pixmaps for the sides, does not generate mipmaps.
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.Pixmap positiveX, com.badlogic.gdx.graphics.Pixmap negativeX, com.badlogic.gdx.graphics.Pixmap positiveY, com.badlogic.gdx.graphics.Pixmap negativeY, com.badlogic.gdx.graphics.Pixmap positiveZ, com.badlogic.gdx.graphics.Pixmap negativeZ, boolean useMipMaps)
      Construct a Cubemap with the specified Pixmaps for the sides, optionally generating mipmaps.
    • OwnCubemap Link icon

      public OwnCubemap(int width, int height, int depth, com.badlogic.gdx.graphics.Pixmap.Format format)
      Construct a Cubemap with Pixmaps for each side of the specified size.
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.TextureData positiveX, com.badlogic.gdx.graphics.TextureData negativeX, com.badlogic.gdx.graphics.TextureData positiveY, com.badlogic.gdx.graphics.TextureData negativeY, com.badlogic.gdx.graphics.TextureData positiveZ, com.badlogic.gdx.graphics.TextureData negativeZ)
      Construct a Cubemap with the specified TextureData's for the sides
    • OwnCubemap Link icon

      public OwnCubemap(com.badlogic.gdx.graphics.TextureData positiveX, com.badlogic.gdx.graphics.TextureData negativeX, com.badlogic.gdx.graphics.TextureData positiveY, com.badlogic.gdx.graphics.TextureData negativeY, com.badlogic.gdx.graphics.TextureData positiveZ, com.badlogic.gdx.graphics.TextureData negativeZ, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
  • Method Details Link icon

    • clearAllCubemaps Link icon

      public static void clearAllCubemaps(com.badlogic.gdx.Application app)
      Clears all managed cubemaps. This is an internal method. Do not use it!
    • invalidateAllCubemaps Link icon

      public static void invalidateAllCubemaps(com.badlogic.gdx.Application app)
      Invalidate all managed cubemaps. This is an internal method. Do not use it!
    • setAssetManager Link icon

      public static void setAssetManager(com.badlogic.gdx.assets.AssetManager manager)
      Sets the AssetManager. When the context is lost, cubemaps managed by the asset manager are reloaded by the manager on a separate thread (provided that a suitable AssetLoader is registered with the manager). Cubemaps not managed by the AssetManager are reloaded via the usual means on the rendering thread.
      Parameters:
      manager - the asset manager.
    • getManagedStatus Link icon

      public static String getManagedStatus()
    • getNumManagedCubemaps Link icon

      public static int getNumManagedCubemaps()
      Returns:
      the number of managed cubemaps currently loaded
    • load Link icon

      public void load(com.badlogic.gdx.graphics.CubemapData data)
      Sets the sides of this cubemap to the specified CubemapData.
    • load Link icon

      public void load(com.badlogic.gdx.graphics.CubemapData data, com.badlogic.gdx.graphics.Texture.TextureFilter minFilter, com.badlogic.gdx.graphics.Texture.TextureFilter magFilter)
    • getCubemapData Link icon

      public com.badlogic.gdx.graphics.CubemapData getCubemapData()
    • isManaged Link icon

      public boolean isManaged()
      Specified by:
      isManaged in class com.badlogic.gdx.graphics.GLTexture
    • reload Link icon

      protected void reload()
      Specified by:
      reload in class com.badlogic.gdx.graphics.GLTexture
    • getWidth Link icon

      public int getWidth()
      Specified by:
      getWidth in class com.badlogic.gdx.graphics.GLTexture
    • getHeight Link icon

      public int getHeight()
      Specified by:
      getHeight in class com.badlogic.gdx.graphics.GLTexture
    • getDepth Link icon

      public int getDepth()
      Specified by:
      getDepth in class com.badlogic.gdx.graphics.GLTexture
    • dispose Link icon

      public void dispose()
      Disposes all resources associated with the cubemap
      Specified by:
      dispose in interface com.badlogic.gdx.utils.Disposable
      Overrides:
      dispose in class com.badlogic.gdx.graphics.GLTexture