#include "SALOME_ExtractGeometry.h"
-#include <limits.h>
+#include <float.h>
#include <vtkObjectFactory.h>
#include <vtkDataSetMapper.h>
thePlane->GetOrigin(anOrigin);
::PositionToDistance(GetInput(),theDir,anOrigin,theDist);
}
+
+//=======================================================================
+//function : IsPlanarInput
+//purpose :
+//=======================================================================
+
+bool VISU_PipeLine::IsPlanarInput() const
+{
+ float aBounds[6];
+ GetInput()->GetBounds( aBounds ); // xmin,xmax, ymin,ymax, zmin,zmax
+ if (fabs( aBounds[0] - aBounds[1] ) <= FLT_MIN ||
+ fabs( aBounds[2] - aBounds[3] ) <= FLT_MIN ||
+ fabs( aBounds[4] - aBounds[5] ) <= FLT_MIN )
+ return true;
+
+ return false;
+}
+
virtual void SetInput(TInput* theInput);
virtual TInput* GetInput() const;
+ bool IsPlanarInput() const;
+
typedef vtkDataSetMapper TMapper;
virtual TMapper* GetMapper();