Package ch.bailu.gtk.graphene
Klasse Box
java.lang.Object
ch.bailu.gtk.type.Type
ch.bailu.gtk.type.Pointer
ch.bailu.gtk.type.Record
ch.bailu.gtk.graphene.Box
- Alle implementierten Schnittstellen:
PointerInterface
A 3D box, described as the volume between a minimum and
a maximum vertices.
a maximum vertices.
-
Feldübersicht
Felder -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungstatic Box
allocBox()
Allocates a new #graphene_box_t.boolean
containsBox
(Box b) Checks whether the #graphene_box_t @a contains the given
#graphene_box_t @b.boolean
containsPoint
(Point3D point) Checks whether @box contains the given @point.static Box
empty()
A degenerate #graphene_box_t that can only be expanded.boolean
Checks whether the two given boxes are equal.void
Expands the dimensions of @box to include the coordinates at @point.void
expandScalar
(float scalar, Box res) Expands the dimensions of @box by the given @scalar value.void
expandVec3
(Vec3 vec, Box res) Expands the dimensions of @box to include the coordinates of the
given vector.void
free()
Frees the resources allocated by graphene_box_alloc().void
getBoundingSphere
(Sphere sphere) Computes the bounding #graphene_sphere_t capable of containing the given
#graphene_box_t.void
Retrieves the coordinates of the center of a #graphene_box_t.static ClassHandler
float
getDepth()
Retrieves the size of the @box on the Z axis.float
Retrieves the size of the @box on the Y axis.static int
void
Retrieves the coordinates of the maximum point of the given
#graphene_box_t.void
Retrieves the coordinates of the minimum point of the given
#graphene_box_t.static long
static TypeSystem.TypeSize
void
Retrieves the size of the box on all three axes, and stores
it into the given @size vector.static long
static TypeSystem.TypeSize
float
getWidth()
Retrieves the size of the @box on the X axis.static Box
infinite()
A degenerate #graphene_box_t that cannot be expanded.Initializes the given #graphene_box_t with two vertices.initFromBox
(Box src) Initializes the given #graphene_box_t with the vertices of
another #graphene_box_t.initFromVec3
(Vec3 min, Vec3 max) Initializes the given #graphene_box_t with two vertices
stored inside #graphene_vec3_t.boolean
intersection
(Box b, Box res) Intersects the two given #graphene_box_t.static Box
minusOne()
A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the
maximum vertex set at (0, 0, 0).static Box
one()
A #graphene_box_t with the minimum vertex set at (0, 0, 0) and the
maximum vertex set at (1, 1, 1).static Box
A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the
maximum vertex set at (1, 1, 1).void
Unions the two given #graphene_box_t.static Box
zero()
A #graphene_box_t with both the minimum and maximum vertices set at (0, 0, 0).Von Klasse geerbte Methoden ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Von Klasse geerbte Methoden ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Von Klasse geerbte Methoden java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Von Schnittstelle geerbte Methoden ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Felddetails
-
MIN
Private field: direct-type- Siehe auch:
-
MAX
Private field: direct-type- Siehe auch:
-
-
Konstruktordetails
-
Box
-
Box
public Box()
-
-
Methodendetails
-
getClassHandler
-
allocBox
Allocates a new #graphene_box_t.
The contents of the returned structure are undefined.- Gibt zurück:
- the newly allocated #graphene_box_t structure. Use graphene_box_free() to free the resources allocated by this function
-
containsBox
Checks whether the #graphene_box_t @a contains the given
#graphene_box_t @b.- Parameter:
b
- a #graphene_box_t- Gibt zurück:
- `true` if the box is contained in the given box
-
containsPoint
Checks whether @box contains the given @point.- Parameter:
point
- the coordinates to check- Gibt zurück:
- `true` if the point is contained in the given box
-
equal
Checks whether the two given boxes are equal.- Parameter:
b
- a #graphene_box_t- Gibt zurück:
- `true` if the boxes are equal
-
expand
Expands the dimensions of @box to include the coordinates at @point.- Parameter:
point
- the coordinates of the point to includeres
- return location for the expanded box
-
expandScalar
Expands the dimensions of @box by the given @scalar value.
If @scalar is positive, the #graphene_box_t will grow; if @scalar is
negative, the #graphene_box_t will shrink.- Parameter:
scalar
- a scalar valueres
- return location for the expanded box
-
expandVec3
Expands the dimensions of @box to include the coordinates of the
given vector.- Parameter:
vec
- the coordinates of the point to include, as a #graphene_vec3_tres
- return location for the expanded box
-
free
public void free()Frees the resources allocated by graphene_box_alloc(). -
getBoundingSphere
Computes the bounding #graphene_sphere_t capable of containing the given
#graphene_box_t.- Parameter:
sphere
- return location for the bounding sphere
-
getCenter
Retrieves the coordinates of the center of a #graphene_box_t.- Parameter:
center
- return location for the coordinates of the center
-
getDepth
public float getDepth()Retrieves the size of the @box on the Z axis.- Gibt zurück:
- the depth of the box
-
getHeight
public float getHeight()Retrieves the size of the @box on the Y axis.- Gibt zurück:
- the height of the box
-
getMax
Retrieves the coordinates of the maximum point of the given
#graphene_box_t.- Parameter:
max
- return location for the maximum point
-
getMin
Retrieves the coordinates of the minimum point of the given
#graphene_box_t.- Parameter:
min
- return location for the minimum point
-
getSize
Retrieves the size of the box on all three axes, and stores
it into the given @size vector.- Parameter:
size
- return location for the size
-
getWidth
public float getWidth()Retrieves the size of the @box on the X axis.- Gibt zurück:
- the width of the box
-
init
Initializes the given #graphene_box_t with two vertices.- Parameter:
min
- the coordinates of the minimum vertexmax
- the coordinates of the maximum vertex- Gibt zurück:
- the initialized #graphene_box_t
-
initFromBox
Initializes the given #graphene_box_t with the vertices of
another #graphene_box_t.- Parameter:
src
- a #graphene_box_t- Gibt zurück:
- the initialized #graphene_box_t
-
initFromVec3
Initializes the given #graphene_box_t with two vertices
stored inside #graphene_vec3_t.- Parameter:
min
- the coordinates of the minimum vertexmax
- the coordinates of the maximum vertex- Gibt zurück:
- the initialized #graphene_box_t
-
intersection
Intersects the two given #graphene_box_t.
If the two boxes do not intersect, @res will contain a degenerate box
initialized with graphene_box_empty().- Parameter:
b
- a #graphene_box_tres
- return location for the result- Gibt zurück:
- true if the two boxes intersect
-
union
Unions the two given #graphene_box_t.- Parameter:
b
- the box to union to @ares
- return location for the result
-
empty
A degenerate #graphene_box_t that can only be expanded.
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
infinite
A degenerate #graphene_box_t that cannot be expanded.
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
minusOne
A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the
maximum vertex set at (0, 0, 0).
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
one
A #graphene_box_t with the minimum vertex set at (0, 0, 0) and the
maximum vertex set at (1, 1, 1).
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
oneMinusOne
A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the
maximum vertex set at (1, 1, 1).
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
zero
A #graphene_box_t with both the minimum and maximum vertices set at (0, 0, 0).
The returned value is owned by Graphene and should not be modified or freed.- Gibt zurück:
- a #graphene_box_t
-
getTypeID
public static long getTypeID() -
getParentTypeID
public static long getParentTypeID() -
getTypeSize
-
getParentTypeSize
-
getInstanceSize
public static int getInstanceSize()
-