+// Copyright (C) 2007-2014 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, 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
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+
#ifndef VTKVIEWER_RENDERWINDOWINTERACTOR_H
#define VTKVIEWER_RENDERWINDOWINTERACTOR_H
#include "VTKViewer.h"
#include "VTKViewer_Actor.h"
-#include <qtimer.h>
-#include <qobject.h>
+#include <QObject>
+
+class QTimer;
+class QMouseEvent;
+class QKeyEvent;
+class QContextMenuEvent;
// Open CASCADE Includes
#include <TColStd_MapOfInteger.hxx>
/** @name Selection Management */
//@{
bool highlightCell(const TColStd_IndexedMapOfInteger& MapIndex,
- VTKViewer_Actor* theMapActor,
- bool hilight,
- bool update = true );
+ VTKViewer_Actor* theMapActor,
+ bool hilight,
+ bool update = true );
bool highlightEdge(const TColStd_IndexedMapOfInteger& MapIndex,
- VTKViewer_Actor* theMapActor,
- bool hilight,
- bool update = true );
+ VTKViewer_Actor* theMapActor,
+ bool hilight,
+ bool update = true );
bool highlightPoint(const TColStd_IndexedMapOfInteger& MapIndex,
- VTKViewer_Actor* theMapActor,
- bool hilight,
- bool update = true );
+ VTKViewer_Actor* theMapActor,
+ bool hilight,
+ bool update = true );
void unHighlightSubSelection();
bool unHighlightAll();
//void SetSelectionMode(Selection_Mode mode);
void SetSelectionProp(const double& theRed = 1, const double& theGreen = 1,
- const double& theBlue = 0, const int& theWidth = 5);
+ const double& theBlue = 0, const int& theWidth = 5);
void SetSelectionTolerance(const double& theTolNodes = 0.025, const double& theTolCell = 0.001);
//@}
//@{
void ChangeRepresentationToWireframe();
void ChangeRepresentationToSurface();
+ void ChangeRepresentationToSurfaceWithEdges();
//@}
/** @name Change to wireframe or surface a list of vtkactor*/
//@{
void ChangeRepresentationToWireframe(vtkActorCollection* ListofActors);
void ChangeRepresentationToSurface(vtkActorCollection* ListofActors);
+ void ChangeRepresentationToSurfaceWithEdges(vtkActorCollection* ListofActors);
//@}
/** @name Erase Display functions*/
void setViewWindow( VTKViewer_ViewWindow* theViewWnd );
void setCellData(const int& theIndex,
- VTKViewer_Actor* theMapActor,
- VTKViewer_Actor* theActor) {}
+ VTKViewer_Actor* theMapActor,
+ VTKViewer_Actor* theActor) {}
void setEdgeData(const int& theCellIndex,
- VTKViewer_Actor* theMapActor,
- const int& theEdgeIndex,
- VTKViewer_Actor* theActor ) {} //NB
+ VTKViewer_Actor* theMapActor,
+ const int& theEdgeIndex,
+ VTKViewer_Actor* theActor ) {} //NB
void setPointData(const int& theIndex,
- VTKViewer_Actor* theMapActor,
- VTKViewer_Actor* theActor) {}
+ VTKViewer_Actor* theMapActor,
+ VTKViewer_Actor* theActor) {}
typedef void (*TUpdateActor)(const TColStd_IndexedMapOfInteger& theMapIndex,
- VTKViewer_Actor* theMapActor,
- VTKViewer_Actor* theActor);
+ VTKViewer_Actor* theMapActor,
+ VTKViewer_Actor* theActor);
protected:
VTKViewer_RenderWindowInteractor();
VTKViewer_InteractorStyle* myInteractorStyle;
bool highlight(const TColStd_IndexedMapOfInteger& theMapIndex,
- VTKViewer_Actor* theMapActor, VTKViewer_Actor* theActor,
- TUpdateActor theFun, bool hilight, bool update);
+ VTKViewer_Actor* theMapActor, VTKViewer_Actor* theActor,
+ TUpdateActor theFun, bool hilight, bool update);
void setActorData(const TColStd_IndexedMapOfInteger& theMapIndex,
- VTKViewer_Actor* theMapActor,
- VTKViewer_Actor *theActor,
- TUpdateActor theFun);
+ VTKViewer_Actor* theMapActor,
+ VTKViewer_Actor *theActor,
+ TUpdateActor theFun);
/*! Timer used during various mouse events to figure
* out mouse movements.