Click or drag to resize
AB4D logo

DXScene Events

The DXScene type exposes the following members.

Events
 NameDescription
Public eventAfterFrameInitialized AfterFrameInitialized event is triggered after the RenderTargets have been set and cleared, Viewports have been set and default Rasterizer state has been set.
Public eventAfterFrameRendered AfterFrameRendered event is triggered after all the rendering activities for one frame have been finished.
Public eventAfterObjectsRendered AfterObjectsRendered event is triggered after all the objects have been rendered and before rendered objects are "sent to the screen" (Present method on SwapChain is called or the render target is prepared for D3DImage)
Public eventAfterUpdated AfterUpdated event is triggered after the SceneNode objects have been updated and before the decision is made to render the next frame or not. Subscriber to this event can prevent rendering frame or force rendering it with changing the IsRenderNeeded property in the event args.
Public eventBackBufferReady BackBufferReady event is triggered when the rendered image is ready to be copied from graphic to main memory. This is used when DirectXImage presentation type is used and when DXEngine is using software rendering or when UseSharedWpfTexture is set to true. In those cases the DXEngine is rendering the image to a so called staging buffer and when the image in staging buffer is ready the BackBufferReady is triggered. The event arguments contain the size of the image, its format and the mapped subresource.
Public eventDeviceRemoved DeviceRemoved event is triggered when the DirectX device is removed or reset (for example when the DirectX driver is updated; but not when computer goes to sleep). The event handler can handle this case with saving the current state of the 3D scene, dispose the current DirectX objects and recreate the 3D scene.
Public eventHardwareAccelerate3DLineSettingsChanged HardwareAccelerate3DLineSettingsChanged is triggered when HardwareAccelerate3DLines or HardwareAccelerate3DLineCaps properties are changed.
Public eventSizeChanged SizeChanged event is trigger after the Resize(Int32, Int32, Single, Single) method is called.
Top
See Also