Class Shell

  • Direct Known Subclasses:
    IndexedFaceArray, QuadraticShell

    public class Shell
    extends GeometryData
    A shell represents the geometry of an object as a collection of non-connected faces.

    Each face is composed of a trimmed surface, the edge curves, and vertices that connects the
    edges. Contrary to the BREP representation, the shell representation holds no information
    about how each face is connected to the neighbouring faces.
    • Constructor Summary

      Constructors 
      Constructor Description
      Shell​(long cPtr, boolean cMemoryOwn)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void delete()  
      pair_d_d extremums​(Vector3D dir)
      Get the minimum and maximum values of the shell in a certain direction.
      static long getCPtr​(Shell obj)  
      FaceCPtr getFace​(long idx)
      Get a surface patch.
      void getFace​(long idx, GenericFace face)
      Get a surface patch.
      TriMeshPtr getTriMesh()
      gets a trimesh representation of this geometry data.

      The trimesh that is returned is by default a copy, which means
      ownership is transfered to the caller.
      TriMeshPtr getTriMesh​(boolean forceCopy)
      gets a trimesh representation of this geometry data.

      The trimesh that is returned is by default a copy, which means
      ownership is transfered to the caller.
      GeometryData.GeometryType getType()
      the type of this primitive
      boolean isConvex()
      test if this geometry data is convex
      OBB obb()
      Create Oriented Bounding Box (OBB) as a bounding volume for the shell.
      long size()
      Get the number of surface patches in this shell.
      • Methods inherited from class java.lang.Object

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

      • Shell

        public Shell​(long cPtr,
                     boolean cMemoryOwn)
    • Method Detail

      • getCPtr

        public static long getCPtr​(Shell obj)
      • getTriMesh

        public TriMeshPtr getTriMesh​(boolean forceCopy)
        Description copied from class: GeometryData
        gets a trimesh representation of this geometry data.

        The trimesh that is returned is by default a copy, which means
        ownership is transfered to the caller. Specifying forceCopy to false
        will enable copy by reference and ownership is not necesarilly transfered.
        This is more efficient, though pointer is only alive as long as this
        GeometryData is alive.

        Overrides:
        getTriMesh in class GeometryData
        Returns:
        TriMesh representation of this GeometryData
      • getTriMesh

        public TriMeshPtr getTriMesh()
        Description copied from class: GeometryData
        gets a trimesh representation of this geometry data.

        The trimesh that is returned is by default a copy, which means
        ownership is transfered to the caller. Specifying forceCopy to false
        will enable copy by reference and ownership is not necesarilly transfered.
        This is more efficient, though pointer is only alive as long as this
        GeometryData is alive.

        Overrides:
        getTriMesh in class GeometryData
        Returns:
        TriMesh representation of this GeometryData
      • isConvex

        public boolean isConvex()
        Description copied from class: GeometryData
        test if this geometry data is convex
        Overrides:
        isConvex in class GeometryData
        Returns:
        true if convex
      • size

        public long size()
        Get the number of surface patches in this shell.
        Returns:
        the number of surface patches.
      • getFace

        public FaceCPtr getFace​(long idx)
        Get a surface patch.
        Parameters:
        idx - [in] index of patch.
        Returns:
        a copy of the surface patch.
      • getFace

        public void getFace​(long idx,
                            GenericFace face)
        Get a surface patch.
        Parameters:
        idx - [in] index of patch.
        face - [out] existing face to copy data into.
      • extremums

        public pair_d_d extremums​(Vector3D dir)
        Get the minimum and maximum values of the shell in a certain direction.
        Parameters:
        dir - [in] the direction to find extremums for.
        Returns:
        the minimum and maximum as a pair of values.
      • obb

        public OBB obb()
        Create Oriented Bounding Box (OBB) as a bounding volume for the shell.
        Returns:
        the OBB.