Class OBBToleranceColliderPtr


  • public class OBBToleranceColliderPtr
    extends java.lang.Object
    Ptr stores a pointer and optionally takes ownership of the value.
    • Constructor Detail

      • OBBToleranceColliderPtr

        public OBBToleranceColliderPtr​(long cPtr,
                                       boolean cMemoryOwn)
      • OBBToleranceColliderPtr

        public OBBToleranceColliderPtr()
        Default constructor yielding a NULL-pointer.
      • OBBToleranceColliderPtr

        public OBBToleranceColliderPtr​(OBBToleranceCollider ptr)
        Do not take ownership of ptr.

        ptr can be null.

        The constructor is implicit on purpose.
    • Method Detail

      • delete

        public void delete()
      • isShared

        public boolean isShared()
        check if this Ptr has shared ownership or none
        ownership
        Returns:
        true if Ptr has shared ownership, false if it has no ownership.
      • isNull

        public boolean isNull()
        checks if the pointer is null
        Returns:
        Returns true if the pointer is null
      • setTolerance

        public void setTolerance​(double tolerance)
        set the tolerance of the collider
        Parameters:
        tolerance - [in] meters
      • collides

        public boolean collides​(OBB obbA,
                                OBB obbB,
                                Transform3D aTb)
        test if obbA is closer than tolerance to obbB. The aTb transform describe
        obbB relative to obbA's coordinate frame. This method is approximate and the obb's
        may lie up to sqrt(tolerance^2+tolerance^2) away from each other.
      • collides

        public boolean collides​(OBB obbA,
                                OBB obbB,
                                Transform3D aTb,
                                double tolerance)
        test if obbA is closer than tolerance to obbB. The aTb transform describe
        obbB relative to obbA's coordinate frame. This method is approximate and the obb's
        may lie up to sqrt(tolerance^2+tolerance^2) away from each other.
      • inCollision

        public boolean inCollision​(OBB bvA,
                                   OBB bvB,
                                   Transform3D aTb)
        test if two bounding volumes are colliding
        Parameters:
        bvA - [in] bounding volume A
        bvB - [in] bounding volume B
        aTb - [in] transform from bvA to bvB
        Returns:
        true if in collision