Click or drag to resize
AB4D logo

DXView Events

The DXView type exposes the following members.

Events
 NameDescription
Public eventDefaultSystemAdapterChanged DefaultSystemAdapterChanged event is triggered when the default system adapter (the primary system GPU) is changed. This means that it is not longer possible to share a DXEngine's texture with WPF. DXEngine will need to switch to WritableBitmap that is much slower than shared texture because the rendered scene needs to be copied from GPU memory to to CPU memory. In this case it is recommended to save the current scene, dispose the DXViewportView and create a new DXViewportView that will use the new graphics card.
Public eventDisposing Occurs when when Dispose is called.
Public eventDXRenderSizeChanged Called when the size of the rendering area is changed. Also called after the back buffers are initialized for the first time.
Public eventDXSceneDeviceCreated Called when the DXScene and DirectX 11 device have been created and when UsedGraphicsProfile was set, but before it is fully initialized (DXImage, D3DHOst, DirectX buffers and views are not created yet). This method can be used to change some properties the created DXScene object that is set to the DXScene property. Once all the DirectX objects has been initialized (all the buffers and views are created), the DXSceneInitialized event is triggered. Note that when DXScene is not created because a WPF 3D rendering is used, then the Wpf3DRenderingInitialized event is called.
Public eventDXSceneInitialized Called after the DXScene has been fully initialized - the device, buffers and views are created. In Wpf3D mode the event is triggered after the Wpf3D has been initialized. To be notified after the DXScene, DirectX device and UsedGraphicsProfile would be set and before the DirectX buffers and views are created, use the DXSceneDeviceCreated event.
Public eventGraphicsProfileRejected GraphicsProfileRejected event is fired when a GraphicsProfile is rejected.
Public eventSceneRendered Called after the scene has been rendered (with WPF 3D rendering this is called from CompositionTarget.Rendering event handler.
Public eventSceneUpdating Called when the scene is being updated and before it is rendered.
Public eventWpf3DRenderingInitialized Wpf3DRenderingInitialized event is called when WPF 3D rendering graphics profile is initialized. This rendering profile can be selected because user selected this profile (Wpf3D was the only profile in the GraphicsProfiles collection) or because no DirectX 11 rendering can be initialized (usually because of the problems with the drivers or some other problems). When a DirectX 11 rendering is initialized, then the DXSceneDeviceCreated event is called.
Top
See Also