-// Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2020 CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
class vtkPlane;
class vtkImplicitBoolean;
class vtkTimeStamp;
+class vtkPlaneCollection;
class SMESH_DeviceActor;
class SMESH_NodeLabelActor;
friend class SMESH_Actor;
public:
- vtkTypeMacro(SMESH_ActorDef,SMESH_Actor);
+ vtkTypeMacro(SMESH_ActorDef,SMESH_Actor)
virtual void Delete();
virtual void AddToRender(vtkRenderer* theRenderer);
virtual void RemoveFromRender(vtkRenderer* theRenderer);
+ virtual void EnableSelection( bool enable );
virtual bool hasHighlight() { return true; }
virtual void highlight(bool theHighlight);
virtual void SetPreSelected(bool thePreselect = false);
virtual bool IsInfinitive();
- virtual void SetOpacity(vtkFloatingPointType theValue);
- virtual vtkFloatingPointType GetOpacity();
+ virtual void SetOpacity(double theValue);
+ virtual double GetOpacity();
- virtual void SetSufaceColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b, int delta );
- virtual void GetSufaceColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b, int& delta);
+ virtual void SetSufaceColor(double r,double g,double b, int delta );
+ virtual void GetSufaceColor(double& r,double& g,double& b, int& delta);
- virtual void SetEdgeColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetEdgeColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void SetVolumeColor(double r,double g,double b, int delta );
+ virtual void GetVolumeColor(double& r,double& g,double& b, int& delta);
- virtual void SetOutlineColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetOutlineColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void SetEdgeColor(double r,double g,double b);
+ virtual void GetEdgeColor(double& r,double& g,double& b);
+ virtual void SetOutlineColor(double r,double g,double b);
+ virtual void GetOutlineColor(double& r,double& g,double& b);
- virtual void SetNodeColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetNodeColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
- virtual void Set0DColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void Get0DColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void SetNodeColor(double r,double g,double b);
+ virtual void GetNodeColor(double& r,double& g,double& b);
- virtual void SetBallColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetBallColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void Set0DColor(double r,double g,double b);
+ virtual void Get0DColor(double& r,double& g,double& b);
- virtual void SetHighlightColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetHighlightColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void SetBallColor(double r,double g,double b);
+ virtual void GetBallColor(double& r,double& g,double& b);
- virtual void SetPreHighlightColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloatingPointType b);
- virtual void GetPreHighlightColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b);
+ virtual void UpdateSelectionProps();
- virtual vtkFloatingPointType GetLineWidth();
- virtual void SetLineWidth(vtkFloatingPointType theVal);
+ virtual double GetLineWidth();
+ virtual void SetLineWidth(double theVal);
- virtual void Set0DSize(vtkFloatingPointType size);
- virtual vtkFloatingPointType Get0DSize();
+ virtual double GetOutlineWidth();
+ virtual void SetOutlineWidth(double theVal);
- virtual void SetBallSize(vtkFloatingPointType size);
- virtual vtkFloatingPointType GetBallSize();
+ virtual void Set0DSize(double size);
+ virtual double Get0DSize();
+
+ virtual void SetBallSize(double size);
+ virtual double GetBallSize();
+
+ virtual void SetBallScale(double size);
+ virtual double GetBallScale();
virtual int GetNodeObjId(int theVtkID);
- virtual vtkFloatingPointType* GetNodeCoord(int theObjID);
+ virtual double* GetNodeCoord(int theObjID);
+ virtual int GetNodeVtkId(int theObjID);
virtual int GetElemObjId(int theVtkID);
virtual vtkCell* GetElemCell(int theObjID);
virtual void SetPointRepresentation(bool theIsPointsVisible);
virtual bool GetPointRepresentation();
- virtual vtkFloatingPointType* GetBounds();
+ virtual double* GetBounds();
virtual void SetTransform(VTKViewer_Transform* theTransform);
virtual vtkUnstructuredGrid* GetUnstructuredGrid();
virtual vtkDataSet* GetInput();
virtual vtkMapper* GetMapper();
- virtual vtkFloatingPointType GetShrinkFactor();
- virtual void SetShrinkFactor(vtkFloatingPointType theValue);
+ virtual double GetShrinkFactor();
+ virtual void SetShrinkFactor(double theValue);
virtual bool IsShrunkable() { return myIsShrinkable;}
virtual bool IsShrunk() { return myIsShrunk;}
virtual void SetPointsLabeled(bool theIsPointsLabeled);
virtual bool GetPointsLabeled();
+ virtual void SetPointsFontProperties( SMESH::LabelFont family, int size,
+ bool bold, bool italic, bool shadow,
+ double r, double g, double b );
+ virtual void SetCellsFontProperties( SMESH::LabelFont family, int size,
+ bool bold, bool italic, bool shadow,
+ double r, double g, double b );
+
virtual void SetCellsLabeled(bool theIsCellsLabeled);
virtual bool GetCellsLabeled();
virtual void SetFacesOriented(bool theIsFacesOriented);
virtual bool GetFacesOriented();
- virtual void SetFacesOrientationColor(vtkFloatingPointType theColor[3]);
- virtual void GetFacesOrientationColor(vtkFloatingPointType theColor[3]);
+ virtual void SetFacesOrientationColor(double r,double g,double b);
+ virtual void GetFacesOrientationColor(double& r,double& g,double& b);
- virtual void SetFacesOrientationScale(vtkFloatingPointType theScale);
- virtual vtkFloatingPointType GetFacesOrientationScale();
+ virtual void SetFacesOrientationScale(double theScale);
+ virtual double GetFacesOrientationScale();
virtual void SetFacesOrientation3DVectors(bool theState);
virtual bool GetFacesOrientation3DVectors();
virtual void SetControlMode(eControl theMode);
+ virtual void SetControl(SMESH::Controls::FunctorPtr theFunctor);
+ virtual int GetNumberControlEntities();
virtual eControl GetControlMode(){ return myControlMode;}
virtual SMESH::Controls::FunctorPtr GetFunctor() { return myFunctor; }
virtual vtkIdType GetNumberOfClippingPlanes();
virtual vtkPlane* GetClippingPlane(vtkIdType theID);
virtual vtkIdType AddClippingPlane(vtkPlane* thePlane);
+ virtual void AddOpenGLClippingPlane(vtkPlane* thePlane);
+ virtual void SetOpenGLClippingPlane();
virtual TVisualObjPtr GetObject() { return myVisualObj;}
virtual void SetMarkerStd( VTK::MarkerType, VTK::MarkerScale );
virtual void SetMarkerTexture( int, VTK::MarkerTexture );
+ virtual void UpdateFilter();
+
protected:
void SetControlMode(eControl theMode, bool theCheckEntityMode);
void SetImplicitFunctionUsed(bool theIsImplicitFunctionUsed);
vtkProperty* mySurfaceProp;
vtkProperty* myBackSurfaceProp;
+ vtkProperty* myNormalVProp;
+ vtkProperty* myReversedVProp;
vtkProperty* myEdgeProp;
vtkProperty* myNodeProp;
vtkProperty* myHighlightProp;
vtkProperty* myOutLineProp;
vtkProperty* myPreselectProp;
-
+
SMESH_DeviceActor* myHighlitableActor;
eControl myControlMode;
SMESH::Controls::FunctorPtr myFunctor;
vtkProperty* my2DExtProp;
+ vtkProperty* my3DExtProp;
SMESH_CellLabelActor* my2DActor;
SMESH_DeviceActor* my2DExtActor;
SMESH_CellLabelActor* my3DActor;
SMESH_DeviceActor* my0DExtActor;
unsigned int myEntityMode;
- unsigned int myEntityState;
unsigned int myEntityModeCache;
+ int myRepresentationCache;
bool myIsEntityModeCache;
bool myIsPointsVisible;
bool myIsShrunk;
vtkImplicitBoolean* myImplicitBoolean;
+ vtkPlaneCollection* myPlaneCollection;
typedef TVTKSmartPtr<vtkPlane> TPlanePtr;
typedef std::vector<TPlanePtr> TCippingPlaneCont;
TCippingPlaneCont myCippingPlaneCont;
bool myIsFacesOriented;
int myDeltaBrightness;
+ int myDeltaVBrightness;
VTK::MarkerTexture myMarkerTexture;