Class DirectionalShadowLight
java.lang.Object
com.badlogic.gdx.graphics.g3d.environment.BaseLight<com.badlogic.gdx.graphics.g3d.environment.DirectionalLight>
com.badlogic.gdx.graphics.g3d.environment.DirectionalLight
gaiasky.util.gdx.model.gltf.scene3d.lights.DirectionalLightEx
gaiasky.util.gdx.model.gltf.scene3d.lights.DirectionalShadowLight
- All Implemented Interfaces:
com.badlogic.gdx.graphics.g3d.environment.ShadowMap, com.badlogic.gdx.utils.Disposable
public class DirectionalShadowLight
extends DirectionalLightEx
implements com.badlogic.gdx.graphics.g3d.environment.ShadowMap, com.badlogic.gdx.utils.Disposable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.badlogic.gdx.graphics.Cameraprotected final com.badlogic.gdx.math.Vector3protected com.badlogic.gdx.graphics.glutils.FrameBufferprotected static final floatprotected final com.badlogic.gdx.graphics.g3d.utils.TextureDescriptorFields inherited from class DirectionalLightEx
baseColor, intensityFields inherited from class com.badlogic.gdx.graphics.g3d.environment.DirectionalLight
directionFields inherited from class com.badlogic.gdx.graphics.g3d.environment.BaseLight
color -
Constructor Summary
ConstructorsConstructorDescriptionDirectionalShadowLight(int shadowMapWidth, int shadowMapHeight) DirectionalShadowLight(int shadowMapWidth, int shadowMapHeight, float shadowViewportWidth, float shadowViewportHeight, float shadowNear, float shadowFar) -
Method Summary
Modifier and TypeMethodDescriptionvoidbegin()protected com.badlogic.gdx.graphics.glutils.FrameBuffercreateFrameBuffer(int width, int height) voiddispose()voidend()booleanequals(DirectionalLightEx other) booleanequals(DirectionalShadowLight other) com.badlogic.gdx.graphics.Cameracom.badlogic.gdx.graphics.g3d.utils.TextureDescriptorcom.badlogic.gdx.graphics.glutils.FrameBuffercom.badlogic.gdx.math.Matrix4setBounds(com.badlogic.gdx.math.collision.BoundingBox box) setCenter(com.badlogic.gdx.math.Vector3 center) setShadowMapSize(int shadowMapWidth, int shadowMapHeight) voidsetViewport(double shadowViewportWidth, double shadowViewportHeight, double shadowNear, double shadowFar) setViewport(float shadowViewportWidth, float shadowViewportHeight, float shadowNear, float shadowFar) protected voidvalidate()Methods inherited from class DirectionalLightEx
equals, set, set, set, set, set, set, updateColorModifier and TypeMethodDescriptionbooleanequals(com.badlogic.gdx.graphics.g3d.environment.DirectionalLight other) set(float r, float g, float b, float dirX, float dirY, float dirZ) set(float r, float g, float b, com.badlogic.gdx.math.Vector3 direction) set(com.badlogic.gdx.graphics.Color color, float dirX, float dirY, float dirZ) set(com.badlogic.gdx.graphics.Color color, com.badlogic.gdx.math.Vector3 direction) set(com.badlogic.gdx.graphics.Color baseColor, com.badlogic.gdx.math.Vector3 direction, float intensity) com.badlogic.gdx.graphics.g3d.environment.DirectionalLightset(com.badlogic.gdx.graphics.g3d.environment.DirectionalLight copyFrom) voidMethods inherited from class com.badlogic.gdx.graphics.g3d.environment.DirectionalLight
equals, setDirection, setDirectionMethods inherited from class com.badlogic.gdx.graphics.g3d.environment.BaseLight
setColor, setColor
-
Field Details
-
SQRT2
protected static final float SQRT2 -
fbo
protected com.badlogic.gdx.graphics.glutils.FrameBuffer fbo -
cam
protected com.badlogic.gdx.graphics.Camera cam -
textureDesc
protected final com.badlogic.gdx.graphics.g3d.utils.TextureDescriptor textureDesc -
center
protected final com.badlogic.gdx.math.Vector3 center
-
-
Constructor Details
-
DirectionalShadowLight
public DirectionalShadowLight() -
DirectionalShadowLight
public DirectionalShadowLight(int shadowMapWidth, int shadowMapHeight) -
DirectionalShadowLight
public DirectionalShadowLight(int shadowMapWidth, int shadowMapHeight, float shadowViewportWidth, float shadowViewportHeight, float shadowNear, float shadowFar)
-
-
Method Details
-
setShadowMapSize
-
createFrameBuffer
protected com.badlogic.gdx.graphics.glutils.FrameBuffer createFrameBuffer(int width, int height) -
setViewport
public void setViewport(double shadowViewportWidth, double shadowViewportHeight, double shadowNear, double shadowFar) -
setViewport
public DirectionalShadowLight setViewport(float shadowViewportWidth, float shadowViewportHeight, float shadowNear, float shadowFar) -
setCenter
-
setCenter
-
setBounds
-
validate
protected void validate() -
begin
public void begin() -
end
public void end() -
getFrameBuffer
public com.badlogic.gdx.graphics.glutils.FrameBuffer getFrameBuffer() -
getCamera
public com.badlogic.gdx.graphics.Camera getCamera() -
getProjViewTrans
public com.badlogic.gdx.math.Matrix4 getProjViewTrans()- Specified by:
getProjViewTransin interfacecom.badlogic.gdx.graphics.g3d.environment.ShadowMap
-
getDepthMap
public com.badlogic.gdx.graphics.g3d.utils.TextureDescriptor getDepthMap()- Specified by:
getDepthMapin interfacecom.badlogic.gdx.graphics.g3d.environment.ShadowMap
-
dispose
public void dispose()- Specified by:
disposein interfacecom.badlogic.gdx.utils.Disposable
-
equals
- Overrides:
equalsin classDirectionalLightEx
-
equals
-