Class MirrorSource

java.lang.Object
gaiasky.util.gdx.model.gltf.scene3d.scene.MirrorSource
All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable

public class MirrorSource extends Object implements com.badlogic.gdx.utils.Disposable
  • Field Details

    • fbo

      protected com.badlogic.gdx.graphics.glutils.FrameBuffer fbo
    • clipScene

      public boolean clipScene
      enable/disable scene clipping. When enabled, objects behind mirror are not rendered.
    • mirrorAttribute

      protected final MirrorSourceAttribute mirrorAttribute
  • Constructor Details

    • MirrorSource

      public MirrorSource()
  • Method Details

    • createFrameBuffer

      protected com.badlogic.gdx.graphics.glutils.FrameBuffer createFrameBuffer(int width, int height)
    • setSize

      public void setSize(int width, int height)
      Set mirror source frame buffer size (usually the same as the final render resolution).
      Parameters:
      width - when set to zero, default back buffer width will be used.
      height - when set to zero, default back buffer height will be used.
    • setPlane

      public void setPlane(float nx, float ny, float nz, float d)
      set mirror plane
      Parameters:
      nx - normal x
      ny - normal y
      nz - normal z
      d - plan origin
    • set

      public MirrorSource set(float nx, float ny, float nz, float d, boolean clipScene)
      set mirror source
      Parameters:
      nx - normal x
      ny - normal y
      nz - normal z
      d - plan origin
      clipScene - if objects behind the plane should be clipped.
    • begin

      public void begin(com.badlogic.gdx.graphics.Camera camera, Environment environment, SceneSkybox skyBox)
    • end

      public void end()
    • dispose

      public void dispose()
      Specified by:
      dispose in interface com.badlogic.gdx.utils.Disposable