Class ImmediateContextRenderer
- Namespace
- HelixToolkit.SharpDX.Render
- Assembly
- HelixToolkit.SharpDX.dll
public class ImmediateContextRenderer : DisposeObject, IRenderer, IDisposable
- Inheritance
-
ImmediateContextRenderer
- Implements
- Derived
- Inherited Members
Constructors
ImmediateContextRenderer(IDevice3DResources)
Initializes a new instance of the ImmediateContextRenderer class.
public ImmediateContextRenderer(IDevice3DResources deviceResource)
Parameters
deviceResourceIDevice3DResourcesThe deviceResource.
Properties
ImmediateContext
Gets or sets the immediate context.
public DeviceContextProxy? ImmediateContext { get; }
Property Value
- DeviceContextProxy
The immediate context.
Methods
Attach(IRenderHost)
public void Attach(IRenderHost host)
Parameters
hostIRenderHost
Detach()
public void Detach()
OnDispose(bool)
Disposes of object resources.
protected override void OnDispose(bool disposeManagedResources)
Parameters
disposeManagedResourcesboolIf true, managed resources should be disposed of in addition to unmanaged resources.
RenderOpaque(RenderContext, FastList<SceneNode>, ref RenderParameter, bool)
Renders the scene.
public virtual int RenderOpaque(RenderContext context, FastList<SceneNode> renderables, ref RenderParameter parameter, bool testFrustum)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
parameterRenderParameterThe parameter.
testFrustumbool
Returns
- int
Number of node has been rendered
RenderPostProc(RenderContext, FastList<SceneNode>, ref RenderParameter)
Renders the post proc.
public virtual void RenderPostProc(RenderContext context, FastList<SceneNode> renderables, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
parameterRenderParameterThe parameter.
RenderPreProc(RenderContext, FastList<SceneNode>, ref RenderParameter)
Renders the pre proc.
public virtual void RenderPreProc(RenderContext context, FastList<SceneNode> renderables, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
parameterRenderParameterThe parameter.
RenderScene2D(RenderContext2D, FastList<SceneNode2D>, ref RenderParameter2D)
Render2s the d.
public virtual void RenderScene2D(RenderContext2D context, FastList<SceneNode2D> renderables, ref RenderParameter2D parameter)
Parameters
contextRenderContext2DThe context.
renderablesFastList<SceneNode2D>The renderables.
parameterRenderParameter2DThe parameter.
RenderScreenSpaced(RenderContext, FastList<SceneNode>, int, int, ref RenderParameter)
Renders the screen spaced.
public virtual void RenderScreenSpaced(RenderContext context, FastList<SceneNode> renderables, int start, int count, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
startintStart index in renderables
countintNumber of renderables to render.
parameterRenderParameterThe parameter.
RenderScreenSpacedPostProc(RenderContext, FastList<SceneNode>, FastList<SceneNode>, FastList<SceneNode>, ref RenderParameter)
Renders the screenspaced node's post proc.
public virtual void RenderScreenSpacedPostProc(RenderContext context, FastList<SceneNode> screenSpacedWithPostEffects, FastList<SceneNode> nodesWithPostEffects, FastList<SceneNode> postProcNodes, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
screenSpacedWithPostEffectsFastList<SceneNode>nodesWithPostEffectsFastList<SceneNode>postProcNodesFastList<SceneNode>parameterRenderParameterThe parameter.
RenderToBackBuffer(RenderContext, ref RenderParameter)
Renders to back buffer.
public virtual void RenderToBackBuffer(RenderContext context, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
parameterRenderParameterThe parameter.
RenderToPingPongBuffer(RenderContext, ref RenderParameter)
Renders to ping pong buffer.
public virtual void RenderToPingPongBuffer(RenderContext context, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
parameterRenderParameterThe parameter.
RenderTransparent(RenderContext, FastList<SceneNode>, ref RenderParameter)
Renders the transparent.
public virtual int RenderTransparent(RenderContext context, FastList<SceneNode> renderables, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
parameterRenderParameterThe parameter.
Returns
SetRenderTargets(ref RenderParameter)
Sets the render targets.
public void SetRenderTargets(ref RenderParameter parameter)
Parameters
parameterRenderParameterThe parameter.
UpdateGlobalVariables(RenderContext, FastList<SceneNode>, ref RenderParameter)
Updates the global variables. Such as light buffer and global transformation buffer
public virtual void UpdateGlobalVariables(RenderContext context, FastList<SceneNode> lights, ref RenderParameter parameter)
Parameters
contextRenderContextThe context.
lightsFastList<SceneNode>The lights.
parameterRenderParameterThe parameter.
UpdateNotRenderParallel(RenderContext, FastList<KeyValuePair<int, SceneNode>>)
Updates the no render parallel. UpdateNotRenderParallel(RenderContext, FastList<KeyValuePair<int, SceneNode>>)
public virtual void UpdateNotRenderParallel(RenderContext context, FastList<KeyValuePair<int, SceneNode>> renderables)
Parameters
contextRenderContextrenderablesFastList<KeyValuePair<int, SceneNode>>The renderables.
UpdateSceneGraph(RenderContext, FastList<SceneNode>, FastList<KeyValuePair<int, SceneNode>>)
Updates the scene graph.
public virtual void UpdateSceneGraph(RenderContext context, FastList<SceneNode> renderables, FastList<KeyValuePair<int, SceneNode>> results)
Parameters
contextRenderContextThe context.
renderablesFastList<SceneNode>The renderables.
resultsFastList<KeyValuePair<int, SceneNode>>Returns list of flattened scene graph with depth index as KeyValuePair.Key
UpdateSceneGraph2D(RenderContext2D, FastList<SceneNode2D>)
Updates the scene graph.
public void UpdateSceneGraph2D(RenderContext2D context, FastList<SceneNode2D> renderables)
Parameters
contextRenderContext2DThe context.
renderablesFastList<SceneNode2D>The renderables.