Class DirectionalLightRenderer
java.lang.Object
foundry.veil.impl.client.render.light.DirectionalLightRenderer
- All Implemented Interfaces:
LightTypeRenderer<DirectionalLight>
,AutoCloseable
,org.lwjgl.system.NativeResource
@Internal
public class DirectionalLightRenderer
extends Object
implements LightTypeRenderer<DirectionalLight>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
free()
int
void
prepareLights
(LightRenderer lightRenderer, List<DirectionalLight> lights, Set<DirectionalLight> removedLights, CullFrustum frustum) Prepares the specified lights to be rendered.void
renderLights
(LightRenderer lightRenderer, List<DirectionalLight> lights) Renders all prepared lights with this renderer.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
Constructor Details
-
DirectionalLightRenderer
public DirectionalLightRenderer()
-
-
Method Details
-
prepareLights
public void prepareLights(LightRenderer lightRenderer, List<DirectionalLight> lights, Set<DirectionalLight> removedLights, CullFrustum frustum) Description copied from interface:LightTypeRenderer
Prepares the specified lights to be rendered.- Specified by:
prepareLights
in interfaceLightTypeRenderer<DirectionalLight>
- Parameters:
lightRenderer
- The light renderer instancelights
- The lights to renderremovedLights
- The lights that will be removed this framefrustum
- The culling view frustum
-
renderLights
Description copied from interface:LightTypeRenderer
Renders all prepared lights with this renderer.
Shaders, custom uniforms, and the way lights are rendered is up to the individual renderer.
- Specified by:
renderLights
in interfaceLightTypeRenderer<DirectionalLight>
- Parameters:
lightRenderer
- The light renderer instancelights
- The lights to render
-
getVisibleLights
public int getVisibleLights()- Specified by:
getVisibleLights
in interfaceLightTypeRenderer<DirectionalLight>
- Returns:
- The number of lights visible last frame
-
free
public void free()- Specified by:
free
in interfaceorg.lwjgl.system.NativeResource
-