-// Copyright (C) 2007-2008 CEA/DEN, EDF R&D
+// Copyright (C) 2007-2012 CEA/DEN, EDF R&D
//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
-// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
+
#ifndef __TRANSFORMED_TRIANGLE_HXX__
#define __TRANSFORMED_TRIANGLE_HXX__
#include "Log.hxx"
+#ifdef WNT
+#pragma warning(disable:4251)
+#endif
+
namespace INTERP_TEST
{
class TransformedTriangleTest;
namespace INTERP_KERNEL
{
+ class TetraAffineTransform;
/** \class TransformedTriangle
* \brief Class representing one of the faces of the triangulated source polyhedron after having been transformed
~TransformedTriangle();
double calculateIntersectionVolume();
+ double calculateIntersectionSurface(TetraAffineTransform* tat);
void dumpCoords() const;
// ----------------------------------------------------------------------------------
// High-level methods called directly by calculateIntersectionVolume()
// ----------------------------------------------------------------------------------
- void calculateIntersectionPolygons();
+ void calculateIntersectionAndProjectionPolygons();
void calculatePolygonBarycenter(const IntersectionPolygon poly, double* barycenter);
double calculateVolumeUnderPolygon(IntersectionPolygon poly, const double* barycenter);
+ // ----------------------------------------------------------------------------------
+ // High-level methods called directly by calculateIntersectionSurface()
+ // ----------------------------------------------------------------------------------
+ void calculateIntersectionPolygon();
+
+ double calculateSurfacePolygon();
+
// ----------------------------------------------------------------------------------
// Detection of degenerate triangles
// ----------------------------------------------------------------------------------
// Double and triple product calculations
// ----------------------------------------------------------------------------------
-
+ void resetNearZeroCoordinates();
bool areDoubleProductsConsistent(const TriSegment seg) const;