X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROGUI%2FHYDROGUI_Actor.cxx;h=d42756802b60ea25aceb4490b2b8a7c53f8f6ae7;hb=81c9f5cdf82909d0aebd2c491c50fa7516cc80b7;hp=4848a0b11435e5d1360004e84f942f5f5416f8c0;hpb=94e41385896064b100d11c5d86109f038fa08fc0;p=modules%2Fhydro.git diff --git a/src/HYDROGUI/HYDROGUI_Actor.cxx b/src/HYDROGUI/HYDROGUI_Actor.cxx index 4848a0b1..d4275680 100644 --- a/src/HYDROGUI/HYDROGUI_Actor.cxx +++ b/src/HYDROGUI/HYDROGUI_Actor.cxx @@ -6,6 +6,26 @@ #include #include #include +#include +#include +#include + +HYDROGUI_Actor::HYDROGUI_Actor() +{ + myVertexActor->GetDeviceActor()->SetMapper( myVertexActor->GetDeviceActor()->GetMapper() ); + myIsolatedEdgeActor->GetDeviceActor()->SetMapper( myIsolatedEdgeActor->GetDeviceActor()->GetMapper() ); + myOneFaceEdgeActor->GetDeviceActor()->SetMapper( myOneFaceEdgeActor->GetDeviceActor()->GetMapper() ); + mySharedEdgeActor->GetDeviceActor()->SetMapper( mySharedEdgeActor->GetDeviceActor()->GetMapper() ); + myWireframeFaceActor->GetDeviceActor()->SetMapper( myWireframeFaceActor->GetDeviceActor()->GetMapper() ); + myShadingFaceActor->SetInput(myShadingFaceSource->GetOutputPort(),false); + myShadingFaceActor->GetDeviceActor()->SetMapper( myShadingFaceActor->GetDeviceActor()->GetMapper() ); + GEOM_Actor::myHighlightActor->GetDeviceActor()->SetMapper( GEOM_Actor::myHighlightActor->GetDeviceActor()->GetMapper() ); +} + + +HYDROGUI_Actor::~HYDROGUI_Actor() +{ +} HYDROGUI_Actor* HYDROGUI_Actor::New() { @@ -15,26 +35,20 @@ HYDROGUI_Actor* HYDROGUI_Actor::New() } void HYDROGUI_Actor::SetMapper( vtkMapper* theMapper ) -{ - SALOME_Actor::SetMapper(theMapper); -} - -/*double* HYDROGUI_Actor::GetBounds() { - double* aBounds = GEOM_Actor::GetBounds(); - return aBounds; -}*/ + SALOME_Actor::SetMapper( theMapper ); +} void HYDROGUI_Actor::SetTransform( VTKViewer_Transform* theTransform ) { - SALOME_Actor::SetTransform( theTransform ); + Superclass::SetTransform(theTransform); myVertexActor ->GetDeviceActor()->SetTransform( theTransform ); myIsolatedEdgeActor ->GetDeviceActor()->SetTransform( theTransform ); myOneFaceEdgeActor ->GetDeviceActor()->SetTransform( theTransform ); mySharedEdgeActor ->GetDeviceActor()->SetTransform( theTransform ); myWireframeFaceActor->GetDeviceActor()->SetTransform( theTransform ); myShadingFaceActor ->GetDeviceActor()->SetTransform( theTransform ); - myHighlightActor ->GetDeviceActor()->SetTransform( theTransform ); + GEOM_Actor::myHighlightActor->GetDeviceActor()->SetTransform( theTransform ); } void HYDROGUI_Actor::SetShape( const TopoDS_Shape& theShape, @@ -56,5 +70,11 @@ void HYDROGUI_Actor::SetShape( const TopoDS_Shape& theShape, myWireframeFaceActor->GetDeviceActor()->SetInfinitive( true ); if( myShadingFaceSource->IsEmpty() ) + { myShadingFaceActor->GetDeviceActor()->SetInfinitive( true ); + } + else + { + myShadingFaceSource->Update(); + } }