24#ifndef _PB_REGULARCARTESIANGRID2D_
25#define _PB_REGULARCARTESIANGRID2D_
27#include <MeshViz/3Ddata/PbGrid2D.h>
83 SbBool isDataDuplicate=TRUE) ;
110 {
return !(m1 == m2); }
115 void setGeometry(
int num_x,
int num_y,
float x_min,
float y_min,
float x_max,
float y_max);
120 void setGeometry(
int num_x,
int num_y,
float x_min,
float y_min,
float x_max,
float y_max,
const float *z);
126 void getGeometry(
int &num_x,
int &num_y,
float &x_min,
float &y_min,
float &x_max,
float &y_max)
const;
133 void getGeometry(
int &num_x,
int &num_y,
float &x_min,
float &y_min,
float &x_max,
float &y_max,
const float *&z)
const;
180 void meshContouring(PiContouring *_PiContouring,
const float *z)
const;
182 void getLimits(
PoMesh2D *_PoMesh2D, Ppoint_list_list3 &limit)
const;
184 void getNodesCoord(
const float *z,
SoMFVec3f &vertices)
const;
185 virtual SbBool hasSidesNormals()
const;
186 virtual void getSidesNormals(
SbVec3f *&normals,
189 void print(FILE *fp)
const;
192 void constructXYGeometry(
float x_min,
float y_min,
float x_max,
float y_max,
SbBool is_data_duplicate);
193 void setXYGeometry(
int numX,
int numY,
const float *x,
const float *y);
194 void getXYGeometry(
const float* &x,
const float* &y)
const;
197 float m_x[2], m_y[2];
198 float m_xmin, m_xmax, m_dx;
199 float m_ymin, m_ymax, m_dy;
201 void updateBoundingBox()
const;
214 num_x = numX; x_min = m_xmin; x_max = m_xmax;
215 num_y = numY; y_min = m_ymin; y_max = m_ymax;
221 num_x = numX; x_min = m_xmin; x_max = m_xmax;
222 num_y = numY; y_min = m_ymin; y_max = m_ymax;
DTEXT Dynamic array of int .
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Defines an abstract cell...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Defines an abstract grid...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Defines a pixel cell of ...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Defines a quadrangle cel...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Defines a regular cartes...
void setGeometry(int num_x, int num_y, float x_min, float y_min, float x_max, float y_max, const float *z)
Defines a new 3D geometry.
virtual float getArea() const
Gets the area of the mesh.
virtual SbVec3f getNodeCoord(int nod_index) const
Gets the coordinates of a node defined by its index.
friend int operator!=(const PbRegularCartesianGrid2D &m1, const PbRegularCartesianGrid2D &m2)
Inequality comparison operator.
virtual const PbCell * findContainingCell(const SbVec3f &point, float tolerance, SbVec3f &pcoord) const
Find the mesh's cell that contains the point.
virtual const PbCell * getCell(int cell_index) const
Gets the cell which index is cell_index.
PbRegularCartesianGrid2D & operator=(const PbRegularCartesianGrid2D &mesh)
Assignment operator.
void getGeometry(int &num_x, int &num_y, float &x_min, float &y_min, float &x_max, float &y_max) const
Gets the mesh 2D geometry.
virtual SbVec3f getNodeCoord(int i, int j) const
Gets the coordinates of a node defined by its i,j indices on the grid.
virtual const PbCell * findContainingCell(const SbVec3f &point, float tolerance, SbVec3f &pcoord, const PbCell *adjacent_cell) const
PbRegularCartesianGrid2D(int num_x, int num_y, float x_min, float y_min, float x_max, float y_max, const float *z, SbBool isDataDuplicate=TRUE)
Constructor of a 3D regular grid mesh.
~PbRegularCartesianGrid2D()
Destructor.
void setGeometry(int num_x, int num_y, float x_min, float y_min, float x_max, float y_max)
Defines a new 2D geometry.
PbRegularCartesianGrid2D(const PbRegularCartesianGrid2D &mesh)
Copy constructor.
friend int operator==(const PbRegularCartesianGrid2D &m1, const PbRegularCartesianGrid2D &m2)
Equality comparison operator.
PbRegularCartesianGrid2D(int num_x, int num_y, const PbRegularCartesianGrid2D &other_mesh)
Constructor of a regular grid mesh, by refining the given other_mesh.
PbRegularCartesianGrid2D(int num_x, int num_y, float x_min, float y_min, float x_max, float y_max, SbBool isDataDuplicate=TRUE)
Constructor of a 2D regular grid mesh.
PbRegularCartesianGrid2D(SbBool isDataDuplicate=TRUE)
Constructor of a default simple mesh.
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Base class for all surfa...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Representation of vector...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Filled representation of...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Representation of the ed...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Class to build the sides...
Multiple-value field containing any number of three-dimensional vectors.