Package ch.bailu.gtk.graphene
Class Frustum
java.lang.Object
ch.bailu.gtk.type.Type
ch.bailu.gtk.type.Pointer
ch.bailu.gtk.type.Record
ch.bailu.gtk.graphene.Frustum
- All Implemented Interfaces:
PointerInterface
A 3D volume delimited by 2D clip planes.
The contents of the `graphene_frustum_t` are private, and should not be
modified directly.
The contents of the `graphene_frustum_t` are private, and should not be
modified directly.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic Frustum
Allocates a new #graphene_frustum_t structure.boolean
containsPoint
(Point3D point) Checks whether a point is inside the volume defined by the given
#graphene_frustum_t.boolean
Checks whether the two given #graphene_frustum_t are equal.void
free()
Frees the resources allocated by graphene_frustum_alloc().static ClassHandler
static int
static long
static TypeSystem.TypeSize
static long
static TypeSystem.TypeSize
Initializes the given #graphene_frustum_t using the provided
clipping planes.initFromFrustum
(Frustum src) Initializes the given #graphene_frustum_t using the clipping
planes of another #graphene_frustum_t.initFromMatrix
(Matrix matrix) Initializes a #graphene_frustum_t using the given @matrix.boolean
intersectsBox
(Box box) Checks whether the given @box intersects a plane of
a #graphene_frustum_t.boolean
intersectsSphere
(Sphere sphere) Checks whether the given @sphere intersects a plane of
a #graphene_frustum_t.Methods inherited from class ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Methods inherited from class ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Constructor Details
-
Frustum
-
-
Method Details
-
getClassHandler
-
allocFrustum
Allocates a new #graphene_frustum_t structure.
The contents of the returned structure are undefined.- Returns:
- the newly allocated #graphene_frustum_t structure. Use graphene_frustum_free() to free the resources allocated by this function.
-
containsPoint
Checks whether a point is inside the volume defined by the given
#graphene_frustum_t.- Parameters:
point
- a #graphene_point3d_t- Returns:
- `true` if the point is inside the frustum
-
equal
Checks whether the two given #graphene_frustum_t are equal.- Parameters:
b
- a #graphene_frustum_t- Returns:
- `true` if the given frustums are equal
-
free
public void free()Frees the resources allocated by graphene_frustum_alloc(). -
init
public Frustum init(@Nonnull Plane p0, @Nonnull Plane p1, @Nonnull Plane p2, @Nonnull Plane p3, @Nonnull Plane p4, @Nonnull Plane p5) Initializes the given #graphene_frustum_t using the provided
clipping planes.- Parameters:
p0
- a clipping planep1
- a clipping planep2
- a clipping planep3
- a clipping planep4
- a clipping planep5
- a clipping plane- Returns:
- the initialized frustum
-
initFromFrustum
Initializes the given #graphene_frustum_t using the clipping
planes of another #graphene_frustum_t.- Parameters:
src
- a #graphene_frustum_t- Returns:
- the initialized frustum
-
initFromMatrix
Initializes a #graphene_frustum_t using the given @matrix.- Parameters:
matrix
- a #graphene_matrix_t- Returns:
- the initialized frustum
-
intersectsBox
Checks whether the given @box intersects a plane of
a #graphene_frustum_t.- Parameters:
box
- a #graphene_box_t- Returns:
- `true` if the box intersects the frustum
-
intersectsSphere
Checks whether the given @sphere intersects a plane of
a #graphene_frustum_t.- Parameters:
sphere
- a #graphene_sphere_t- Returns:
- `true` if the sphere intersects the frustum
-
getTypeID
public static long getTypeID() -
getParentTypeID
public static long getParentTypeID() -
getTypeSize
-
getParentTypeSize
-
getInstanceSize
public static int getInstanceSize()
-