Class RootEffectRenderFeature
A root render feature that can manipulate effects.
public abstract class RootEffectRenderFeature : RootRenderFeature, IComponent, IReferencable, ICollectorHolder, IGraphicsRendererCore, IDisposable
- Inheritance
-
RootEffectRenderFeature
- Implements
- Derived
- Inherited Members
- Extension Methods
Fields
EffectCompiled
public Action<RenderSystem, Effect, RenderEffectReflection> EffectCompiled
Field Value
InstantiatedEffects
Stores reflection info for each effect.
public Dictionary<Effect, RenderEffectReflection> InstantiatedEffects
Field Value
RenderEffectKey
Key to store extra info for each effect instantiation of each object.
public StaticObjectPropertyKey<RenderEffect> RenderEffectKey
Field Value
ResourceGroupPool
public ResourceGroup[] ResourceGroupPool
Field Value
Properties
ComputeFallbackEffect
public RootEffectRenderFeature.ComputeFallbackEffectDelegate ComputeFallbackEffect { get; set; }
Property Value
EffectDescriptorSetSlotCount
public int EffectDescriptorSetSlotCount { get; }
Property Value
EffectObjectNodes
public ConcurrentCollector<EffectObjectNode> EffectObjectNodes { get; }
Property Value
EffectPermutationSlotCount
Gets number of effect permutation slot, which is the number of effect cached per object.
public int EffectPermutationSlotCount { get; }
Property Value
FrameLayouts
public ConcurrentCollector<FrameResourceGroupLayout> FrameLayouts { get; }
Property Value
PipelineProcessors
[DataMember]
public List<PipelineProcessor> PipelineProcessors { get; }
Property Value
Methods
ComputeDataArrayExpectedSize(DataType)
protected override int ComputeDataArrayExpectedSize(DataType type)
Parameters
typeDataType
Returns
ComputeResourceGroupOffset(RenderNodeReference)
Compute the index of first descriptor set stored in ResourceGroupPool.
protected int ComputeResourceGroupOffset(RenderNodeReference renderNode)
Parameters
renderNodeRenderNodeReference
Returns
CreateDrawCBufferOffsetSlot(string)
public ConstantBufferOffsetReference CreateDrawCBufferOffsetSlot(string variable)
Parameters
variablestring
Returns
CreateDrawLogicalGroup(string)
public LogicalGroupReference CreateDrawLogicalGroup(string logicalGroup)
Parameters
logicalGroupstring
Returns
CreateEffectPermutationSlot(string)
Creates a slot for storing a particular effect instantiation (per RenderObject).
public EffectPermutationSlot CreateEffectPermutationSlot(string effectName)
Parameters
effectNamestring
Returns
CreateFrameCBufferOffsetSlot(string)
public ConstantBufferOffsetReference CreateFrameCBufferOffsetSlot(string variable)
Parameters
variablestring
Returns
CreateUniqueDescriptorSetLayout(DescriptorSetLayoutBuilder)
public DescriptorSetLayout CreateUniqueDescriptorSetLayout(DescriptorSetLayoutBuilder descriptorSetLayoutBuilder)
Parameters
descriptorSetLayoutBuilderDescriptorSetLayoutBuilder
Returns
CreateViewCBufferOffsetSlot(string)
public ConstantBufferOffsetReference CreateViewCBufferOffsetSlot(string variable)
Parameters
variablestring
Returns
CreateViewLogicalGroup(string)
public LogicalGroupReference CreateViewLogicalGroup(string logicalGroup)
Parameters
logicalGroupstring
Returns
Destroy()
Disposes of object resources.
protected override void Destroy()
GetEffectPermutationSlot(RenderStage)
Gets the effect slot for a given render stage.
public EffectPermutationSlot GetEffectPermutationSlot(RenderStage renderStage)
Parameters
renderStageRenderStage
Returns
GetOrCreateEffectDescriptorSetSlot(string)
public EffectDescriptorSetReference GetOrCreateEffectDescriptorSetSlot(string name)
Parameters
namestring
Returns
InitializeCore()
Initializes this instance. Query for specific cbuffer (either new one, like PerMaterial, or parts of an existing one, like PerObject=>Skinning)
protected override void InitializeCore()
InvalidateEffectPermutation(RenderObject, RenderEffect)
Implemented by subclasses to reset effect dependent data.
protected virtual void InvalidateEffectPermutation(RenderObject renderObject, RenderEffect renderEffect)
Parameters
renderObjectRenderObjectrenderEffectRenderEffect
Prepare(RenderDrawContext)
Performs most of the work (computation and resource preparation). Later game simulation might be running during that step.
public override void Prepare(RenderDrawContext context)
Parameters
contextRenderDrawContext
PrepareEffectPermutations(RenderDrawContext)
Perform effect permutations, before Prepare(RenderDrawContext).
public override void PrepareEffectPermutations(RenderDrawContext context)
Parameters
contextRenderDrawContext
PrepareEffectPermutationsImpl(RenderDrawContext)
Actual implementation of PrepareEffectPermutations(RenderDrawContext).
public virtual void PrepareEffectPermutationsImpl(RenderDrawContext context)
Parameters
contextRenderDrawContext
ProcessPipelineState(RenderContext, RenderNodeReference, ref RenderNode, RenderObject, PipelineStateDescription)
protected virtual void ProcessPipelineState(RenderContext context, RenderNodeReference renderNodeReference, ref RenderNode renderNode, RenderObject renderObject, PipelineStateDescription pipelineState)
Parameters
contextRenderContextrenderNodeReferenceRenderNodeReferencerenderNodeRenderNoderenderObjectRenderObjectpipelineStatePipelineStateDescription
RemoveViewCBufferOffsetSlot(ConstantBufferOffsetReference)
public void RemoveViewCBufferOffsetSlot(ConstantBufferOffsetReference cbufferOffsetSlot)
Parameters
cbufferOffsetSlotConstantBufferOffsetReference
Reset()
public override void Reset()