Class CBufferCollectionUpdater
This is a collection of CBuffers associated with effects that is going to be updated.
Inherited Members
Namespace: Evergine.Framework.Graphics
Assembly: Evergine.Framework.dll
Syntax
public class CBufferCollectionUpdater : DisposableObject
Constructors
CBufferCollectionUpdater(UpdatePolicy, int)
Initializes a new instance of the CBufferCollectionUpdater class.
Declaration
public CBufferCollectionUpdater(UpdatePolicy updatePolicy, int sizeBlockMultiplier = 1)
Parameters
Type | Name | Description |
---|---|---|
UpdatePolicy | updatePolicy | The update policy. |
int | sizeBlockMultiplier | The multiplier for the size of a cbuffer. |
Fields
UpdatePolicy
The update policy of this buffer collection.
Declaration
public readonly UpdatePolicy UpdatePolicy
Field Value
Type | Description |
---|---|
UpdatePolicy |
Methods
Collect(IEngineShaderParameters)
Updates the constant buffers.
Declaration
public void Collect(IEngineShaderParameters engineShaderParameters)
Parameters
Type | Name | Description |
---|---|---|
IEngineShaderParameters | engineShaderParameters | The engine shader parameters. |
Destroy()
Destroys all resources of this instance.
Declaration
protected override void Destroy()
Overrides
GetCBufferUpdater(Effect)
Gets a constant buffer effect updater for the specified effect.
Declaration
public CBufferCollectionUpdaterEffectEntry GetCBufferUpdater(Effect effect)
Parameters
Type | Name | Description |
---|---|---|
Effect | effect | The effect. |
Returns
Type | Description |
---|---|
CBufferCollectionUpdaterEffectEntry | The constant buffer updater. |
GetConstantBuffer(Effect, int)
Gets a constant buffer of the specified slot and effect.
Declaration
public ConstantBuffer GetConstantBuffer(Effect effect, int slot)
Parameters
Type | Name | Description |
---|---|---|
Effect | effect | The effect. |
int | slot | The constant buffer slot. |
Returns
Type | Description |
---|---|
ConstantBuffer | The constant buffer. |
Prepare(CommandBuffer)
Prepares all registered effects.
Declaration
public void Prepare(CommandBuffer commandBuffer)
Parameters
Type | Name | Description |
---|---|---|
CommandBuffer | commandBuffer | The command buffer. |
RegisterEffect(Effect)
Registers an effect.
Declaration
public CBufferCollectionUpdaterEffectEntry RegisterEffect(Effect effect)
Parameters
Type | Name | Description |
---|---|---|
Effect | effect | The effect to register. |
Returns
Type | Description |
---|---|
CBufferCollectionUpdaterEffectEntry | The updater entry associated with this effect. |
UnregisterEffect(Effect)
Unregisters an effect.
Declaration
public void UnregisterEffect(Effect effect)
Parameters
Type | Name | Description |
---|---|---|
Effect | effect | The effect to unregister. |