Create a new {@link FrustumIntersection} from the given {@link Matrix4d matrix} by extracing the matrix's frustum planes. <p> In order to update the compute frustum planes later on, call {@link #set(Matrix4d)}.
Create a new {@link FrustumIntersection} from the given {@link Matrix4d matrix} by extracing the matrix's frustum planes. <p> In order to update the compute frustum planes later on, call {@link #set(Matrix4d)}.
Compute the signed distance from the given axis-aligned box to the <code>plane</code>.
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its <code>min</code> and <code>max</code> corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its min and max corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its <code>min</code> and <code>max</code> corner coordinates. <p> This method differs from {@link #intersectAab(Vector3d, Vector3d)} in that it allows to mask-off planes that should not be calculated. For example, in order to only test a box against the left frustum plane, use a mask of {@link #PLANE_MASK_NX}. Or in order to test all planes <i>except</i> the left plane, use a mask of <code>(~0 ^ PLANE_MASK_NX)</code>. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its min and max corner coordinates. <p> This method differs from {@link #intersectAab(double, double, double, double, double, double)} in that it allows to mask-off planes that should not be calculated. For example, in order to only test a box against the left frustum plane, use a mask of {@link #PLANE_MASK_NX}. Or in order to test all planes <i>except</i> the left plane, use a mask of <code>(~0 ^ PLANE_MASK_NX)</code>. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its <code>min</code> and <code>max</code> corner coordinates. <p> This method differs from {@link #intersectAab(Vector3d, Vector3d)} in that it allows to mask-off planes that should not be calculated. For example, in order to only test a box against the left frustum plane, use a mask of {@link #PLANE_MASK_NX}. Or in order to test all planes <i>except</i> the left plane, use a mask of <code>(~0 ^ PLANE_MASK_NX)</code>. <p> In addition, the <code>startPlane</code> denotes the first frustum plane to test the box against. To use this effectively means to store the plane that previously culled an axis-aligned box (as returned by <code>intersectAab()</code>) and in the next frame use the return value as the argument to the <code>startPlane</code> parameter of this method. The assumption is that the plane that culled the object previously will also cull it now (temporal coherency) and the culling computation is likely reduced in that case. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Determine whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler and, if the box is not inside this frustum, return the index of the plane that culled it. The box is specified via its min and max corner coordinates. <p> This method differs from {@link #intersectAab(double, double, double, double, double, double)} in that it allows to mask-off planes that should not be calculated. For example, in order to only test a box against the left frustum plane, use a mask of {@link #PLANE_MASK_NX}. Or in order to test all planes <i>except</i> the left plane, use a mask of <code>(~0 ^ PLANE_MASK_NX)</code>. <p> In addition, the <code>startPlane</code> denotes the first frustum plane to test the box against. To use this effectively means to store the plane that previously culled an axis-aligned box (as returned by <code>intersectAab()</code>) and in the next frame use the return value as the argument to the <code>startPlane</code> parameter of this method. The assumption is that the plane that culled the object previously will also cull it now (temporal coherency) and the culling computation is likely reduced in that case. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Determine whether the given sphere is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for spheres that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Determine whether the given sphere is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns {@link #INTERSECT} for spheres that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Update the stored frustum planes of <code>this</code> {@link FrustumIntersection} with the given {@link Matrix4d matrix}. <p> Reference: <a href="http://gamedevs.org/uploads/fast-extraction-viewing-frustum-planes-from-world-view-projection-matrix.pdf"> Fast Extraction of Viewing Frustum Planes from the World-View-Projection Matrix</a>
Update the stored frustum planes of <code>this</code> {@link FrustumIntersection} with the given {@link Matrix4d matrix} and allow to optimize the frustum plane extraction in the case when no intersection test is needed for spheres. <p> Reference: <a href="http://gamedevs.org/uploads/fast-extraction-viewing-frustum-planes-from-world-view-projection-matrix.pdf"> Fast Extraction of Viewing Frustum Planes from the World-View-Projection Matrix</a>
Test whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. The box is specified via its <code>min</code> and <code>max</code> corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Test whether the given axis-aligned box is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. The box is specified via its min and max corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for boxes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Test whether the given line segment, defined by the end points <code>a</code> and <code>b</code>, is partly or completely within the frustum defined by <code>this</code> frustum culler.
Test whether the given line segment, defined by the end points <code>(aX, aY, aZ)</code> and <code>(bX, bY, bZ)</code>, is partly or completely within the frustum defined by <code>this</code> frustum culler.
Test whether the given XY-plane (at <code>Z = 0</code>) is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. The plane is specified via its <code>min</code> and <code>max</code> corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for planes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Test whether the given XY-plane (at <code>Z = 0</code>) is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. The plane is specified via its min and max corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for planes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Test whether the given XZ-plane (at <code>Y = 0</code>) is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. The plane is specified via its min and max corner coordinates. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for planes that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem. <p> Reference: <a href="http://old.cescg.org/CESCG-2002/DSykoraJJelinek/">Efficient View Frustum Culling</a>
Test whether the given point is within the frustum defined by <code>this</code> frustum culler.
Test whether the given point <code>(x, y, z)</code> is within the frustum defined by <code>this</code> frustum culler.
Test whether the given sphere is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for spheres that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Test whether the given sphere is partly or completely within or outside of the frustum defined by <code>this</code> frustum culler. <p> The algorithm implemented by this method is conservative. This means that in certain circumstances a <i>false positive</i> can occur, when the method returns <code>true</code> for spheres that do not intersect the frustum. See <a href="http://iquilezles.org/www/articles/frustumcorrect/frustumcorrect.htm">iquilezles.org</a> for an examination of this problem.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads indicating that the axis-aligned box is fully inside of the frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads indicating that the axis-aligned box intersects the frustum.
Return value of {@link #intersectSphere(Vector3d, double)} or {@link #intersectSphere(double, double, double, double)} indicating that the sphere is completely outside of the frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>x=-1</code> when using the identity frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>y=-1</code> when using the identity frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>z=-1</code> when using the identity frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>x=1</code> when using the identity frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>y=1</code> when using the identity frustum.
The value in a bitmask for {@link #intersectAab(double, double, double, double, double, double, int) intersectAab()} that identifies the plane with equation <code>z=1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>x=-1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>y=-1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>z=-1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>x=1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>y=1</code> when using the identity frustum.
Return value of {@link #intersectAab(double, double, double, double, double, double) intersectAab()} and its different overloads identifying the plane with equation <code>z=1</code> when using the identity frustum.
Efficiently performs frustum intersection tests by caching the frustum planes of an arbitrary transformation {@link Matrix4d matrix}. <p> This class is preferred over the frustum intersection methods in {@link Matrix4d} when many objects need to be culled by the same static frustum.
@author Kai Burjack