Quaternion Constructors
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.
Initializes a new instance of the Quaternion structure.
Overloads
Quaternion(Vector3D, Double) |
Initializes a new instance of the Quaternion structure. |
Quaternion(Double, Double, Double, Double) |
Initializes a new instance of the Quaternion structure. |
Quaternion(Vector3D, Double)
Initializes a new instance of the Quaternion structure.
public:
Quaternion(System::Windows::Media::Media3D::Vector3D axisOfRotation, double angleInDegrees);
public Quaternion (System.Windows.Media.Media3D.Vector3D axisOfRotation, double angleInDegrees);
new System.Windows.Media.Media3D.Quaternion : System.Windows.Media.Media3D.Vector3D * double -> System.Windows.Media.Media3D.Quaternion
Public Sub New (axisOfRotation As Vector3D, angleInDegrees As Double)
Parameters
- angleInDegrees
- Double
Angle to rotate around the specified axis, in degrees.
Remarks
The W property of the quaternion is computed automatically.
Applies to
Quaternion(Double, Double, Double, Double)
Initializes a new instance of the Quaternion structure.
public:
Quaternion(double x, double y, double z, double w);
public Quaternion (double x, double y, double z, double w);
new System.Windows.Media.Media3D.Quaternion : double * double * double * double -> System.Windows.Media.Media3D.Quaternion
Public Sub New (x As Double, y As Double, z As Double, w As Double)
Parameters
- x
- Double
Value of the new Quaternion's X coordinate.
- y
- Double
Value of the new Quaternion's Y coordinate.
- z
- Double
Value of the new Quaternion's Z coordinate.
- w
- Double
Value of the new Quaternion's W coordinate.
Remarks
For the axis (x, y, z) and angle of rotation theta, the w
value for the quaternion is:
w = cos(theta/2)
Note that if you use the Vector3D constructor, the fourth parameter is the angle, in degrees, and the w calculation is performed for you.
Applies to
الملاحظات
https://aka.ms/ContentUserFeedback.
قريبًا: خلال عام 2024، سنتخلص تدريجيًا من GitHub Issues بوصفها آلية إرسال ملاحظات للمحتوى ونستبدلها بنظام ملاحظات جديد. لمزيد من المعلومات، راجعإرسال الملاحظات وعرضها المتعلقة بـ