CompositionGraphicsDevice Class

Definition

Used to create all hardware bound resources for a given DirectX device on a compositor session. CompositionGraphicsDevice contains a DirectX device that is used to perform the GPU operations. Developers can obtain a Graphics device from the compositor top level object.

public ref class CompositionGraphicsDevice sealed
public ref class CompositionGraphicsDevice sealed : CompositionObject
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class CompositionGraphicsDevice final
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 131072)]
class CompositionGraphicsDevice final : CompositionObject
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class CompositionGraphicsDevice
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 131072)]
public sealed class CompositionGraphicsDevice : CompositionObject
Public NotInheritable Class CompositionGraphicsDevice
Public NotInheritable Class CompositionGraphicsDevice
Inherits CompositionObject
Inheritance
Object Platform::Object IInspectable CompositionGraphicsDevice
Inheritance
Object Platform::Object IInspectable CompositionObject CompositionGraphicsDevice
Attributes

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Remarks

Version history

Windows version SDK version Value added
1703 15063 CreateDrawingSurface2
1703 15063 CreateVirtualDrawingSurface
1903 18362 CreateMipmapSurface
1903 18362 Trim

Properties

Comment

A string to associate with the CompositionObject.

(Inherited from CompositionObject)
Compositor

The Compositor used to create this CompositionObject.

(Inherited from CompositionObject)
Dispatcher

The dispatcher for the CompositionObject.

(Inherited from CompositionObject)
DispatcherQueue

Gets the DispatcherQueue for the CompostionObject.

(Inherited from CompositionObject)
ImplicitAnimations

The collection of implicit animations attached to this object.

(Inherited from CompositionObject)
Properties

The collection of properties associated with the CompositionObject.

(Inherited from CompositionObject)

Methods

CaptureAsync(Visual, SizeInt32, DirectXPixelFormat, DirectXAlphaMode, Single)

Captures various source elements, including visual trees owned by an application, to a composition surface.

Close()

Closes the CompositionObject and releases system resources.

(Inherited from CompositionObject)
ConnectAnimation(String, CompositionAnimation)

Connects and animation.

(Inherited from CompositionObject)
CreateDrawingSurface(Size, DirectXPixelFormat, DirectXAlphaMode)

Creates an instance of CompositionDrawingSurface.

CreateDrawingSurface2(SizeInt32, DirectXPixelFormat, DirectXAlphaMode)

Creates an instance of CompositionDrawingSurface.

CreateImageFromUri(Uri)

Creates a CompositionImage from the specified Uri.

CreateImageFromUri(Uri, CompositionImageOptions)

Creates a CompositionImage from the specified Uri using the specified options.

CreateMipmapSurface(SizeInt32, DirectXPixelFormat, DirectXAlphaMode)

Creates an instance of CompositionMipMapSurface.

CreateVirtualDrawingSurface(SizeInt32, DirectXPixelFormat, DirectXAlphaMode)

Creates an instance of CompositionVirtualDrawingSurface.

DisconnectAnimation(String)

Disconnects an animation.

(Inherited from CompositionObject)
Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

(Inherited from CompositionObject)
PopulatePropertyInfo(String, AnimationPropertyInfo)

Defines a property that can be animated.

(Inherited from CompositionObject)
StartAnimation(String, CompositionAnimation)

Connects an animation with the specified property of the object and starts the animation.

(Inherited from CompositionObject)
StartAnimation(String, CompositionAnimation, AnimationController)

Connects an animation with the specified property of the object and starts the animation.

(Inherited from CompositionObject)
StartAnimationGroup(ICompositionAnimationBase)

Starts an animation group.

The StartAnimationGroup method on CompositionObject lets you start CompositionAnimationGroup. All the animations in the group will be started at the same time on the object.

(Inherited from CompositionObject)
StopAnimation(String)

Disconnects an animation from the specified property and stops the animation.

(Inherited from CompositionObject)
StopAnimationGroup(ICompositionAnimationBase)

Stops an animation group.

(Inherited from CompositionObject)
Trim()

Trims any graphics memory allocated by the graphics device on the app's behalf.

TryGetAnimationController(String)

Returns an AnimationController for the animation running on the specified property.

(Inherited from CompositionObject)

Events

RenderingDeviceReplaced

Event triggered when the rendering device has been replaced.

Applies to