M_Rhino_Geometry_Quaternion_SetRotation_1 - mcneel/rhinocommon-api-docs GitHub Wiki

Quaternion.SetRotation Method (Double, Vector3d)

Sets the quaternion to cos(angle/2), sin(angle/2)*x, sin(angle/2)*y, sin(angle/2)*z where (x,y,z) is the unit vector parallel to axis. This is the unit quaternion that represents the rotation of angle about axis.

Namespace: Rhino.Geometry
Assembly: RhinoCommon (in RhinoCommon.dll) Version: Rhino 6.0

Syntax

C#

public void SetRotation(
	double angle,
	Vector3d axisOfRotation
)

VB

Public Sub SetRotation ( 
	angle As Double,
	axisOfRotation As Vector3d
)

Parameters

 

angle
Type: System.Double
in radians.
axisOfRotation
Type: Rhino.Geometry.Vector3d
The direction of the axis of rotation.

Version Information

Supported in: 6.0.16224.21491, 5D58w

See Also

Reference

Quaternion Structure
SetRotation Overload
Rhino.Geometry Namespace

⚠️ **GitHub.com Fallback** ⚠️