Sdílet prostřednictvím


PerspectiveTransform3D Class

Definition

Represents a 3-D perspective effect.

public ref class PerspectiveTransform3D sealed : Transform3D
/// [Windows.Foundation.Metadata.Activatable(65536, Windows.Foundation.UniversalApiContract)]
/// [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 PerspectiveTransform3D final : Transform3D
/// [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)]
/// [Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
class PerspectiveTransform3D final : Transform3D
[Windows.Foundation.Metadata.Activatable(65536, typeof(Windows.Foundation.UniversalApiContract))]
[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 PerspectiveTransform3D : Transform3D
[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)]
[Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
public sealed class PerspectiveTransform3D : Transform3D
Public NotInheritable Class PerspectiveTransform3D
Inherits Transform3D
Inheritance
Object Platform::Object IInspectable DependencyObject Transform3D PerspectiveTransform3D
Attributes

Windows requirements

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

Remarks

For more info about using PerspectiveTransform3D, see the UIElement.Transform3D property.

Adding a PerspectiveTransform3D element to a scene with no other 3-D transforms will not change the appearance of any 2-D elements. It will preserve the X and Y coordinates in the plane of Z=0. To take advantage of the perspective effect, you need to use CompositeTransform3D in conjunction with PerspectiveTransform3D.

Following the guidelines of the The Direct3D Transformation Pipeline, PerspectiveTransform3D represents a projection transform. In comparison, CompositeTransform3D represents a world or view transform. Because of this, PerspectiveTransform3D should usually be applied at the root of the XAML scene. In most cases, this would be the Page element.

Constructors

PerspectiveTransform3D()

Initializes a new instance of the PerspectiveTransform3D class.

Properties

Depth

Gets or sets the distance in pixels to the plane where z=0.

DepthProperty

Identifies the Depth dependency property.

Dispatcher

Gets the CoreDispatcher that this object is associated with. The CoreDispatcher represents a facility that can access the DependencyObject on the UI thread even if the code is initiated by a non-UI thread.

(Inherited from DependencyObject)
OffsetX

Gets or sets the x-offset in pixels for the perspective's origin from the center of the element.

OffsetXProperty

Identifies the OffsetX dependency property.

OffsetY

Gets or sets the y-offset in pixels for the perspective's origin from the center of the element.

OffsetYProperty

Identifies the OffsetY dependency property.

Methods

ClearValue(DependencyProperty)

Clears the local value of a dependency property.

(Inherited from DependencyObject)
GetAnimationBaseValue(DependencyProperty)

Returns any base value established for a dependency property, which would apply in cases where an animation is not active.

(Inherited from DependencyObject)
GetValue(DependencyProperty)

Returns the current effective value of a dependency property from a DependencyObject.

(Inherited from DependencyObject)
ReadLocalValue(DependencyProperty)

Returns the local value of a dependency property, if a local value is set.

(Inherited from DependencyObject)
RegisterPropertyChangedCallback(DependencyProperty, DependencyPropertyChangedCallback)

Registers a notification function for listening to changes to a specific DependencyProperty on this DependencyObject instance.

(Inherited from DependencyObject)
SetValue(DependencyProperty, Object)

Sets the local value of a dependency property on a DependencyObject.

(Inherited from DependencyObject)
UnregisterPropertyChangedCallback(DependencyProperty, Int64)

Cancels a change notification that was previously registered by calling RegisterPropertyChangedCallback.

(Inherited from DependencyObject)

Applies to

See also