Click or drag to resize
AB4D logo

VirtualRealityProviderBaseUpdateRenderingContext Method

UpdateRenderingContext is called from the BeginVirtualRealityRenderingStep and should update the properties in the RenderingContext according to the current eye. See remarks for more info about the usual tasks that are preformed in this method.

Namespace: Ab3d.DirectX
Assembly: Ab3d.DXEngine (in Ab3d.DXEngine.dll) Version: 7.0.8865.1045
Syntax
C#
public abstract void UpdateRenderingContext(
	RenderingContext renderingContext,
	bool isNewFrame
)

Parameters

renderingContext  RenderingContext
RenderingContext
isNewFrame  Boolean
true if no eye was yet rendered for the current frame; false if the first eye was already rendered for the current frame and we need to render the second eye
Remarks

UpdateRenderingContext is called from the BeginVirtualRealityRenderingStep and should update the properties in the RenderingContext according to the current eye.

This method is usually called from the BeginVirtualRealityRenderingStep (when the virtual reality provider is enabled).

Usually this method does the following:
- Creates the back buffers and views that are needed for rendering (the back buffers are also recreated if the size of CurrentBackBufferDescription is different from the size of previously created back buffers).
- Updates the CurrentEye property.
- Sets the UsedCamera property to a StereoscopicCamera
- Calls SetBackBuffer(Texture2D, Texture2DDescription, RenderTargetView, DepthStencilView, Int32, Boolean) method and sets the new back buffers.
- Calls SetCustomDestinationBuffer(Texture2D, Texture2DDescription, RenderTargetView) on the DefaultResolveBackBufferRenderingStep.

See Also