34 #include <SALOME_Actor.h>
36 #include <TopoDS_Shape.hxx>
37 #include <vtkSmartPointer.h>
56 class vtkAppendPolyData;
65 void SetShape(
const TopoDS_Shape& theShape,
67 bool theIsVector =
false);
69 void SetDeflection(
double theDeflection);
72 void AddToRender(vtkRenderer* theRenderer);
73 void RemoveFromRender(vtkRenderer* theRenderer);
75 enum EDisplayMode{ eWireframe, eShading, eShadingWithEdges = eShading + 2 };
80 void SetSelected(
bool theIsSelected);
97 virtual void setDisplayMode(
int thenewmode);
102 virtual void Render(vtkRenderer *, vtkMapper *);
107 void ReleaseGraphicsResources(vtkWindow *);
108 const TopoDS_Shape& getTopo();
109 void setInputShape(
const TopoDS_Shape& ashape,
double adef1,
110 int imode,
bool isVector =
false);
118 virtual void highlight(
bool theHighlight);
121 void ShallowCopy(vtkProp *prop);
124 void SetOpacity(
double opa);
128 void SetColor(
double r,
double g,
double b);
129 void GetColor(
double& r,
double& g,
double& b);
131 void SetPointColor(
double r,
double g,
double b);
133 void SetIsolatedEdgeColor(
double r,
double g,
double b);
135 void SetSharedEdgeColor(
double r,
double g,
double b);
137 void SetFreeEdgeColor(
double r,
double g,
double b);
139 void SetEdgesInShadingColor(
double r,
double g,
double b);
141 void SetIsosColor(
double r,
double g,
double b);
143 void SetLabelColor(
double r,
double g,
double b);
147 void SetMaterial(std::vector<vtkProperty*> theProps);
150 virtual bool IsInfinitive();
156 Highlight(
bool theHighlight);
162 PreHighlight(vtkInteractorStyle* theInteractorStyle,
163 SVTK_SelectionEvent* theSelectionEvent,
164 bool theIsHighlight);
169 Highlight(vtkInteractorStyle* theInteractorStyle,
170 SVTK_SelectionEvent* theSelectionEvent,
171 bool theIsHighlight);
176 SetVisibility(
int );
183 SetNbIsos(
const int theNb[2]);
187 GetNbIsos(
int &theNbU,
int &theNbV);
190 void SetIsosWidth(
const int width);
192 int GetIsosWidth()
const;
194 virtual void SetWidth(
const int width);
196 int GetWidth()
const;
201 SetVectorMode(
const bool theMode);
210 SetVerticesMode(
const bool theMode);
219 SetNameMode(
const bool theMode);
227 SetTransform(VTKViewer_Transform* theTransform);
233 void GetMatrix(vtkCamera* theCam, vtkMatrix4x4 *result);
285 virtual void SetMapper(vtkMapper*);
290 double myEdgesInWireframeColor[3];
291 double myEdgesInShadingColor[3];
292 double myIsolatedEdgeColor[3];
293 double mySharedEdgeColor[3];
294 double myOneFaceEdgeColor[3];
GEOM_SmartPtr< GEOM_EdgeSource > PEdgeSource
Definition: GEOM_Actor.h:44
GEOM_SmartPtr< GEOM_WireframeFace > PWFaceSource
Definition: GEOM_Actor.h:47
GEOM_SmartPtr< vtkAppendPolyData > PAppendFilter
Definition: GEOM_Actor.h:56
GEOM_SmartPtr< GEOM_ShadingFace > PSFaceSource
Definition: GEOM_Actor.h:50
GEOM_SmartPtr< GEOM_VertexSource > PVertexSource
Definition: GEOM_Actor.h:41
#define GEOM_OBJECT_EXPORT
Definition: GEOM_OBJECT_defs.hxx:37
This class allows to display an OpenCASCADE CAD model in a VTK viewer.
Definition: GEOM_Actor.h:60
vtkSmartPointer< vtkProperty > myShadingFaceProp
Definition: GEOM_Actor.h:279
PPolyGeomPainterDataMapper myPolyDataMapper
Definition: GEOM_Actor.h:283
PDeviceActor myHighlightActor
Definition: GEOM_Actor.h:273
vtkSmartPointer< vtkProperty > myHighlightProp
Definition: GEOM_Actor.h:277
PVertexSource myStandaloneVertexSource
Definition: GEOM_Actor.h:256
PDeviceActor myShadingFaceActor
Definition: GEOM_Actor.h:270
PEdgeSource myOneFaceEdgeSource
Definition: GEOM_Actor.h:262
virtual bool hasHighlight()
Definition: GEOM_Actor.h:119
bool myVectorMode
Definition: GEOM_Actor.h:248
PDeviceActor mySharedEdgeActor
Definition: GEOM_Actor.h:264
vtkSmartPointer< vtkProperty > myPreHighlightProp
Definition: GEOM_Actor.h:278
PDeviceActor myOneFaceEdgeActor
Definition: GEOM_Actor.h:261
PSFaceSource myShadingFaceSource
Definition: GEOM_Actor.h:271
vtkSmartPointer< vtkProperty > myShadingBackFaceProp
Definition: GEOM_Actor.h:280
EDisplayMode
Definition: GEOM_Actor.h:75
vtkTypeMacro(GEOM_Actor, SALOME_Actor) static GEOM_Actor *New()
bool myVerticesMode
Definition: GEOM_Actor.h:249
double myDeflection
Definition: GEOM_Actor.h:243
bool myNameMode
Definition: GEOM_Actor.h:250
vtkTextActor * myTextActor
Definition: GEOM_Actor.h:275
void operator=(const GEOM_Actor &)
double GetDeflection() const
Definition: GEOM_Actor.h:70
PWFaceSource myWireframeFaceSource
Definition: GEOM_Actor.h:268
GEOM_Actor(const GEOM_Actor &)
PAppendFilter myAppendFilter
Definition: GEOM_Actor.h:282
PDeviceActor myWireframeFaceActor
Definition: GEOM_Actor.h:267
PDeviceActor myStandaloneVertexActor
Definition: GEOM_Actor.h:255
PEdgeSource mySharedEdgeSource
Definition: GEOM_Actor.h:265
PVertexSource myVertexSource
Definition: GEOM_Actor.h:253
PDeviceActor myIsolatedEdgeActor
Definition: GEOM_Actor.h:258
PEdgeSource myIsolatedEdgeSource
Definition: GEOM_Actor.h:259
bool myIsForced
Definition: GEOM_Actor.h:244
bool myIsSelected
Definition: GEOM_Actor.h:247
PDeviceActor myVertexActor
Definition: GEOM_Actor.h:252
bool IsSelected() const
Definition: GEOM_Actor.h:81
TopoDS_Shape myShape
Definition: GEOM_Actor.h:240
bool isOnlyVertex
Definition: GEOM_Actor.h:241
Definition: GEOM_EdgeSource.h:37
Definition: GEOM_ShadingFace.h:27
Definition: GEOM_VertexSource.h:37
Definition: GEOM_WireframeFace.h:37