package ocgtk
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha256=4e50fdb5093136a10fc8ffbe388e44cbcb70d52f8afdd48863ec7e22580ff054
doc/ocgtk.graphene/Ocgtk_graphene/Graphene/Wrappers/Plane/index.html
Module Wrappers.Plane
type t = [ `plane ] Gobject.objval alloc : unit -> tCreate a new Plane
val transform :
t ->
[ `matrix ] Gobject.obj ->
[ `matrix ] Gobject.obj option ->
tTransforms a #graphene_plane_t @p using the given @matrix and @normal_matrix.
If @normal_matrix is %NULL, a transformation matrix for the plane normal will be computed from @matrix. If you are transforming multiple planes using the same @matrix it's recommended to compute the normal matrix beforehand to avoid incurring in the cost of recomputing it every time.
Normalizes the vector of the given #graphene_plane_t, and adjusts the constant accordingly.
Negates the normal vector and constant of a #graphene_plane_t, effectively mirroring the plane across the origin.
val init_from_vec4 : t -> [ `vec4 ] Gobject.obj -> tInitializes the given #graphene_plane_t using the components of the given #graphene_vec4_t vector.
val init_from_points :
t ->
[ `point3_d ] Gobject.obj ->
[ `point3_d ] Gobject.obj ->
[ `point3_d ] Gobject.obj ->
tInitializes the given #graphene_plane_t using the 3 provided co-planar points.
The winding order is counter-clockwise, and determines which direction the normal vector will point.
val init_from_point :
t ->
[ `vec3 ] Gobject.obj ->
[ `point3_d ] Gobject.obj ->
tInitializes the given #graphene_plane_t using the given normal vector and an arbitrary co-planar point.
Initializes the given #graphene_plane_t using the normal vector and constant of another #graphene_plane_t.
val init : t -> [ `vec3 ] Gobject.obj option -> float -> tInitializes the given #graphene_plane_t using the given @normal vector and @constant values.
val get_normal : t -> [ `vec3 ] Gobject.objRetrieves the normal vector pointing towards the origin of the given #graphene_plane_t.
val get_constant : t -> floatRetrieves the distance along the normal vector of the given #graphene_plane_t from the origin.
val distance : t -> [ `point3_d ] Gobject.obj -> floatComputes the distance of @point from a #graphene_plane_t.