Package com.openinventor.meshviz.data
Class PbGrid3D
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.meshviz.graph.PbBase
-
- com.openinventor.meshviz.data.PbMesh
-
- com.openinventor.meshviz.data.PbMesh3D
-
- com.openinventor.meshviz.data.PbGrid3D
-
- Direct Known Subclasses:
PbCartesianGrid3D
,PbRegularCartesianGrid3D
public class PbGrid3D extends PbMesh3D
Defines an abstract grid volume mesh. This class defines a mesh of which topology is a regular grid made of num_x * num_y * num_z nodes. Each node with index (i,j,k) in the mesh (except for points along the mesh border) is connected to six points with indices (i+1,j,k), (i,j+1,k), (i-1,j,k), (i,j-1,k), (i,j,k-1), (i,j,k+1).The values on the mesh nodes are defined by the
PbMesh.addValuesSet()
method, where argument val is an array of num_x * num_y * num_z floats.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openinventor.meshviz.data.PbMesh
PbMesh.CellBox, PbMesh.ContainingCell, PbMesh.CoordinatesInfo, PbMesh.DataBindings
-
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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int[]
getCellIndices(int cell_index)
Calculates indices i,j,k that verify cell_index = (i*(num_y-1) + j)*(num_z-1) + k.int[]
getDim()
Gets the dimensions num_x, num_y, num_z of the grid.SbVec3f
getNodeCoord(int i, int j, int k)
Gets the coordinates of a node defined by its i,j,k indices on the grid.int[]
getNodeIndices(int nod_index)
Calculates indices i,j,k that verify (i*num_y + j)*num_z + k.void
setGeometry(int num_x, int num_y, int num_z, float[] x, float[] y, float[] z)
Defines a volume mesh geometry.-
Methods inherited from class com.openinventor.meshviz.data.PbMesh
addStringsSet, addStringsSet, addValuesSet, addValuesSet, addValuesSet, addValuesSet, addVecsSet, addVecsSet, findContainingCell, findContainingCell, getArea, getBiggestCellBox, getBoundingBox, getCell, getCoordinates, getDirectValuesSet, getDirectVecsSet, getMaxValuesSet, getMaxVecsSet, getMinValuesSet, getMinVecsSet, getNodeCoord, getNumCells, getNumNodes, getNumStringsSet, getNumValuesSet, getNumVecsSet, getSmallestCellBox, getStringsSetName, getValuesBinding, getValuesSet, getValuesSetName, getVecsSet, getVecsSetName, getVolume, isDataDuplicated, removeAllStringsSet, removeAllValuesSet, removeAllVecsSet, removeStringsSet, removeValuesSet, removeVecsSet, setCoordinates
-
Methods inherited from class com.openinventor.meshviz.graph.PbBase
enableConnection, isConnectionEnabled, touch
-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Method Detail
-
getNodeIndices
public int[] getNodeIndices(int nod_index)
Calculates indices i,j,k that verify (i*num_y + j)*num_z + k.
-
getDim
public int[] getDim()
Gets the dimensions num_x, num_y, num_z of the grid.
-
getNodeCoord
public SbVec3f getNodeCoord(int i, int j, int k)
Gets the coordinates of a node defined by its i,j,k indices on the grid.
-
getCellIndices
public int[] getCellIndices(int cell_index)
Calculates indices i,j,k that verify cell_index = (i*(num_y-1) + j)*(num_z-1) + k.
-
setGeometry
public void setGeometry(int num_x, int num_y, int num_z, float[] x, float[] y, float[] z)
Defines a volume mesh geometry. The size of the x array depends on the derived class that calls this method. It is either num_x or num_x * num_y * num_z. Idem for y and z array.
-
-