Fix problems with the OpenGL clipping planes.

This commit is contained in:
rnv 2014-02-19 16:43:32 +04:00
parent fad37730ee
commit 6e68fcd497
3 changed files with 7 additions and 4 deletions

View File

@ -1313,7 +1313,7 @@ void SMESH_ActorDef::SetShrinkFactor(double theValue){
Modified();
}
void SMESH_ActorDef::SetShrink(){
void SMESH_ActorDef::SetShrink() {
if(!myIsShrinkable) return;
myBaseActor->SetShrink();
@ -2207,7 +2207,10 @@ SMESH_ActorDef::SetOpenGLClippingPlane()
my3DExtActor->SetPlaneCollection( myPlaneCollection );
my3DExtActor->SetUnstructuredGrid(myVisualObj->GetUnstructuredGrid());
Modified();
if(IsShrunk())
SetShrink();
else
Modified();
}
void

View File

@ -142,7 +142,6 @@ SMESH_DeviceActor
if(MYDEBUG) MESSAGE("~SMESH_DeviceActor - "<<this);
myMapper->Delete();
myPlaneCollection->Delete();
myProperty->Delete();

View File

@ -161,7 +161,8 @@ class SMESHOBJECT_EXPORT SMESH_DeviceActor: public vtkLODActor{
VTKViewer_PolyDataMapper *myMapper;
TVisualObjPtr myVisualObj;
vtkPlaneCollection* myPlaneCollection;
vtkSmartPointer<vtkPlaneCollection> myPlaneCollection;
vtkProperty *myProperty;
EReperesent myRepresentation;