Documentation of 'jvx.volume.PgCubeSet' Java class
PgCubeSet ("JavaView Reference Manual")
"JavaView? v5.03.003"
jvx.volume

Class PgCubeSet

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, PsUpdateIf, PgGeometryIf


    public class PgCubeSet
    extends PgPointSet
    Base class for most geometric volumes of cubes formed by vertices. The class contains an array with cubes. Each cube is an instance of type PiVector containing indices of the vertices which are stored in the superclass PgPointSet. Additionally, there exist instance variables for cube normals, cube colors, cube texture coordinates, and other cube properties. Note, that such cube properties are not stored with each cube but each property is stored in an additional array of same length as the array of cubes. If a property is not available then the corresponding array is null.

    The dimension of all points is determined as argument of the constructor and cannot be changed later. See PgPointSet for details about allocation and access.

    The number of vertices per cube is the same for all cube of the cube set, each cube has eight vertices.

    There exist several utility functions to allocate and modify the number of cubes, for example,

            setNumCubes(int num)
     
    allocates num cubes. Internally, there exists a cache to reduce the number of actual memory allocations. The size of the cache is managed by protected methods.

    Whenever the number of cubes is changed, the class automatically adjusts the size of those cube properties which are currently in use, i.e. whose array is not null.

    Applications may modify the entries of a cube and of cube properties by direct method calls such as

            setCube(int, PiVector)
     
    which sets the cube with index ind equal to the components of a vector v by copying. Alternatively, if an application modifies a larger number of cubes then the application may prefer to obtain the cube array from the cube set and directly modify the array
     
    	PiVector [] cube = cubeSet.getCubes();
    	for (int i=0; i<cubeSet.getNumCubes(); i++)
    		cube[i].copy(v);
     
    The same choice is available for arrays containing cube properties. Note, that classes like PgCubeSet, may not reference all vertices, e.g. if the currently active cubes consists of a subset of all vertices. Also note, that the actual size of the cube array may differ from m_numCubes efficiency reasons. Therefore, do not use cube.length but use getNumCubes().

    This class contains mainly basic methods for memory allocation and access to instance variables. Geometric methods operating on cube sets such as computing a specific surface or computing the intersection of two surfaces are available in special workshop classes as extensions outside the base JavaView packages.

    A good starting to obtain further insight are methods like computeBox (if source code access to JavaView is available), or the tutorial applets of JavaView.

    See Also:
    Serialized Form
    Author:
    Ulrich Reitebuch
    Version:
    09.03.15, 2.00 revised (kp) Moved to jvx.volume from dev.volume.
    18.05.10, 1.00 created (ur) Created based on PgTetraSet.
    • Field Detail

      • LOCAL_EDGE_TO_VERTEX

        public static final int[][] LOCAL_EDGE_TO_VERTEX
        Local indices of the two vertices of all edges of cubes. This list provides an absolute ordering of all edges of a cube, for example, the k-th edge (k in {0,...,11}) connects the two vertices m_cube.m_data[LOCAL_EDGE_TO_VERTEX[k][0]] and m_cube.m_data[LOCAL_EDGE_TO_VERTEX[k][1]].
      • LOCAL_FACE_TO_VERTEX

        public static final int[][] LOCAL_FACE_TO_VERTEX
        Local indices of the four vertices of all faces of cubes. This list provides an absolute ordering of all faces of a cube, for example, the k-th face (k in {0,...,5}) connects the four vertices m_cube.m_data[LOCAL_FACE_TO_VERTEX[k][0]], m_cube.m_data[LOCAL_FACE_TO_VERTEX[k][1]], m_cube.m_data[LOCAL_FACE_TO_VERTEX[k][2]] and m_cube.m_data[LOCAL_FACE_TO_VERTEX[k][3]].
    • Constructor Detail

      • PgCubeSet

        public PgCubeSet()
        Constructor of a cube grid for a solid in three-dimensional space.

        This constructor allows to create a geometry by specifying the class name as string. By default, showing of vertices is enabled.

      • PgCubeSet

        public PgCubeSet(int aVertexDim)
        Constructor of a cube grid for a solid in a space of given dimension. This constructor should be preferred by all applications. By default, showing of vertices is disabled.
    • Method Detail

      • init

        public void init()
        Initialize and reset instance variables after call to super.init().
        Overrides:
        init in class PgPointSet
      • getJvx

        public PgJvxSrc getJvx()
        Fills a geometry object with data from this instance, for example, to print to file.
        Specified by:
        getJvx in interface PgGeometryIf
        Overrides:
        getJvx in class PgPointSet
        Returns:
        src a geometry source to be filled with data from this instance.
      • setJvx

        public void setJvx(PgJvxSrc src)
        Fill this instance with data from a geometry source, for example, previously read from file.

        If src geometry has missing neighbour information then method calculates neighbour information using makeNeighbour(), unless PsJavaView.m_bAutoNeighbour==false.

        // TODO: Cube normals??? // Is this just cut-and-paste stuff, or is it really done? If src geometry has missing cube normals then method calculates tetra normals using makeCubeNormals(), unless PsJavaView.m_bAutoNormals==false.

        Specified by:
        setJvx in interface PgGeometryIf
        Overrides:
        setJvx in class PgPointSet
        Parameters:
        src - a geometry source used to fill this instance with data.
        Version:
        07.04.02, 1.20 revised (kp) Adjust range of PuDouble/PuInteger variables.
        25.09.00, 1.10 revised (kp) Bug in handling of backface color removed.
      • applyModelingMatrix

        public boolean applyModelingMatrix()
        Multiply the modeling matrix to all vertices and vectors. The modeling matrix of this geometry is set to the identity matrix.
        Overrides:
        applyModelingMatrix in class PgPointSet
        Returns:
        true if operation was applied successfully.
        Since:
        JavaView 2.36
        Version:
        04.09.02, 1.00 created (kp)
      • clone

        public java.lang.Object clone()
        Duplicate geometry by recursively cloning all instance variables except inspector panels and lists of registered listeners. The parent relationship is maintained only within this class but not to external classes. In general, all links of the clone to external objects are set to null.
        Specified by:
        clone in interface PgGeometryIf
        Overrides:
        clone in class PgPointSet
        See Also:
        copy(PsObject)
        Version:
        27.07.03, 1.20 revised (kp) Missing assignment of parent to cloned backColor added.
        16.09.00, 1.10 revised (kp) Cloning of boundary curves added.
        05.07.00, 1.00 created (kp)
      • copy

        public void copy(PsObject object)
        Copy instance variables by duplication, not by copying a reference.

        The argument was changed from PgGeometry to PsObject since there were problems in J/Link which preferred to use jv.object.PsObject#copy(PsObject) instead of jv.project.PgGeometry#copy(PsObject).

        Overrides:
        copy in class PgPointSet
        See Also:
        clone()
        Version:
        08.11.02, 1.10 revised (kp) Argument changed to PsObject from PgGeometry.
      • copyCubeSet

        public void copyCubeSet(PgCubeSet geom)
        Copy instance variables of this class but not of its superclass.
      • copyConnectivity

        public void copyConnectivity(PgCubeSet geom)
        Copy connectivity of mesh, i.e. tetrahedra and neighbour array.
      • toString

        public java.lang.String toString()
        Create a multi-line string representation with detailed information about all instance variables.
        Specified by:
        toString in interface PgGeometryIf
        Overrides:
        toString in class PgPointSet
        Version:
        11.07.03, 1.10 revised (kp) Print tetra normals.
      • addCube

        public int addCube(PiVector cube)
        Add a new cube to the end of the cube list and increment the number of cubes. The neighbour array is automatically updated.

        If cube normals exist then the normal is calculated for the new cube too. Note, if vertex normals exist then the normals of the cube vertices are currently not recalculated (this behavior might change in the future).

        If cube colors exist then the color of the new cube is the global cube color. // TODO: New cube's neighbourhood is not yet computed.

        Parameters:
        cube - cube to be added to cube list
        Returns:
        int index of new cube in cube list
        Version:
        11.07.03, 2.20 revised (kp) Compute normal of new cube if normals exist.
        17.07.02, 2.10 revised (kp) Increase total size by 20 percent.
        26.05.02, 2.00 revised (kp) Create neighbour and color of new cube.
        05.12.00, 1.00 created (kp)
      • getGlobalCubeColor

        public java.awt.Color getGlobalCubeColor()
        Get global cube color which is used if no local colors are available.
      • getGlobalCubeTagColor

        public java.awt.Color getGlobalCubeTagColor()
        Get global color of tagged cubes.
      • setGlobalCubeColor

        public void setGlobalCubeColor(java.awt.Color color)
        Set global cube color to be used if no local colors are available.
      • setGlobalCubeTagColor

        public void setGlobalCubeTagColor(java.awt.Color color)
        Set global color of tagged cubes.
      • getGlobalEdgeColor

        public java.awt.Color getGlobalEdgeColor()
        Get global edge color which is used if no local colors are available.
      • getGlobalEdgeSize

        public double getGlobalEdgeSize()
        Get thickness in pixels of edge when drawn in display.
      • setGlobalEdgeColor

        public void setGlobalEdgeColor(java.awt.Color color)
        Set global edge color to be used if no local colors are available.
      • setGlobalEdgeSize

        public void setGlobalEdgeSize(double size)
        Set thickness in pixels of edge when drawn in display.
      • getGlobalBndColor

        public java.awt.Color getGlobalBndColor()
        Get global boundary color which is used if no local colors are available.
      • getGlobalBndTagColor

        public java.awt.Color getGlobalBndTagColor()
        Get global color of tagged boundaries.
      • setGlobalBndColor

        public void setGlobalBndColor(java.awt.Color color)
        Set global boundary color to be used if no local colors are available.
      • setGlobalBndTagColor

        public void setGlobalBndTagColor(java.awt.Color color)
        Set global color of tagged boundaries.
      • getCubes

        public PiVector[] getCubes()
        Get cube array for read and write access.

        Do not modify the size of any cube vector.

        Note, that the actual size of the array may be larger than m_numCubes for efficiency reasons. Therefore, do not use the length of array.

      • getCubeColors

        public java.awt.Color[] getCubeColors()
        Get cube color array for read and write access, but do not modify the size of any color vector. Note, that subclasses may not reference all cube colors. Also note, that the actual size of the color array may be larger than m_numCubes for efficiency reasons. Therefore, do not use length of array.
      • getCubeTexture

        public PdVector[] getCubeTexture(int ind)
        Get cube texture array of an individual cube. Returns null if no cube texture available, or index out of range.
        Since:
        JavaView 2.80.000
        Version:
        06.06.03, 1.00 created (kp)
      • getCubeTextures

        public PdVector[][] getCubeTextures()
        Get cube texture array for read and write access, but do not modify the size of any texture vector. Note, that subclasses may not reference all cube textures. Also note, that the actual size of the texture array may be larger than m_numCubes for efficiency reasons. Therefore, do not use length of array. Each cube has associated an array of 2-dimensional vectors with normalized texture coordinates.
      • getVertexTextures

        public PdVector[] getVertexTextures()
        Get array of all texture coordinates both for vertex and cube based textures. This method overwrites PgPointSet#getVertexTextures if texture is cube based.
        Overrides:
        getVertexTextures in class PgPointSet
        Returns:
        plain array of texture coordinates
      • getNeighbours

        public PiVector[] getNeighbours()
        Get neighbour array for read and write access, but do not modify the size of any neighbour vector. Also note, that the actual size of the array may be larger than m_numCubes for efficiency reasons. Therefore, do not use length of array.
      • getNumBoundaries

        public int getNumBoundaries()
        Return number of (living) boundary polygons. This number may be different from number of boundary components and number of boundary edges.
        Returns:
        number of boundary segments used
        See Also:
        PgTetraSet.getBoundaries()
        Author:
        Konrad Polthier
        Version:
        23.04.05, 2.00 revised (kp) Count boundaries only which are not deleted.
        16.09.98, 1.00 created (kp)
      • hasBoundary

        public boolean hasBoundary()
        Check whether surface has boundary polygons, assume boundary has been calculated. TODO: Check for boundary even if boundary polygons have not been calculated yet.
        Version:
        23.04.05, 2.00 revised (kp) No longer count boundaries which are marked deleted.
      • getBoundaries

        public PgCubeBndElementSet[] getBoundaries()
        Get array of boundary polygons, some of which may be marked inactive. If there does not exist a boundary then method returns array of zero length.
        Returns:
        a possibly empty array of boundary polygons. Array is never null.
        Version:
        23.04.05, 2.00 revised (kp) No longer return boundaries which are marked deleted.
      • removeBoundaries

        public void removeBoundaries()
        Remove all boundary surfaces.
        Version:
        11.12.04, 1.10 revised (kp) Explicitly remove link to this tetraSet before nulling bnd.
        16.09.00, 1.00 created (kp)
      • removeDeletedBoundaries

        public int removeDeletedBoundaries()
        Remove all boundary surfaces which are marked PsObject.IS_DELETED.
        Returns:
        number of deleted boundaries.
        Version:
        23.04.05, 1.00 created (kp)
      • setBoundary

        public void setBoundary(PgCubeBndElementSet[] newBnd)
        Set new boundary polygons by replacing the previous array with the argument array.
        Parameters:
        newBnd - array with new boundary polygons of tetra set.
        Version:
        16.09.00, 1.10 revised (kp) Use num of bnd polygons instead of bnd components.
      • assureBoundary

        public void assureBoundary(int num)
        Allocate boundary polygons and register current tetra set. If new number of polygons is smaller than old number then try to reuse old polygons.
      • isShowingEdges

        public boolean isShowingEdges()
        Determines whether drawing of cube edges is enabled.
      • showEdges

        public void showEdges(boolean flag)
        Set flag to enable drawing of cube edges.
      • isShowingEdgeColors

        public boolean isShowingEdgeColors()
        Determine whether showing of edge colors is enabled.
      • showEdgeColors

        public void showEdgeColors(boolean flag)
        Set flag to enable drawing of individual edge colors.
      • isShowingEdgeColorFromCubes

        public boolean isShowingEdgeColorFromCubes()
        Determines whether local edge color is induced from tetrahedron or vertex colors.
      • showEdgeColorFromCubes

        public void showEdgeColorFromCubes(boolean flag)
        Set flag if edge colors are induced from local cube or vertex colors.
      • isShowingSmoothEdgeColors

        public boolean isShowingSmoothEdgeColors()
        Determines whether smooth coloring of edges is enabled, currently requires vertex colors.
      • showSmoothEdgeColors

        public void showSmoothEdgeColors(boolean flag)
        Set flag to enable smooth coloring of edges, currently requires vertex colors.
      • isShowingEdgeColorFromVertices

        public boolean isShowingEdgeColorFromVertices()
        Determines whether smooth edge coloring uses vertex colors at vertices, requires vertex colors.
      • showEdgeColorFromVertices

        public void showEdgeColorFromVertices(boolean flag)
        Set flag to enable smooth edge coloring using vertex colors at vertices, requires vertex colors.
      • isShowingCubeLabels

        public boolean isShowingCubeLabels()
        Determines whether showing of cube labels is enabled.
      • isShowingCubes

        public boolean isShowingCubes()
        Determines whether drawing of cubes is enabled.
      • isShowingTaggedCubes

        public boolean isShowingTaggedCubes()
        Determines whether drawing of tagged cubes is enabled.
      • isShowingCubeTexture

        public boolean isShowingCubeTexture()
        Determines whether drawing of cube texture is enabled.
      • isShowingBoundaries

        public boolean isShowingBoundaries()
        Determines whether drawing of boundary curves is enabled.
      • isShowingTaggedBoundaries

        public boolean isShowingTaggedBoundaries()
        Determines whether drawing of tagged boundary curves is enabled.
      • isShowingCubeColors

        public boolean isShowingCubeColors()
        Determines whether global cube color is used.
      • isShowingSmoothLighting

        public boolean isShowingSmoothLighting()
        Determines whether smooth lighting is enabled, requires vertex normals.
      • showSmoothLighting

        public void showSmoothLighting(boolean flag)
        Set flag to enable smooth lighting, requires vertex normals.
      • isShowingSmoothCubeColors

        public boolean isShowingSmoothCubeColors()
        Determines whether smooth coloring of cubes is enabled, currently requires vertex colors.
      • showSmoothCubeColors

        public void showSmoothCubeColors(boolean flag)
        Set flag to enable smooth coloring of cubes, currently requires vertex colors.
      • isShowingCubeColorFromVertices

        public boolean isShowingCubeColorFromVertices()
        Determines whether smooth cube coloring uses vertex colors, requires vertex colors.
      • showCubeColorFromVertices

        public void showCubeColorFromVertices(boolean flag)
        Set flag to enable smooth cube coloring using vertex colors at vertices, requires vertex colors.
      • isShowingCubeFromVertexColors

        public boolean isShowingCubeFromVertexColors()
        Deprecated. since JavaView 4.60.001, use #isShowingCubeColorFromVertices()
        Determines whether smooth element coloring uses vertex colors, requires vertex colors.
      • showCubeFromVertexColors

        public void showCubeFromVertexColors(boolean flag)
        Deprecated. since JavaView 4.60.001, use #showingCubeColorFromVertices(boolean)
        Set flag to enable smooth element coloring using vertex colors at vertices, requires vertex colors.
      • showCubeLabels

        public void showCubeLabels(boolean flag)
        Set flag to enable drawing of cube labels in display.
      • showCubes

        public void showCubes(boolean flag)
        Set flag to enable drawing of cubes.
      • showTaggedCubes

        public void showTaggedCubes(boolean flag)
        Set flag to enable drawing of tagged cubes.
      • showCubeTexture

        public void showCubeTexture(boolean flag)
        Set flag to enable drawing of cube texture.
      • showVertexTexture

        public void showVertexTexture(boolean flag)
        Set flag to enable drawing of vertex texture. This method disables tetra texture whenever vertex texture is enabled, and vice versa.
        Overrides:
        showVertexTexture in class PgPointSet
      • showBoundaries

        public void showBoundaries(boolean flag)
        Set flag to enable drawing of boundary surfaces.
      • showTaggedBoundaries

        public void showTaggedBoundaries(boolean flag)
        Set flag to enable drawing of boundary surfaces.
      • showCubeColors

        public void showCubeColors(boolean flag)
        Set flag of using global tetrahedron color instead of coloring each cube individually.
      • getNumFaces

        public int getNumFaces()
        Get number of quad faces of cube set. TODO: currently always recomputes number of faces.
      • setNumFaces

        public void setNumFaces(int numFaces)
        Major memory allocation routine, all element allocation should be done here. Element and neighbour array are adjusted to new size. All element property arrays, such as element normals, are adjusted if they where allocated before. All element allocation is done in this method. Method should not be called directly unless a specific allocation is required. Usually, a user would specify the number of elements via setNumElements().
        Version:
        14.03.06, 2.00 revised (kp) Method made public to allow better control of allocations.
        14.03.03, 1.50 revised (kp) Increase number of vectors of vector field is available.
        19.12.00, 1.25 revised (kp) Reset neighbour array if number of elements is decreased.
        16.07.00, 1.20 revised (kp) Assure length of element textures if allocated.
        11.07.00, 1.10 revised (kp) Assure neighbours if dimOfElements==-1.
      • getMaxNumCubes

        public int getMaxNumCubes()
        Get total length of allocated tetrahedron array. Usually, only a subset is filled with data. Method is for internal use, see getNumCubes() for daily work.
      • setMaxNumCubes

        public void setMaxNumCubes(int numCubes)
        Major memory allocation routine, all cube allocation should be done here. Cube and neighbour array are adjusted to new size. All cube property arrays, such as cube normals, are adjusted if they where allocated before. All cube allocation is done in this method. Method should not be called directly unless a specific allocation is required. Usually, a user would specify the number of cubes via setNumCubes().
        Version:
        14.03.06, 2.00 revised (kp) Method made public to allow better control of allocations.
        14.03.03, 1.50 revised (kp) Increase number of vectors of vector field is available.
        19.12.00, 1.25 revised (kp) Reset neighbour array if number of cubes is decreased.
        16.07.00, 1.20 revised (kp) Assure length of cube textures if allocated.
        11.07.00, 1.10 revised (kp) Assure neighbours if dimOfCubes==-1.
      • getNumCubes

        public int getNumCubes()
        Get number of cubes in cube array. Note, that the actual size of the cube array may be larger for efficiency reasons. Therefore, do not use m_cube.length.
      • getNumCubeIndices

        public int getNumCubeIndices()
        Get total number of vertex entries in all cubes.
        Returns:
        int total number of all vertex indices of all cubes
      • setNumCubes

        public void setNumCubes(int numCubes)
        Allocate given number of cubes, and allocate normals, colors etc. if they already exist. Internally, there may exist more cubes than requested serving as buffer and to reduce allocation times.

        Note, the neighbour array might be initialized to -1 when its size changes.

        Version:
        18.04.10, 2.90 revised (kp) Invocation of setMaxNumTetras and check for instanceSharing adjusted to PgElementSet#setNumElements.
        11.12.04, 2.80 revised (kp) No longer update dimOfCubes of numCubes is reduced.
        05.08.04, 2.70 revised (kp) No action if same number is requested.
        24.07.03, 2.60 revised (kp) Cache of maxNumCubes reduced if numCubes too small.
        28.06.03, 2.50 revised (kp) Update dimOfCubes when numCubes is reduced.
        25.03.03, 2.10 revised (kp) Update vector fields too.
      • getDimOfCubes

        public int getDimOfCubes()
        Get number of vertices per cube which is constant 8.
      • setDimOfColors

        public void setDimOfColors(int aSize)
        Let all colors have same number of components aSize!=0.
        Overrides:
        setDimOfColors in class PgPointSet
        Parameters:
        aSize - Number of components of each color vector.
      • setDimOfVectors

        public void setDimOfVectors(int aSize)
        Let all vectors have same number of vectors aSize!=0. It is more efficient to call method before setNumVertices().
        Overrides:
        setDimOfVectors in class PgPointSet
        Parameters:
        aSize - Number of coordinates of each cube.
        See Also:
        PgPointSet.setDimOfVectors(int)
        Version:
        17.10.00, 2.00 revised (ep) Corrected bounds of loop for cube normals.
      • hasCubeColors

        public boolean hasCubeColors()
        Check if cube colors have been allocated.
        See Also:
        assureCubeColors()
      • hasCubeTextures

        public boolean hasCubeTextures()
        Check if cube textures have been allocated.
        See Also:
        assureCubeTextures()
      • assureCubeColors

        public void assureCubeColors()
        Assures respectively allocates correct length of cube color array. Length of array is equal to length of cube array.
      • assureCubeTextures

        public void assureCubeTextures()
        Assures respectively allocates correct length of cube texture array. Length of array is equal to length of cube array. Dimension of normal vectors is equal to getDimOfTextures().
        Version:
        24.06.05, 1.10 revised (kp) No longer remove vertex textures.
      • isShowingSmallCubes

        public boolean isShowingSmallCubes()
        Flag if shrunken cubes are shown.
      • showSmallCubes

        public void showSmallCubes(boolean flag)
        Set flag to show shrunken cubes.
      • makeCubeConn

        public void makeCubeConn(int uDiscr,
                                 int vDiscr,
                                 int wDiscr)
        Generates element and neighbourhood information for a cube volume. Method generates only topological information, no coordinates are required. For information about the generated tetrahedra see // TODO: Change the image??? // Numbering is slightly changed. microcube.gif.
        Parameters:
        uDiscr - An int with number of lines on x-axis.
        vDiscr - An int with number of lines on y-axis.
        wDiscr - An int with number of lines on z-axis.
        See Also:
        makeNeighbour()
        Version:
        23.06.07, 1.00 created (kp)
      • flipOrientation

        public void flipOrientation()
        Change orientation of all cubves and invert normal vectors.
        Overrides:
        flipOrientation in class PgPointSet
        See Also:
        PgPointSet.flipOrientation()
        Author:
        Konrad Polthier
        Version:
        15.06.06, 1.20 revised (kp) Direct replacement rules which avoid internal array allocations, missing inversion of tetra textures added.
        30.01.99, 1.05 revised (kp) Neighbour corrected.
        04.10.98, 1.02 revised (kp) Invert normals too.
        21.12.97, 1.01 revised (kp) Use invert().
        21.10.97, 1.00 created (kp)
      • getVertexValence

        public static PiVector getVertexValence(PgCubeSet geom)
        Compute valence of each vertex, that is, the number of incoming edges. This method requires correct neighbour information.
        Returns:
        vector with the valence of each vertex, its length equals the number of vertices.
      • buildCube

        public void buildCube(PdVector[] quadr,
                              int uDiscr,
                              int vDiscr,
                              int wDiscr)
        Creates a volume by trilinear interpolation of eight given vertices and given discretization. (For used order of indexing see macrocube.gif). Each micro cube is divided into six tetrahedra in makeCubeConn(int,int,int).
        Parameters:
        quadr - a PdVector array with the eight edge points
        uDiscr - an int with the number of knots for the first axis
        vDiscr - an int with the number of knots for the second axis
        wDiscr - an int with the number of knots for the third axis
        See Also:
        makeCubeConn(int,int,int)
      • getNumUnusedVertices

        public int getNumUnusedVertices()
        Get the number of unused vertices which are not references by cubes. // * This method is very cheap and should be
        Returns:
        number of unused vertices
        Author:
        Konrad Polthier
        Version:
        26.12.01, 1.00 revised (kp)
        26.12.01, 1.00 created (kp)
      • removeUnusedVertices

        public boolean removeUnusedVertices()
        Remove all points not referenced by cubes. First, the method computes where each point is moved to, then all point data is moved and the vertex indices are changed. This routine is O(n).
        Returns:
        true if method was successfull
        Author:
        Konrad Polthier
        Version:
        26.12.01, 1.50 revised (kp) Early quit if there are no unused vertices.
        17.12.00, 1.30 revised (ep) Handle vector fields.
        12.02.00, 1.20 revised (kp) Additional check whether bnd refers to valid vertices.
        17.10.99, 1.10 revised (kp) Rename from previous name compress(). Texture added.
        00.00.98, 1.00 created (kp)
      • removeMarkedVertices

        public int[] removeMarkedVertices()
        Remove vertices marked with tag PsObject#IS_DELETED from cubes. Remove all cubes containing a marked vertex, and remove all marked vertices. It is necessary to keep a valid cube set after removal of vertices in the superclass.
        Overrides:
        removeMarkedVertices in class PgPointSet
        Returns:
        array with indices of new positions of all previously existing vertices
        Version:
        22.04.02, 1.50 revised (kp) Update list of boundary vertices. 15.06.00, 1.00 created (kp)
      • removeCube

        public int[] removeCube(int ind)
        Remove cube with given index, and decrement index of all cubes with higher index. Method just marks cube with tag PsObject.IS_DELETED and invokes removeMarkedCubes().
        Parameters:
        ind - index of cube which is to be deleted
        Returns:
        Array with indices of new positions of all previously existing cubes
        Author:
        Konrad Polthier
        Version:
        20.07.00, 1.10 revised (kp) Return value changed to index array from boolean.
        14.07.00, 1.00 created (kp)
      • removeMarkedCubes

        public int[] removeMarkedCubes()
        Remove all cubes which have been marked PsObject.IS_DELETED. First, the method computes where each cube is moved to, then all cube data is moved and the references to the tetra in bnd curves is changed. This routine is O(n).

        Method assumes that there exist no references to marked cubes. Otherwise application of this method would lead to unpredictable results.

        Returns:
        Array with indices of new positions of all previously existing cubes
        Author:
        Konrad Polthier
        Version:
        17.12.00, 1.20 revised (ep) Handle vector fields.
        20.07.00, 1.10 revised (kp) Return value changed to index array from boolean.
        13.01.00, 1.01 revised (kp) Slight bug found by (ur) removed.
        17.10.99, 1.00 created (kp)
      • merge

        public boolean merge(PgGeometryIf aGeom)
        Merge cube set with current object and store union of both objects in 'this'. Number of points and cubes is the sum of both objects. List of boundary curves is the union of both objects, i.e. both objects are not identified along common boundary curves.

        The merged geometry will local colors allocated and assigned if

                        1. both the global color of both geometries are different, or
                        2. either geometry has local colors.
         
        If local colors are allocated but one of the geometries does not have local colors then its local colors are be assumed to be its global color. The merged geometry will show globalVertexColors if
                        1. the global color of both geometries is the same, and
                        2. both geometries are showing the global color.
         
        In all other cases the merged geometry will show local colors. The global color of the merged geometry is never changed.
        Specified by:
        merge in interface PgGeometryIf
        Overrides:
        merge in class PgPointSet
        Parameters:
        aGeom - tetraSet to be merged into 'this'
        Returns:
        true if method was successfull
        Author:
        Konrad Polthier
        Version:
        08.07.06, 2.50 revised (kp) Handling of edges implemented.
        12.09.02, 2.20 revised (kp) Merging of colors revised.
        01.10.01, 2.11 revised (ur) Set individual tetra colors to global color in a geometry, if only the other geometry has tetra colors.
        22.07.00, 2.10 revised (kp) Argument changed to class PgGeometryIf.
        15.06.00, 2.00 revised (kp) Argument changed to class PgGeometry.
        01.06.99, 1.01 revised (kp) Added missing assureCubeNormals(), -Colors().
        10.12.97, 1.00 created (kp)
      • getCubeWithEdge

        public int getCubeWithEdge(int vertexInd1,
                                   int vertexInd2)
        Find first cube with an edge whose two vertex indices are given. Modified version of PgElementSet#getElementWithEdge since for cubes we need to run through all edges of a cube.
      • clearTagCube

        public void clearTagCube(int ind,
                                 int aTag)
        Clear a single tag of a cube. For possible tags see PvGeometryIf.
      • hasTagCube

        public boolean hasTagCube(int ind,
                                  int aTag)
        Check whether cube has given tag. For possible tags see PvGeometryIf.
      • setTagCube

        public void setTagCube(int ind,
                               int aTag)
        Set a tag of a cube. For possible tags see PvGeometryIf.
      • getCubeVertices

        public PdVector[] getCubeVertices(int cubeInd)
        Get an array with pointers to all vertices of a cube. Vertices appear in the array in the same order as in the cube.
        Author:
        Konrad Polthier
        Version:
        08.06.99, 1.01 revised (kp) Cousin method removed allowing to pass vector array as argument.
        12.12.97, 1.00 created (kp)
      • getCube

        public PiVector getCube(int ind)
        Get a reference to an individual cube.
        Parameters:
        ind - index of cube
      • getNeighbour

        public PiVector getNeighbour(int ind)
        Get a reference to an individual neighbour vector.
        Parameters:
        ind - index of tetra
      • getCubeColor

        public java.awt.Color getCubeColor(int ind)
        Get a reference to an individual cube color.
        Parameters:
        ind - index of cube
      • setCubeVertices

        public boolean setCubeVertices(int elemInd,
                                       PdVector[] vArray)
        Copy new cube vertices at specified position in the vertex array of PgPointSet. Destination cube including data array must already exists.
        Parameters:
        elemInd - index of tetra
        vArray - array with new coordinates of cube vertices
        Returns:
        boolean false, if index out of range, or argument missing
        Version:
        12.12.97, 1.00 created (kp)
      • setCube

        public boolean setCube(int elemInd,
                               int[] anIndArray)
        Copy new vertex indices to cube at specified position in the cube list. Number of cubes is increased if required.
        Parameters:
        elemInd - index of cube
        anIndArray - array with new vertex indices of cube
        Returns:
        boolean false, if cube and array have different length
      • setCube

        public boolean setCube(int ind,
                               PiVector newCube)
        Copy new vertex indices to cube at specified position in the cube list. Number of cubes is increased if required.
        Parameters:
        ind - index of cube
        newCube - vector with new indices of cube
        Returns:
        boolean false, if cube and array have different
      • setNeighbour

        public boolean setNeighbour(int ind,
                                    PiVector newNeigh)
        Set neighbour cubes of given cube. Index must be a valid cube index, and length of neighbour entries must be 6.

        Usually, an applications calls makeNeighbour() instead of calling this low level method. This method is provided for efficiency.

        Parameters:
        ind - index of cube
        newNeigh - vector with indices of neighbour cubes
        Returns:
        boolean false in case of failure.
        Since:
        JavaView 3.24.001
        Version:
        16.05.04, 1.00 created (kp)
      • setCubeColor

        public boolean setCubeColor(int ind,
                                    java.awt.Color aColor)
        Copy new color to cube color at specified position in the color list
        Parameters:
        ind - index of cube
        aColor - color to be copied to color list
        Returns:
        boolean false, if index out of range, or argument missing
        Version:
        24.02.01, 1.10 revised (kp) Invoke assureCube...() only if destination array too small.
      • setCubeTexture

        public boolean setCubeTexture(int ind,
                                      PdVector[] aTexture)
        Copy new texture coordinates to cube texture at specified position in the cube texture list
        Parameters:
        ind - index of cube
        aTexture - array with texture coordinates to be copied
        Returns:
        boolean false, if index out of range, or argument missing
        Version:
        24.02.01, 1.10 revised (kp) Invoke assureCube...() only if destination array too small.
      • setCubes

        public void setCubes(PiVector[] cube)
        Copy the first getNumCubes() cubes of source array into an existing cube array. If source array is too small then abort operation. Assure size of neighbour array, but recomputation of neighbour information must be invoked explicitly using makeNeighbour().

        Parameters:
        cube - array of cube vectors to be copied
        Version:
        09.11.02, 2.00 revised (kp) Full revision handling cubes with 2 or less vertices.
        24.02.01, 1.10 revised (kp) Call assureNeighbours() only if new value of m_dimOfCubes==1.
      • removeCubeColors

        public void removeCubeColors()
        Remove local cube colors from a geometry and use global cube color instead.

        Showing of cube colors must be switched off explicitly using showCubeColors(boolean).

      • setCubeColors

        public void setCubeColors(java.awt.Color[] color)
        Copy cube colors of list to existing array of cube colors. Length of argument list must be equal or larger than getNumCubes().

        Showing of cube colors must be switched on in order to be visible.

        Parameters:
        color - array with new tetra colors
      • setCubeTextures

        public void setCubeTextures(PdVector[][] texCoords)
        Use the given textures coordinates as cube-based texture coordinates. Length of argument list must be equal or larger than getNumCubes(). All tetra textures are copied. The dimension of all argument textures must be equal to getDimOfTextures() of the geometry.

        Showing of textures must be switched on in order to be visible.

        Parameters:
        texCoords - array with new cube textures
        See Also:
        setCubeTexturesFromList(PdVector [])
      • setCubeTexturesFromList

        public void setCubeTexturesFromList(PdVector[] texCoords)
        Use the given textures coordinates as cube-based texture coordinates. Length of argument list must be equal or larger than getNumCubeIndices(). All textures coordinates are copied. The dimension of all argument texture vectors must be equal to getDimOfTextures() of the geometry.

        In contrast to the method setCubeTextures(PdVector [][]) the texture coordinates of the double vector are simply linearized, that means, if the first tetra has n-vertices, then the first n-textures coordinates are used as texture coordinates of this tetra.

        Showing of textures must be switched on in order to be visible.

        Parameters:
        texCoords - array with new tetra textures
        Since:
        JavaView 2.45
        See Also:
        setCubeTextures(PdVector [][])
        Version:
        09.11.02, 1.00 created (kp)
      • removeTexture

        public void removeTexture()
        Remove all texture information from volume and switch off showing of texture. Removes texture image and texture coordinates from cubes and vertices both.
        Overrides:
        removeTexture in class PgPointSet
        Version:
        25.01.02, 1.00 created (kp)
      • setNeighbours

        public void setNeighbours(PiVector[] neighbour)
        Copy neighbour array to existing array of neighbours. Length of argument list must be equal or larger than getNumCubes(). All neighbour information is copied.
        Parameters:
        neighbour - array with neighbour information
        See Also:
        makeNeighbour()
      • getNeighbourLocInd

        public int getNeighbourLocInd(int elemInd,
                                      int vInd,
                                      int wInd)
        For a given edge return the local index of the vertex containing the neighbourhood information. For triangles, return the local index of the third vertex in the tetra[anElem], i.e. the vertex not on the edge (vInd, wInd).

        Modified to handle tetras with more than three edges too. The 'neighbour vertex' is now defined as the place which stores the neighbourhood information for edge (vInd, wInd) in m_neighbour. If i is the lowest local index of both edge vertices, then i+elemLen-1 is the searched position. In case of a triangle, i+elemLen-1 == i+2, so nothing is changed for triangles.

        Parameters:
        vInd - index of first vertex of an tetra edge, not local indices
        wInd - index of second vertex of an tetra edge, not local indices
        elemInd - an tetra index
        Returns:
        local index of the vertex containing the neighbourhood information for given edge
        See Also:
        getOppVertexLocInd(int, int)
        Author:
        Konrad Polthier
        Version:
        03.09.99, 2.00 revised (kp) Renamed from getOtherVertexLocInd().
        11.04.99, 1.50 revised (kp) otherVertex redefined to allow general polygons, nothing changed in case of triangles. See documentation above.
        12.12.97, 1.00 created (kp)
      • getOppVertexInd

        public int getOppVertexInd(int cubeInd,
                                   int locInd)
        In the adjacent cube find the vertex containing the neighbourhood information for the original cube. Return the index of the vertex in the adjacent cube whose neighbour entry references to the original cube.
        Parameters:
        cubeInd - a cube index
        locInd - local index such that m_neighbour[elemInd].m_data[locInd]==neighElemInd is the adjacent cube.
        Returns:
        index of the vertex in adjacent cube containing the neighbourhood information for common face, or -1.
        See Also:
        getOppVertexLocInd(int, int)
        Author:
        Konrad Polthier
        Version:
        01.10.00, 1.10 revised (kp) Check if cube face is boundary.
        14.01.00, 1.00 created (kp)
      • getOppVertexLocInd

        public int getOppVertexLocInd(int cubeInd,
                                      int locInd)
        In the adjacent cube find the vertex containing the neighbourhood information for the original cube. Return the local index of the vertex in the adjacent cube whose neighbour entry references to the original cube. The 'otherVertex' is now defined as the place which stores the neighbourhood information for edge (vInd, wInd) in m_neighbour.

        Returns -2 in case of bug in neighbourhood. Use makeNeighbour() to create a new neighbourhood.

        Parameters:
        cubeInd - a cube index
        locInd - local index such that m_neighbour[elemInd].m_data[locInd]==neighElemInd is the adjacent cube.
        Returns:
        local index of the vertex in adjacent cube containing the neighbourhood information for common face.
        See Also:
        getNeighbourLocInd(int, int, int)
        Author:
        Konrad Polthier
        Version:
        22.06.07, 1.00 created (kp)
      • getEdgeLength

        public double getEdgeLength(int cubeInd,
                                    int locInd1,
                                    int locInd2)
        Compute length of cube edge specified by tetrahedron index and local vertex indices.
        Parameters:
        cubeInd - index of cube
        locInd1 - local index of first vertex
        locInd2 - local index of second vertex
        Returns:
        length of edge
        Author:
        Konrad Polthier
        Version:
        12.12.97, 1.00 created (kp)
      • getNumBoundaryFaces

        public int getNumBoundaryFaces()
        Calculate number of boundary Faces of a manifold solid using m_neighbour information. This number may be different from number of boundary components and number of boundary segments.

        If solid is non-manifold and neighbour information is not correct then this method may determine a wrong number of boundary faces.

        Returns:
        number of boundary faces
        See Also:
        PgTetraSet.getNumBoundaries()
        Author:
        Konrad Polthier
        Version:
        23.06.07, 1.00 created (kp)
      • getNumEdges

        public int getNumEdges()
        Calculate number of edges of a 3d triangulation using m_neighbour information.

        If neighbour information is missing, then each cube edge is counted.

        If surface is non-manifold and neighbour information is not correct then this method may determine a wrong number of edges.

        Returns:
        number of edges, inner edges counted once
        See Also:
        getNumBoundaryFaces()
        Author:
        Konrad Polthier
        Version:
        23.06.07, 1.00 created (kp)
      • getNumBoundaryVertices

        public int getNumBoundaryVertices()
        Count number of boundary vertices assuming boundary vertices have been previously marked.
        See Also:
        PgTetraSet.markBoundary()
        Author:
        Konrad Polthier
        Version:
        21.05.99, 1.00 revised (kp)
        21.05.99, 1.00 created (kp)
      • blend

        public boolean blend(double s,
                             PgGeometry ag,
                             double t,
                             PgGeometry bg)
        Blend between two cube sets, used in interpolation and computing the associate surfaces this = s*ag + t*bg.
        Specified by:
        blend in interface PgGeometryIf
        Overrides:
        blend in class PgPointSet
        Parameters:
        s - weight of vertices of first geometry
        ag - first geometry used for blending
        t - weight of vertices of second geometry
        bg - second geometry used for blending
        Returns:
        true on success
        Author:
        Konrad Polthier
        Version:
        08.07.06, 2.50 revised (kp) Handling of edges implemented.
        10.03.02, 2.10 revised (kp) Interpolation of vector fields implemented.
        10.11.01, 2.00 revised (kp) Interpolation of material properties enabled.
        30.12.97, 1.00 created (kp)
      • checkNeighbour

        public boolean checkNeighbour(boolean bMessage)
        Check correct neighbour connectivity. For each cube ensure that - length of each neighbour array is 6 - it does not reference itself - it is neighbour of each adjacent cube - it and its neighbour share a face with common vertices.
        Parameters:
        bMessage - Flag to send a message to the console.
        Returns:
        true if neighbour connectivity is correct
        Author:
        Konrad Polthier
        Version:
        28.01.02, 1.10 revised (ur) Flag added to avoid the Message to console.
        31.01.00, 1.01 revised (kp) Allow reference of adjacent tetrahedra even if differently oriented.
        31.10.98, 1.00 created (kp)
      • makeCubeColorsFromXYZ

        public boolean makeCubeColorsFromXYZ()
        Create color from the cube position within its bounding box which is interpreted as RGB cube. If dimension of vertices is smaller than three then only the first vertex components are used in the color computation.
        Author:
        Konrad Polthier
        Version:
        27.09.01, 1.10 revised (kp) Correct if vertex dimension larger than three.
        22.08.00, 1.00 created (kp)
      • makeCubeColorsFromZ

        public boolean makeCubeColorsFromZ()
        Create color from the vertical z-height within its bounding box ranging from low blue to high red. If dimension of vertices is smaller than three then the highest vertex component are used instead of the z-component in the color computation.
        Author:
        Konrad Polthier
        Version:
        16.04.05, 1.20 revised (kp) Both colors flipped to better sync with Maple.
        27.09.01, 1.10 revised (kp) Correct if vertex dimension larger than three.
        22.08.00, 1.00 created (kp)
      • makeCubeColorsFromZHue

        public boolean makeCubeColorsFromZHue()
        Create color from the vertical z-height within its bounding box ranging through hue rainbow. If dimension of vertices is smaller than three then the highest vertex component are used instead of the z-component in the color computation.
        Author:
        Konrad Polthier
        Version:
        17.04.05, 1.20 revised (kp) Expand color spectrum to [magenta,red] from [blue,red].
        27.09.01, 1.10 revised (kp) Correct if vertex dimension larger than three.
        22.08.00, 1.00 created (kp)
      • makeCubeFromVertexColors

        public boolean makeCubeFromVertexColors()
        Create tetra colors as average of all colors of its vertices. Vertex colors must be available.
        Author:
        Konrad Polthier
        Version:
        18.03.01, 1.00 created (kp)
      • makeVertexFromCubeColors

        public boolean makeVertexFromCubeColors()
        Create vertex colors as average of individual color of all adjacent cubes. Local tetra colors must be available.
        Author:
        Konrad Polthier
        Version:
        18.03.01, 1.00 created (kp)
      • makeCubeFromVertexTexture

        public boolean makeCubeFromVertexTexture()
        Create cube textures from vertex textures and remove vertex textures. Vertex textures must be available.
        Author:
        Ulrich Reitebuch
        Version:
        23.04.05, 1.10 revised (kp) Remove vertex textures after conversion.
        04.12.01, 1.00 created (ur)
      • reflect

        public PgGeometry reflect(PdMatrix mat,
                                  boolean bOrient,
                                  boolean bVector)
        Generate a cloned geometry and transform vertices by a matrix. For example, this method is called to calculate mirror images of a geometry. Orientation of geometry affects surface vectors.
        Specified by:
        reflect in interface PgGeometryIf
        Overrides:
        reflect in class PgPointSet
        Parameters:
        mat - 3*3 or 4*4 transformation matrix
        bOrient - flag whether to keep the orientation of the geometry
        bVector - flag whether to keep the orientation of vectors
        Returns:
        new reflected copy of the geometry
        Author:
        Konrad Polthier
        Version:
        20.03.01, 1.20 revised (kp) Neighbour array of reflected geometry corrected.
        12.12.00, 1.10 revised (kp) Additional argument added for orientation of vectors.
        16.11.00, 1.00 created (kp)
      • resetBoundaryNormals

        public boolean resetBoundaryNormals()
        Remove boundary vertex normal. Often boundary vertex normals can not be determined correctly. This method allows to reset these normal to zero. The boundary is determined from the neighbour information.
        Returns:
        false if vertex normals are missing
        Author:
        Konrad Polthier
        Version:
        29.05.01, 1.00 revised (kp)
        29.05.01, 1.00 created (kp)
      • getFVector

        public int[] getFVector()
        Compute F-vector which shows the number of points, edges, faces, etc.

        Note, the number of vertices may include some vertices which are not referenced by cubes. The number of unused vertices must be subtracted from the number of vertices found in the F-vector when computing the Euler characteristic.

        Overrides:
        getFVector in class PgPointSet
        Version:
        20.12.01, 1.10 revised (kp) Renamed to getFVector() from getEulerNumbers().
        04.11.01, 1.00 created (kp)
      • checkNeighbour

        public boolean checkNeighbour()
        Check correct neighbour connectivity. For each cube ensure that
        - it does not reference itself.
        - it is neighbour of each adjacent cube.
        - it and its neighbour join a face with common vertices.
        Returns:
        A boolean indicating if neighbour connectivity is correct (true).
      • computeBox

        public void computeBox(int numULines,
                               int numVLines,
                               int numWLines,
                               double uMin,
                               double vMin,
                               double wMin,
                               double uMax,
                               double vMax,
                               double wMax)
        Generates rectangular volume with given min/max values.
        Parameters:
        numULines - an int with the number of lines on the x-axis
        numVLines - an int with the number of lines on the y-axis
        numWLines - an int with the number of lines on the z-axis
        uMin - a double with the start value on the x-axis
        vMin - a double with the start value on the y-axis
        wMin - a double with the start value on the z-axis
        uMax - a double with the end value on the x-axis
        vMax - a double with the end value on the y-axis
        wMax - a double with the end value on the z-axis
        See Also:
        buildCube(PdVector[],int,int,int)
      • getSurface

        public PgElementSet getSurface(PgElementSet surface)
        Get the elements of the cube set.
        Returns:
        A PgElementSet with the surface.
      • makeEdgeStars

        public PgEdgeStar[] makeEdgeStars()
        Generate list of edges from element information of a possibly non-manifold surface. Method does not use neighbour information but computes the edge list solely based on information of the m_tetra array.

        The routine computes an array of edges temporarily in a single pass through all elements. Additionally, it stores the (1, 2, ..) elements sharing an edge.

        During edge collection, each edge is stored in the array edgesAtVertex at an index equal to the lowest of its two vertex indices. After the collection, each entry of edgesAtVertex is a vector containing those edges emanating from this vertex to vertices with higher vertex index. The entry at index i in edgesAtVertex is an array which contains all edges emanating from vertex with index i to vertices with higher index.

        This algorithm requires the array edgesAtVertex to have size equal to largest vertex index referenced from an element, but has a linear runtime when finding entries with identical edges. When collection is finished, usually some array entries will be null. The return parameter is an array of edges constructed from edgesAtVertex.

        If element set is non-manifold then the number of edges returned by this method may differ from the number which getNumEdgeStars() returns and getNumEdges() since the later relies on a correct neighbour information which is not used here.

        Returns:
        array with all edge, size equals number of edges.
        Author:
        Konrad Polthier
        Version:
        02.07.06, 3.00 revised (kp) Renamed to makeEdgeStars() from getEdgeList().
        17.09.00, 2.10 revised (kp) Bug removed in vertex counting, one vertex was missing.
        23.06.00, 2.00 revised (kp) List of edges changed from vector to array.
        22.08.99, 1.10 revised (kp) Method now also works if vertices haven't been created yet.
        10.04.99, 1.00 created (kp) Code taken from method makeNeighbour().
      • makeNeighbour

        public boolean makeNeighbour()
        Generate neighbourhood information for a given manifold polyhedron. The routine computes an array of faces temporarily in a single pass through all elements, and uses this information to fill out the neighbour instance variable. The diagrams Macrocube and Microcube detail this.
        Returns:
        boolean false, if polyhedron is not a manifold, i.e. a face is shared by more than two elements.
        Author:
        Konrad Polthier
        Version:
        21.12.00, 2.70 revised (kp) Edges with more than two elements all become boundary faces.
        10.04.99, 2.60 revised (kp) Edge construction moved into separate method.
        31.10.98, 2.50 revised (kp) Opposite vertex local index change from k+2 to k-1, no difference for triangulations
        16.09.98, 2.00 revised (kp) Optimized, O(n*n) replaced with O(n) algorithm
        23.11.97, 1.00 created (kp)
      • markBoundary

        public void markBoundary()
        Tag all boundary vertices as those. Assume a correct neighbour connectivity.
      • getEdgeVertex0

        public int getEdgeVertex0(int cubeIndex,
                                  int locEdgeInd)
        Get first vertex of the edge in given cube with given local edge index.
        Version:
        19.04.10, 1.00 created (mn)
      • getEdgeVertex1

        public int getEdgeVertex1(int cubeIndex,
                                  int locEdgeInd)
        Get first vertex of the edge in given cube with given local edge index.
        Version:
        19.04.10, 1.00 created (mn)
      • addElement

        public int addElement(PiVector el)
        Description copied from class: PgGeometry
        Method does nothing and may be overridden by subclasses.
        Specified by:
        addElement in interface PgGeometryIf
        Overrides:
        addElement in class PgGeometry
        Parameters:
        el - vector with indices of vertices in global vertex array
      • getCenterOfCube

        public PdVector getCenterOfCube(int c)
        Get center of a cube.
        Author:
        Matthias Nieser
        Version:
        15.09.2010, 1.00 created (mn)
"JavaView? v5.03.003"

"

The software JavaView? is copyright protected. All Rights Reserved.
"

You see the box below because you did not login.