Class LightShaderGroupDynamic
Base class to build light shader groups with LightGroupRendererDynamic.
public abstract class LightShaderGroupDynamic : LightShaderGroup- Inheritance
- 
      objectLightShaderGroupDynamic
- Inherited Members
Constructors
LightShaderGroupDynamic(RenderContext, ILightShadowMapShaderGroupData)
protected LightShaderGroupDynamic(RenderContext renderContext, ILightShadowMapShaderGroupData shadowGroup)Parameters
- renderContextRenderContext
- shadowGroupILightShadowMapShaderGroupData
Fields
currentLights
List of lights selected for this rendering.
protected FastListStruct<LightDynamicEntry> currentLightsField Value
graphicsProfile
protected GraphicsProfile graphicsProfileField Value
lightRanges
protected LightShaderGroupDynamic.LightRange[] lightRangesField Value
lights
List of all available lights.
protected FastListStruct<LightDynamicEntry> lightsField Value
Properties
LightCurrentCount
public int LightCurrentCount { get; }Property Value
LightLastCount
public int LightLastCount { get; }Property Value
ShadowGroup
public ILightShadowMapShaderGroupData ShadowGroup { get; }Property Value
Methods
AddLight(RenderLight, LightShadowMapTexture)
Try to add light to this group (returns false if not possible).
public bool AddLight(RenderLight light, LightShadowMapTexture shadowMapTexture)Parameters
- lightRenderLight
- shadowMapTextureLightShadowMapTexture
Returns
AddView(int, RenderView, int)
public virtual int AddView(int viewIndex, RenderView renderView, int lightCount)Parameters
- viewIndexint
- renderViewRenderView
- lightCountint
Returns
- int
- The number of lights accepted in currentLights. 
ApplyDrawParameters(RenderDrawContext, int, ParameterCollection, ref BoundingBoxExt)
Applies PerDraw lighting parameters.
public override void ApplyDrawParameters(RenderDrawContext context, int viewIndex, ParameterCollection parameters, ref BoundingBoxExt boundingBox)Parameters
- contextRenderDrawContext
- viewIndexint
- parametersParameterCollection
- boundingBoxBoundingBoxExt
ApplyViewParameters(RenderDrawContext, int, ParameterCollection)
Applies PerView lighting parameters.
public override void ApplyViewParameters(RenderDrawContext context, int viewIndex, ParameterCollection parameters)Parameters
- contextRenderDrawContext
- viewIndexint
- parametersParameterCollection
ComputeLightCount(int)
Compute the number of light supported by this shader. Usually a different number of light will trigger a permutation and layout update.
protected virtual int ComputeLightCount(int lightCount)Parameters
- lightCountint
Returns
Reset()
Resets states.
public override void Reset()SetViews(FastList<RenderView>)
public virtual void SetViews(FastList<RenderView> views)Parameters
- viewsFastList<RenderView>
UpdateLayout(string)
Called when layout is updated, so that parameter keys can be recomputed.
public override void UpdateLayout(string compositionName)Parameters
- compositionNamestring
UpdateLightCount()
protected virtual void UpdateLightCount()