GetDir(aDir[1],myAng[1],myBasePlane[1]);
VISU_CutPlanesPL::CutWithPlanes(myAppendPolyData,aDataSet,GetNbParts(),aDir[1],aBounds,
myPartPosition,myPartCondition,myDisplacement[1]);
- anAppendPolyData->Register(myAppendPolyData);
anAppendPolyData->Delete();
//Calculate values for building of table
vtkMath::Cross(aDir[0],aDir[1],myDirLn);
class vtkAppendPolyData;
-class VISU_CutLinesPL : public VISU_CutPlanesPL{
+class VISU_CutLinesPL : public VISU_CutPlanesPL
+{
protected:
VISU_CutLinesPL();
VISU_CutLinesPL(const VISU_CutLinesPL&);
for (int i = 0, iend = GetNbParts(); i < iend; i++)
if(!aPipeLine->IsPartDefault(i)) SetPartPosition(i, aPipeLine->GetPartPosition(i));
}
- VISU_ScalarMapPL::ShallowCopy(thePipeLine);
+ Superclass::ShallowCopy(thePipeLine);
}
void
VISU_CutPlanesPL
::Init()
{
- VISU_ScalarMapPL::Init();
+ Superclass::Init();
SetNbParts(10);
myBasePlane[0] = YZ;
CutWithPlanes(myAppendPolyData,aDataSet,myNbParts,aDir,aBounds,
myPartPosition,myPartCondition,myDisplacement[0]);
- VISU_ScalarMapPL::Update();
+ Superclass::Update();
}
+//----------------------------------------------------------------------------
+unsigned long int
+VISU_CutPlanesPL
+::GetMemorySize()
+{
+ vtkDataSet* aDataSet = myAppendPolyData->GetOutput();
+ unsigned long int aSize = aDataSet->GetActualMemorySize() * 1024;
+
+ int anEnd = myAppendPolyData->GetNumberOfInputs();
+ for(int anId = 0; anId < anEnd; anId++){
+ aDataSet = myAppendPolyData->GetInput(anId);
+ aSize += aDataSet->GetActualMemorySize() * 1024;
+ }
+
+ aSize += Superclass::GetMemorySize();
+
+ return aSize;
+}
+
+
+//----------------------------------------------------------------------------
void
VISU_CutPlanesPL
::SetPartPosition(int theNum)
aCutPlane->SetCutFunction(aPlane);
aPlane->Delete();
theAppendPolyData->AddInput(aCutPlane->GetOutput());
- aCutPlane->Register(theAppendPolyData);
aCutPlane->Delete();
}
class vtkAppendPolyData;
-class VISU_CutPlanesPL : public VISU_ScalarMapPL{
+class VISU_CutPlanesPL : public VISU_ScalarMapPL
+{
protected:
VISU_CutPlanesPL();
VISU_CutPlanesPL(const VISU_CutPlanesPL&);
void
Update();
+ //! Gets memory size used by the instance (bytes).
+ virtual
+ unsigned long int
+ GetMemorySize();
+
virtual
vtkAppendPolyData*
GetAppendPolyData()
SetContourPrs( aPipeLine->GetIsContourPrs() );
SetNumberOfContours( aPipeLine->GetNumberOfContours() );
}
- VISU_ScalarMapPL::ShallowCopy(thePipeLine);
+ Superclass::ShallowCopy(thePipeLine);
}
VISU_CutPlanesPL::PlaneOrientation
VISU_Plot3DPL::
Init()
{
- VISU_ScalarMapPL::Init();
+ Superclass::Init();
myOrientation = GetOrientation(GetInput2());
SetScaleFactor(GetScaleFactor(GetInput2()));
myWarpScalar->SetNormal(aPlaneNormal);
- VISU_ScalarMapPL::Update();
+ Superclass::Update();
}
+
+//----------------------------------------------------------------------------
+unsigned long int
+VISU_Plot3DPL
+::GetMemorySize()
+{
+ vtkDataSet* aDataSet = myGeometryFilter->GetOutput();
+ unsigned long int aSize = aDataSet->GetActualMemorySize() * 1024;
+
+ aDataSet = myCellDataToPointData->GetInput();
+ aSize += aDataSet->GetActualMemorySize() * 1024;
+
+ aDataSet = myContourFilter->GetInput();
+ aSize += aDataSet->GetActualMemorySize() * 1024;
+
+ aDataSet = myWarpScalar->GetInput();
+ aSize += aDataSet->GetActualMemorySize() * 1024;
+
+ int anEnd = myAppendPolyData->GetNumberOfInputs();
+ for(int anId = 0; anId < anEnd; anId++){
+ aDataSet = myAppendPolyData->GetInput(anId);
+ aSize += aDataSet->GetActualMemorySize() * 1024;
+ }
+
+ aSize += Superclass::GetMemorySize();
+
+ return aSize;
+}
+
+
+//----------------------------------------------------------------------------
void
-VISU_Plot3DPL::
-SetNumberOfContours(int theNumber)
+VISU_Plot3DPL
+::SetNumberOfContours(int theNumber)
{
myContourFilter->SetNumberOfContours(theNumber);
}
VISU_Plot3DPL
::SetMapScale(vtkFloatingPointType theMapScale)
{
- VISU_ScalarMapPL::SetMapScale(theMapScale);
+ Superclass::SetMapScale(theMapScale);
if ( myIsContour ) {
vtkFloatingPointType aRange[2];
class vtkGeometryFilter;
class vtkCellDataToPointData;
-class VISU_Plot3DPL : public VISU_ScalarMapPL{
+class VISU_Plot3DPL : public VISU_ScalarMapPL
+{
protected:
VISU_Plot3DPL();
VISU_Plot3DPL(const VISU_Plot3DPL&);
int
GetNumberOfContours() const;
- void GetBasePlane (vtkFloatingPointType theOrigin[3],
- vtkFloatingPointType theNormal[3],
- bool theCenterOrigine = false ) const;
+ void
+ GetBasePlane (vtkFloatingPointType theOrigin[3],
+ vtkFloatingPointType theNormal[3],
+ bool theCenterOrigine = false ) const;
+
+ void
+ GetMinMaxPosition( vtkFloatingPointType& minPos,
+ vtkFloatingPointType& maxPos ) const;
+
+public:
+ virtual
+ void
+ Init();
- void GetMinMaxPosition( vtkFloatingPointType& minPos,
- vtkFloatingPointType& maxPos ) const;
+ virtual
+ void
+ Update();
-public:
- virtual void Init();
- virtual void Update();
+ //! Gets memory size used by the instance (bytes).
+ virtual
+ unsigned long int
+ GetMemorySize();
static
VISU_CutPlanesPL::PlaneOrientation