Enum Class RenderQueue.Bucket

java.lang.Object
java.lang.Enum<RenderQueue.Bucket>
com.jme3.renderer.queue.RenderQueue.Bucket
All Implemented Interfaces:
Serializable, Comparable<RenderQueue.Bucket>, Constable
Enclosing class:
RenderQueue

public static enum RenderQueue.Bucket extends Enum<RenderQueue.Bucket>
The render queue Bucket specifies the bucket to which the spatial will be placed when rendered.

The behavior of the rendering will differ depending on which bucket the spatial is placed. A spatial's queue bucket can be set via Spatial.setQueueBucket(com.jme3.renderer.queue.RenderQueue.Bucket).

  • Enum Constant Details

    • Opaque

      public static final RenderQueue.Bucket Opaque
      The renderer will try to find the optimal order for rendering all objects using this mode. You should use this mode for most normal objects, except transparent ones, as it could give a nice performance boost to your application.
    • Transparent

      public static final RenderQueue.Bucket Transparent
      This is the mode you should use for object with transparency in them. It will ensure the objects furthest away are rendered first. That ensures when another transparent object is drawn on top of previously drawn objects, you can see those (and the object drawn using Opaque) through the transparent parts of the newly drawn object.
    • Sky

      public static final RenderQueue.Bucket Sky
      A special mode used for rendering really far away, flat objects - e.g. skies. In this mode, the depth is set to infinity so spatials in this bucket will appear behind everything, the downside to this bucket is that 3D objects will not be rendered correctly due to lack of depth testing.
    • Translucent

      public static final RenderQueue.Bucket Translucent
      A special mode used for rendering transparent objects that should not be affected by SceneProcessor. Generally this would contain translucent objects, and also objects that do not write to the depth buffer such as particle emitters.
    • Gui

      public static final RenderQueue.Bucket Gui
      This is a special mode, for drawing 2D object without perspective (such as GUI or HUD parts). The spatial's world coordinate system has the range of [0, 0, -1] to [Width, Height, 1] where Width/Height is the resolution of the screen rendered to. Any spatials outside of that range are culled.
    • Inherit

      public static final RenderQueue.Bucket Inherit
      A special mode, that will ensure that this spatial uses the same mode as the parent Node does.
  • Method Details

    • values

      public static RenderQueue.Bucket[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static RenderQueue.Bucket valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null