Class GeometryRenderCore
- Namespace
- HelixToolkit.SharpDX.Core
- Assembly
- HelixToolkit.SharpDX.dll
public abstract class GeometryRenderCore : RenderCore, IDisposable, IGUID, IThrowingShadow, IGeometryRenderCore
- Inheritance
-
GeometryRenderCore
- Implements
- Derived
- Inherited Members
Constructors
GeometryRenderCore()
Initializes a new instance of the GeometryRenderCore class.
public GeometryRenderCore()
GeometryRenderCore(RenderType)
Initializes a new instance of the GeometryRenderCore class.
public GeometryRenderCore(RenderType renderType)
Parameters
renderTypeRenderTypeType of the render.
Properties
GeometryBuffer
public IAttachableBufferModel? GeometryBuffer { get; set; }
Property Value
InstanceBuffer
public IElementsBufferModel InstanceBuffer { get; set; }
Property Value
InvertCullModeState
public RasterizerStateProxy? InvertCullModeState { get; }
Property Value
RasterDescription
public RasterizerStateDescription RasterDescription { get; set; }
Property Value
- RasterizerStateDescription
RasterState
public RasterizerStateProxy? RasterState { get; }
Property Value
Methods
CreateRasterState(RasterizerStateDescription, bool)
protected virtual bool CreateRasterState(RasterizerStateDescription description, bool force)
Parameters
descriptionRasterizerStateDescriptionforcebool
Returns
DrawIndexed(DeviceContextProxy, IElementsBufferProxy, IElementsBufferModel)
public static void DrawIndexed(DeviceContextProxy context, IElementsBufferProxy indexBuffer, IElementsBufferModel instanceModel)
Parameters
contextDeviceContextProxyindexBufferIElementsBufferProxyinstanceModelIElementsBufferModel
DrawPoints(DeviceContextProxy, IElementsBufferProxy, IElementsBufferModel)
public static void DrawPoints(DeviceContextProxy context, IElementsBufferProxy vertexBuffer, IElementsBufferModel instanceModel)
Parameters
contextDeviceContextProxyvertexBufferIElementsBufferProxyinstanceModelIElementsBufferModel
OnAttach(IRenderTechnique?)
protected override bool OnAttach(IRenderTechnique? technique)
Parameters
techniqueIRenderTechnique
Returns
OnAttachBuffers(DeviceContextProxy, ref int)
Attach vertex buffer routine
protected virtual bool OnAttachBuffers(DeviceContextProxy context, ref int vertStartSlot)
Parameters
contextDeviceContextProxyvertStartSlotint
Returns
OnBindRasterState(DeviceContextProxy, bool)
Set all necessary states and buffers
protected void OnBindRasterState(DeviceContextProxy context, bool isInvertCullMode)
Parameters
contextDeviceContextProxyisInvertCullModebool
OnDetach()
On detaching, default is to release all resources
protected override void OnDetach()
OnElementChanged(object?, EventArgs)
protected void OnElementChanged(object? sender, EventArgs e)
Parameters
OnGeometryBufferChanged(IAttachableBufferModel?)
Called when [geometry buffer changed].
protected virtual void OnGeometryBufferChanged(IAttachableBufferModel? buffer)
Parameters
bufferIAttachableBufferModelThe buffer.
OnInvalidateRendererEvent(object?, EventArgs)
protected void OnInvalidateRendererEvent(object? sender, EventArgs e)
Parameters
OnRender(RenderContext, DeviceContextProxy)
Called when [render].
protected abstract void OnRender(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxyThe device context.
OnRenderCustom(RenderContext, DeviceContextProxy)
Render function for custom shader pass. Used to do special effects
protected abstract void OnRenderCustom(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextdeviceContextDeviceContextProxy
OnRenderDepth(RenderContext, DeviceContextProxy, ShaderPass?)
Called when [render depth].
protected abstract void OnRenderDepth(RenderContext context, DeviceContextProxy deviceContext, ShaderPass? customPass)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxyThe device context.
customPassShaderPassCustom depth pass
OnRenderShadow(RenderContext, DeviceContextProxy)
Called when [render shadow].
protected abstract void OnRenderShadow(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxy
OnUpdateCanRenderFlag()
Called when [update can render flag].
protected override bool OnUpdateCanRenderFlag()
Returns
PreRender(RenderContext, DeviceContextProxy)
protected bool PreRender(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextdeviceContextDeviceContextProxy
Returns
Render(RenderContext, DeviceContextProxy)
Trigger OnRender function delegate if CanRender()==true
public override sealed void Render(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextdeviceContextDeviceContextProxy
RenderCustom(RenderContext, DeviceContextProxy)
Renders the custom pass. Must apply render pass externally. Usually used during PostEffect rendering.
public override sealed void RenderCustom(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxyThe device context.
RenderDepth(RenderContext, DeviceContextProxy, ShaderPass?)
Renders the depth pass.
public override sealed void RenderDepth(RenderContext context, DeviceContextProxy deviceContext, ShaderPass? customPass)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxyThe device context.
customPassShaderPass
RenderShadow(RenderContext, DeviceContextProxy)
Renders the shadow pass. Used to generate shadow map.
public override sealed void RenderShadow(RenderContext context, DeviceContextProxy deviceContext)
Parameters
contextRenderContextThe context.
deviceContextDeviceContextProxyThe device context.