Package com.openinventor.meshviz.data
Class PbCell
java.lang.Object
com.openinventor.inventor.Inventor
com.openinventor.meshviz.graph.PbBase
com.openinventor.meshviz.data.PbCell
- Direct Known Subclasses:
PbHexahedronCell,PbPixelCell,PbPyramidCell,PbQuadrangleCell,PbTetrahedronCell,PbTriangleCell,PbVoxelCell,PbWedgeCell
Defines an abstract cell of a mesh.
A cell is a "simple" basic volume or surface element that connects adjacent nodes of a mesh.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand -
Field Summary
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle -
Method Summary
Modifier and TypeMethodDescriptionfloatgetArea()Gets the area of a cell.Gets the cell's bounding box.float[]Gets the cell's bounds.Gets the cell's geometric center.intgetIndex()Gets the index of the cell in the mesh.floatGets the length of the longest edge of the cell.getNodeCoord(int nod) Gets the coordinate of the nod (nod must be >=0 and <getNumNodes()).intgetNodeIndex(int nod) Gets the index (in the mesh) of a nod (nod must be >=0 and <getNumNodes()).intGets the number of edges.intGets the number of facets.intGets the number of nodes.floatgetValue(float[] weight, float[] s) Gets the scalar value of a point in this cell, given the point's weights.Gets the vector value of a point in this cell, given the point's weights.floatGet the scalar value of a point in the cell.Get the vector value of a point in the cell.floatGets the volume of the cell.locatePoint(SbVec3f coord, float tolerance) Returns 1 if the point is inside the cell, 0 otherwise.Methods inherited from class com.openinventor.meshviz.graph.PbBase
enableConnection, isConnectionEnabled, touchMethods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
Method Details
-
getValue
public float getValue(float[] weight, float[] s) Gets the scalar value of a point in this cell, given the point's weights. -
getBoundingBox
Gets the cell's bounding box. -
getLongestEdgeLength
public float getLongestEdgeLength()Gets the length of the longest edge of the cell. -
getValue
Gets the vector value of a point in this cell, given the point's weights. -
getValue
Get the vector value of a point in the cell.- Parameters:
pcoord- [in] Parametric [0..1] coordinate of the point inside the cell.v- [in] The vector dataset to interpolate- Returns:
- The interpolated value
-
getNumEdges
public int getNumEdges()Gets the number of edges. -
getNumFacets
public int getNumFacets()Gets the number of facets. -
getNodeCoord
Gets the coordinate of the nod (nod must be >=0 and <getNumNodes()). -
getNodeIndex
public int getNodeIndex(int nod) Gets the index (in the mesh) of a nod (nod must be >=0 and <getNumNodes()). -
getNumNodes
public int getNumNodes()Gets the number of nodes. -
getIndex
public int getIndex()Gets the index of the cell in the mesh. -
getCenter
Gets the cell's geometric center. -
getBounds
public float[] getBounds()Gets the cell's bounds. Similar togetBoundingBox()but it does not use any SbBox object. -
getValue
Get the scalar value of a point in the cell.- Parameters:
pcoord- [in] Parametric [0..1] coordinate of the point inside the cell.s- [in] The scalar dataset to interpolate- Returns:
- The interpolated value
-
getArea
public float getArea()Gets the area of a cell. -
getVolume
public float getVolume()Gets the volume of the cell. Returns always 0 for a 2D cell. -
locatePoint
Returns 1 if the point is inside the cell, 0 otherwise. Gets also the parametric coordinate of the point and its weights
-