Represents the composited display surface for an app. This class provides application-wide rendering events.
public : sealed class CompositionTarget
public sealed class CompositionTarget
Public NotInheritable Class CompositionTarget
Windows 10 requirements
Windows 10 (introduced v10.0.10240.0)
Windows.Foundation.UniversalApiContract (introduced v1)
CompositionTarget events are useful for rendering scenarios like:
measuring frame rendering time using the Rendered event
For scenarios that don't involve custom rendering or frame time measurement you probably won't need CompositionTarget and can just rely on the XAML rendering system running and performing all your composition and layout.
|Windows version||SDK version||Value added|
|Rendered Rendered Rendered Rendered||
Occurs immediately after the core rendering process renders a frame. This event lets you determine how long each frame takes to render.
|Rendering Rendering Rendering Rendering||
Occurs when the core rendering process renders a frame.
|SurfaceContentsLost SurfaceContentsLost SurfaceContentsLost SurfaceContentsLost||
Occurs when an underlying major change occurs, such as a DirectX device change. Typically the application must regenerate its surface contents when notified of this event.
Send feedback about: