From: mkr Date: Thu, 12 Jan 2012 16:38:26 +0000 (+0000) Subject: Fix for PAL21179: X-Git-Tag: V6_main_20120117 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=16df95fd0793f9871f898a73dc8b750c42992a41;p=modules%2Fvisu.git Fix for PAL21179: 1) draw outlines (borders) of the shapes, 2) material properties. --- diff --git a/src/OBJECT/VISU_Actor.cxx b/src/OBJECT/VISU_Actor.cxx index dc25a52b..9e48b360 100644 --- a/src/OBJECT/VISU_Actor.cxx +++ b/src/OBJECT/VISU_Actor.cxx @@ -340,7 +340,7 @@ VISU_Actor { UnShrink(); } - SetFeatureEdgesEnabled( theMode == SVTK::Representation::FeatureEdges ); + SetFeatureEdgesEnabled( theMode == VTKViewer::Representation::FeatureEdges ); } diff --git a/src/OBJECT/VISU_Actor.h b/src/OBJECT/VISU_Actor.h index 4ea21ad6..7f4b3434 100644 --- a/src/OBJECT/VISU_Actor.h +++ b/src/OBJECT/VISU_Actor.h @@ -33,7 +33,7 @@ #include "SALOME_Actor.h" #include "VISU_ActorBase.h" #include "VISU_BoostSignals.h" -#include "SVTK_DeviceActor.h" +#include "VTKViewer_Actor.h" #include #include @@ -65,7 +65,7 @@ class VISU_UsedPointsFilter; #define VTK_XVERSION (VTK_MAJOR_VERSION<<16)+(VTK_MINOR_VERSION<<8)+(VTK_BUILD_VERSION) #endif -namespace SVTK +namespace VTKViewer { namespace Representation { diff --git a/src/OBJECT/VISU_MeshAct.cxx b/src/OBJECT/VISU_MeshAct.cxx index 9c2c5040..2e26fcaf 100644 --- a/src/OBJECT/VISU_MeshAct.cxx +++ b/src/OBJECT/VISU_MeshAct.cxx @@ -54,19 +54,19 @@ VISU_MeshAct m = vtkMatrix4x4::New(); mySurfaceActor = SVTK_DeviceActor::New(); - mySurfaceActor->SetRepresentation(SVTK::Representation::Surface); + mySurfaceActor->SetRepresentation(VTKViewer::Representation::Surface); mySurfaceActor->SetUserMatrix(m); myEdgeActor = SVTK_DeviceActor::New(); - myEdgeActor->SetRepresentation(SVTK::Representation::Wireframe); + myEdgeActor->SetRepresentation(VTKViewer::Representation::Wireframe); myEdgeActor->SetUserMatrix(m); myNodeActor = SVTK_DeviceActor::New(); - myNodeActor->SetRepresentation(SVTK::Representation::Points); + myNodeActor->SetRepresentation(VTKViewer::Representation::Points); myNodeActor->SetUserMatrix(m); m->Delete(); - SetRepresentation(SVTK::Representation::Surface); + SetRepresentation(VTKViewer::Representation::Surface); SUIT_ResourceMgr* aResourceMgr = SUIT_Session::session()->resourceMgr(); //Quadratic 2D elements representation @@ -293,10 +293,10 @@ VISU_MeshAct { Superclass::SetRepresentation(theMode); - if(theMode == SVTK::Representation::Insideframe) - myEdgeActor->SetRepresentation(SVTK::Representation::Insideframe); + if(theMode == VTKViewer::Representation::Insideframe) + myEdgeActor->SetRepresentation(VTKViewer::Representation::Insideframe); else - myEdgeActor->SetRepresentation(SVTK::Representation::Wireframe); + myEdgeActor->SetRepresentation(VTKViewer::Representation::Wireframe); } //---------------------------------------------------------------------------- @@ -339,7 +339,7 @@ VISU_MeshAct GetMatrix(myEdgeActor->GetUserMatrix()); GetMatrix(mySurfaceActor->GetUserMatrix()); - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch(GetRepresentation()){ case Points : myNodeActor->SetAllocatedRenderTime(this->AllocatedRenderTime,ren); @@ -378,7 +378,7 @@ VISU_MeshAct GetMatrix(myEdgeActor->GetUserMatrix()); GetMatrix(mySurfaceActor->GetUserMatrix()); - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch(GetRepresentation()){ case Points : myNodeActor->SetAllocatedRenderTime(this->AllocatedRenderTime,ren); @@ -432,7 +432,7 @@ VISU_MeshAct { int result = 0; - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch ( GetRepresentation() ) { case Points: result |= myNodeActor->HasTranslucentPolygonalGeometry(); diff --git a/src/OBJECT/VISU_ScalarMapAct.cxx b/src/OBJECT/VISU_ScalarMapAct.cxx index ac4e542b..c5334947 100644 --- a/src/OBJECT/VISU_ScalarMapAct.cxx +++ b/src/OBJECT/VISU_ScalarMapAct.cxx @@ -233,17 +233,17 @@ VISU_ScalarMapAct vtkMatrix4x4 *aMatrix = vtkMatrix4x4::New(); mySurfaceActor= SVTK_DeviceActor::New(); - mySurfaceActor->SetRepresentation(SVTK::Representation::Surface); + mySurfaceActor->SetRepresentation(VTKViewer::Representation::Surface); mySurfaceActor->SetProperty(aProperty); mySurfaceActor->SetUserMatrix(aMatrix); myEdgeActor = SVTK_DeviceActor::New(); - myEdgeActor->SetRepresentation(SVTK::Representation::Wireframe); + myEdgeActor->SetRepresentation(VTKViewer::Representation::Wireframe); myEdgeActor->SetUserMatrix(aMatrix); myEdgeActor->GetProperty()->SetColor(255.,255.,255.); myPointsActor = SVTK_DeviceActor::New(); - myPointsActor->SetRepresentation(SVTK::Representation::Points); + myPointsActor->SetRepresentation(VTKViewer::Representation::Points); myPointsActor->SetProperty(aProperty); myPointsActor->SetUserMatrix(aMatrix); @@ -572,8 +572,8 @@ VISU_ScalarMapAct Superclass::SetRepresentation(theMode); - if(theMode == SVTK::Representation::Surfaceframe) - mySurfaceActor->SetRepresentation(SVTK::Representation::Surface); + if(theMode == VTKViewer::Representation::Surfaceframe) + mySurfaceActor->SetRepresentation(VTKViewer::Representation::Surface); else mySurfaceActor->SetRepresentation(theMode); @@ -619,7 +619,7 @@ VISU_ScalarMapAct GetMatrix(myPointsActor->GetUserMatrix()); GetMatrix(myPointSpriteActor->GetUserMatrix()); - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch ( GetRepresentation() ) { case Surfaceframe: @@ -659,7 +659,7 @@ VISU_ScalarMapAct GetMatrix(myEdgeActor->GetUserMatrix()); GetMatrix(mySurfaceActor->GetUserMatrix()); - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch ( GetRepresentation() ) { case Surfaceframe: @@ -716,7 +716,7 @@ VISU_ScalarMapAct { int result = 0; - using namespace SVTK::Representation; + using namespace VTKViewer::Representation; switch ( GetRepresentation() ) { case Surfaceframe: result |= mySurfaceActor->HasTranslucentPolygonalGeometry(); diff --git a/src/OBJECT/VISU_ScalarMapAct.h b/src/OBJECT/VISU_ScalarMapAct.h index c6925b4e..f7ecaeaf 100644 --- a/src/OBJECT/VISU_ScalarMapAct.h +++ b/src/OBJECT/VISU_ScalarMapAct.h @@ -31,6 +31,7 @@ #include "VISU_OBJECT.h" #include "VISU_DataSetActor.h" +#include "SVTK_DeviceActor.h" namespace VTK {