package ocgtk
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha256=4e50fdb5093136a10fc8ffbe388e44cbcb70d52f8afdd48863ec7e22580ff054
doc/ocgtk.graphene/Ocgtk_graphene/Graphene/Wrappers/Euler/index.html
Module Wrappers.Euler
type t = [ `euler ] Gobject.objval alloc : unit -> tCreate a new Euler
val to_vec3 : t -> [ `vec3 ] Gobject.objRetrieves the angles of a #graphene_euler_t and initializes a #graphene_vec3_t with them.
val to_quaternion : t -> [ `quaternion ] Gobject.objConverts a #graphene_euler_t into a #graphene_quaternion_t.
val to_matrix : t -> [ `matrix ] Gobject.objConverts a #graphene_euler_t into a transformation matrix expressing the extrinsic composition of rotations described by the Euler angles.
The rotations are applied over the reference frame axes in the order associated with the #graphene_euler_t; for instance, if the order used to initialize @e is %GRAPHENE_EULER_ORDER_XYZ:
* the first rotation moves the body around the X axis with an angle φ * the second rotation moves the body around the Y axis with an angle of ϑ * the third rotation moves the body around the Z axis with an angle of ψ
The rotation sign convention is right-handed, to preserve compatibility between Euler-based, quaternion-based, and angle-axis-based rotations.
val reorder : t -> Graphene_enums.eulerorder -> tReorders a #graphene_euler_t using @order.
This function is equivalent to creating a #graphene_quaternion_t from the given #graphene_euler_t, and then converting the quaternion into another #graphene_euler_t.
val init_with_order :
t ->
float ->
float ->
float ->
Graphene_enums.eulerorder ->
tInitializes a #graphene_euler_t with the given angles and @order.
val init_from_vec3 :
t ->
[ `vec3 ] Gobject.obj option ->
Graphene_enums.eulerorder ->
tInitializes a #graphene_euler_t using the angles contained in a #graphene_vec3_t.
If the #graphene_vec3_t @v is %NULL, the #graphene_euler_t will be initialized with all angles set to 0.
val init_from_radians :
t ->
float ->
float ->
float ->
Graphene_enums.eulerorder ->
tInitializes a #graphene_euler_t using the given angles and order of rotation.
val init_from_quaternion :
t ->
[ `quaternion ] Gobject.obj option ->
Graphene_enums.eulerorder ->
tInitializes a #graphene_euler_t using the given normalized quaternion.
If the #graphene_quaternion_t @q is %NULL, the #graphene_euler_t will be initialized with all angles set to 0.
val init_from_matrix :
t ->
[ `matrix ] Gobject.obj option ->
Graphene_enums.eulerorder ->
tInitializes a #graphene_euler_t using the given rotation matrix.
If the #graphene_matrix_t @m is %NULL, the #graphene_euler_t will be initialized with all angles set to 0.
Initializes a #graphene_euler_t using the angles and order of another #graphene_euler_t.
If the #graphene_euler_t @src is %NULL, this function is equivalent to calling graphene_euler_init() with all angles set to 0.
Initializes a #graphene_euler_t using the given angles.
The order of the rotations is %GRAPHENE_EULER_ORDER_DEFAULT.
val get_z : t -> floatRetrieves the rotation angle on the Z axis, in degrees.
val get_y : t -> floatRetrieves the rotation angle on the Y axis, in degrees.
val get_x : t -> floatRetrieves the rotation angle on the X axis, in degrees.
val get_order : t -> Graphene_enums.eulerorderRetrieves the order used to apply the rotations described in the #graphene_euler_t structure, when converting to and from other structures, like #graphene_quaternion_t and #graphene_matrix_t.
This function does not return the %GRAPHENE_EULER_ORDER_DEFAULT enumeration value; it will return the effective order of rotation instead.
val get_gamma : t -> floatRetrieves the third component of the Euler angle vector, depending on the order of rotation.
See also: graphene_euler_get_z()
val get_beta : t -> floatRetrieves the second component of the Euler angle vector, depending on the order of rotation.
See also: graphene_euler_get_y()
val get_alpha : t -> floatRetrieves the first component of the Euler angle vector, depending on the order of rotation.
See also: graphene_euler_get_x()