1 // Project MULTIPR, IOLS WP1.2.1 - EDF/CS
2 // Partitioning/decimation module for the SALOME v3.2 platform
5 * \file MULTIPR_PointOfField.hxx
7 * \brief Class PointOfField used for decimation. PointOfField = a point in a field = coordinates + value.
9 * \author Olivier LE ROUX - CS, Virtual Reality Dpt
14 #ifndef MULTIPR_POINTOFFIELD_HXX
15 #define MULTIPR_POINTOFFIELD_HXX
17 //*****************************************************************************
19 //*****************************************************************************
31 //*****************************************************************************
33 //*****************************************************************************
40 * Builds an empty set of elements (default constructor).
42 PointOfField() { reset(); }
46 * \param pX x-coordinate of the point.
47 * \param pY y-coordinate of the point.
48 * \param pZ z-coordinate of the point.
49 * \param pVal value of the field at the given point.
51 PointOfField(med_float pX, med_float pY, med_float pZ, med_float pVal)
60 * Destructor. Removes everything.
62 ~PointOfField() { reset(); }
65 * Resets this object in its state by default (empty).
69 mXYZ[0] = std::numeric_limits<med_float>::quiet_NaN();
70 mXYZ[1] = std::numeric_limits<med_float>::quiet_NaN();
71 mXYZ[2] = std::numeric_limits<med_float>::quiet_NaN();
72 mVal = std::numeric_limits<med_float>::quiet_NaN();
76 * Dumps any PointOfField to the given output stream.
77 * \param pOs any output stream.
78 * \param pP any PointOfField.
79 * \return the output stream pOs.
81 friend std::ostream& operator<<(std::ostream& pOs, PointOfField& pP)
83 pOs << "[ " << pP.mXYZ[0] << " ; " << pP.mXYZ[1] << " ; " << pP.mXYZ[2] << "]: " << pP.mVal;
89 med_float mXYZ[3]; /**< 3D-position. */
90 med_float mVal; /**< Value of the field on this point. */
92 }; // class PointOfField
95 } // namespace multipr
98 #endif // MULTIPR_FIELDPOINT_HXX