RotateTransform3D.CenterZ Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the Z coordinate of the Point3D about which to rotate.
public:
property double CenterZ { double get(); void set(double value); };
public double CenterZ { get; set; }
member this.CenterZ : double with get, set
Public Property CenterZ As Double
Property Value
Double that represents the Z coordinate of the Point3D about which to rotate.
Examples
The following code uses this property to change the point around which a RotateTransform3D transforms the model.
public void AddAnimation(object sender, EventArgs e)
{
if ((bool)CenterAnimCheck.IsChecked == true)
{
//Shift point around which model rotates to (-0.5, -0.5, -0.5).
myHorizontalRTransform.CenterX = -0.5;
myHorizontalRTransform.CenterY = -0.5;
myHorizontalRTransform.CenterZ = -0.5;
}
if ((bool)CenterAnimCheck.IsChecked != true)
{
//Set point around which model rotates back to (0, 0, 0).
myHorizontalRTransform.CenterX = 0;
myHorizontalRTransform.CenterY = 0;
myHorizontalRTransform.CenterZ = 0;
}
}
Public Sub AddAnimation(ByVal sender As Object, ByVal e As EventArgs)
If CBool(CenterAnimCheck.IsChecked) = True Then
'Shift point around which model rotates to (-0.5, -0.5, -0.5).
myHorizontalRTransform.CenterX = -0.5
myHorizontalRTransform.CenterY = -0.5
myHorizontalRTransform.CenterZ = -0.5
End If
If CBool(CenterAnimCheck.IsChecked) <> True Then
'Set point around which model rotates back to (0, 0, 0).
myHorizontalRTransform.CenterX = 0
myHorizontalRTransform.CenterY = 0
myHorizontalRTransform.CenterZ = 0
End If
End Sub
Applies to
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
.NET