CompositionTarget class

Applies to Windows and Windows Phone

Represents the composited display surface for an app. This class is mainly for Microsoft DirectX content interop scenarios.

Inheritance

Object
  CompositionTarget

Syntax


public ref class CompositionTarget sealed 

Attributes

[MarshalingBehavior(Agile)]
[Threading(Both)]
[Version(0x06020000)]
[WebHostHidden()]

Members

The CompositionTarget class has these types of members:

Events

The CompositionTarget class has these events.

EventDescription
Rendering Occurs when the core rendering process renders a frame.
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.

 

Methods

The CompositionTarget class inherits methods from the Object class.

Remarks

CompositionTarget has one member, Rendering. Rendering is a static event that is fired by the XAML rendering system overall, not by the Application, Window, Page or any other specific object part of an app. CompositionTarget's sole purpose is to provide this hook into the rendering process. That's mainly relevant only to DirectX content interop scenarios where you want to know when the XAML rendering happens, so that you can execute some DirectX code in response. For scenarios that don't involve DirectX content you probably won't need Rendering and can just rely on the XAML rendering system running and performing all your composition and layout.

Requirements

Minimum supported client

Windows 8 [Windows Store apps only]

Minimum supported server

Windows Server 2012 [Windows Store apps only]

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.UI.Xaml.Media
Windows::UI::Xaml::Media [C++]

Metadata

Windows.winmd

See also

DirectX and XAML interop
Make animations smooth
Direct3D shooting game sample

 

 

Show:
© 2014 Microsoft