Class FacePtr


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

      Constructors 
      Constructor Description
      FacePtr()
      Default constructor yielding a NULL-pointer.
      FacePtr​(long cPtr, boolean cMemoryOwn)  
      FacePtr​(Face ptr)
      Do not take ownership of ptr.

      ptr can be null.

      The constructor is implicit on purpose.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Face __ref__()
      Dereferencing operator.
      FaceCPtr cptr()  
      long curveCount()
      Get the number of curves in the face.
      void delete()  
      Face deref()
      The pointer stored in the object.
      boolean equals​(Face p)  
      pair_d_d extremums​(Vector3D dir)
      Find the extent of the surface along a specific direction.
      static long getCPtr​(FacePtr obj)  
      Curve getCurve​(long i)
      Get a curve of the face.
      Face getDeref()
      Member access operator.
      TriMeshPtr getTriMesh()
      Create a TriMesh representation of the face.

      This function relies on the resolution set with setMeshResolution.
      The resolution is passed on to Curve::discretizeAdaptive and
      Surface::setDiscretizationResolution.


      TriMeshPtr getTriMesh​(boolean forceCopy)
      Create a TriMesh representation of the face.

      This function relies on the resolution set with setMeshResolution.
      The resolution is passed on to Curve::discretizeAdaptive and
      Surface::setDiscretizationResolution.

      boolean isNull()
      checks if the pointer is null
      boolean isShared()
      check if this Ptr has shared ownership or none
      ownership
      OBB obb()
      Create Oriented Bounding Box.

      The default implementation forms a TriMesh in order to estimate the directions for the
      OBB.

      void setMeshResolution​(double resolution)
      Set the resolution used for discretization in the getTriMesh and faceTriMesh
      functions.

      The meaning of this parameter depends on the type of surface.

      Surface surface()
      Get the surface of the face.
      void transform​(Transform3D T)
      Transform the face.
      void transform​(Vector3D P)
      Translation of face.
      SWIGTYPE_p_std__vectorT_rw__math__Vector3DT_double_t_t vertices()
      Get the vertices of the face.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FacePtr

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

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

        public FacePtr​(Face ptr)
        Do not take ownership of ptr.

        ptr can be null.

        The constructor is implicit on purpose.
    • Method Detail

      • getCPtr

        public static long getCPtr​(FacePtr obj)
      • delete

        public void delete()
      • deref

        public Face deref()
        The pointer stored in the object.
      • __ref__

        public Face __ref__()
        Dereferencing operator.
      • getDeref

        public Face getDeref()
        Member access operator.
      • equals

        public boolean equals​(Face p)
      • 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
      • surface

        public Surface surface()
        Get the surface of the face.
        Returns:
        a reference to the surface data.
      • curveCount

        public long curveCount()
        Get the number of curves in the face.
        Returns:
        the number of curves.
      • getCurve

        public Curve getCurve​(long i)
        Get a curve of the face.
        Parameters:
        i - [in] the curve index, which should be less than the number returned by
        curveCount().
        Returns:
        a reference to the curve data.
      • transform

        public void transform​(Transform3D T)
        Transform the face.
        Parameters:
        T - [in] transform.
      • transform

        public void transform​(Vector3D P)
        Translation of face.
        Parameters:
        P - [in] translation vector.
      • getTriMesh

        public TriMeshPtr getTriMesh​(boolean forceCopy)
        Create a TriMesh representation of the face.

        This function relies on the resolution set with setMeshResolution.
        The resolution is passed on to Curve::discretizeAdaptive and
        Surface::setDiscretizationResolution.

        Parameters:
        forceCopy - [in] (not currently used in default implementation)
        Returns:
        a new TriMesh.
      • getTriMesh

        public TriMeshPtr getTriMesh()
        Create a TriMesh representation of the face.

        This function relies on the resolution set with setMeshResolution.
        The resolution is passed on to Curve::discretizeAdaptive and
        Surface::setDiscretizationResolution.


        Returns:
        a new TriMesh.
      • extremums

        public pair_d_d extremums​(Vector3D dir)
        Find the extent of the surface along a specific direction.
        Parameters:
        dir - [in] a normalized direction vector.
        Returns:
        the minimum and maximum values along the given direction.
      • obb

        public OBB obb()
        Create Oriented Bounding Box.

        The default implementation forms a TriMesh in order to estimate the directions for the
        OBB.

        Returns:
        an OBB around the Face.
      • setMeshResolution

        public void setMeshResolution​(double resolution)
        Set the resolution used for discretization in the getTriMesh and faceTriMesh
        functions.

        The meaning of this parameter depends on the type of surface.

        Parameters:
        resolution - [in] the resolution parameter.