27 #ifndef __TY_MODELER_FRAME__
28 #define __TY_MODELER_FRAME__
32 #include <QCloseEvent>
35 #include <QWheelEvent>
36 #include <QResizeEvent>
37 #include <QGridLayout>
38 #include <QFocusEvent>
39 #include <QMouseEvent>
109 TYModelerFrame(QWidget* parent = 0,
const char*
name = 0, Qt::WindowFlags f = Qt::SubWindow);
370 virtual void updateView(
bool clipping =
true,
bool axesAndGrid =
true);
432 virtual bool close();
470 static double getDouble(
const QString& title,
const QString& txt,
double min,
double max,
double val,
471 bool& ok,
int dec = 2);
517 virtual void showEvent(QShowEvent* pEvent);
Gere les undos (fichier header)
Realise le rendu VTK et le rendu OpenGL (fichier header)
Le role de cette classe est limite a emettre des signaux pouvant etre utilise pour interagir sur le r...
Classe abstraite pour la gestion de l'interaction entre la vue graphique (2D ou 3D) et le clavier et ...
Gestion de l'edition en mode camera.
gestion de zoom par zone selectionnee (obsolete)
outil de mesure des distances
gestion des elements selectionnes par picking
Generic class for a modeler window.
virtual void wheelEvent(QWheelEvent *pEvent)
QToolButton * _pSnapGridBtn
Button to activate the magnetic grid.
void setSnapGridActive(bool state)
virtual void closeEvent(QCloseEvent *pEvent)
void updateElementGraphic(bool force=false)
virtual void leaveEvent(QEvent *pEvent)
int _curViewType
The type of the current view.
QStatusBar * _pStatusBar
Status bar.
virtual bool computeCurPos(int x, int y, float *pos)
bool getWireframeOnMovingCamera()
TYCameraEditor * _pCameraEditor
Manages the camera.
void showScale(bool show)
bool _editorModeAccepted
Indicates if the editing mode has been processed.
OGLScalarBarElement * _pOGLScalarBarElement
Graphic object for representing the scale.
QToolButton * _pShowRaysBtn
Button for displaying rays calculated by ray tracing.
virtual void setRenderModeSlot(int mode)
LPTYElement _pElement
A pointer to the element to edit.
void showPlafond(bool show)
TYRenderWindowInteractor * getView()
QToolButton * _pShowScale
Button for displaying the scale.
virtual void enterEvent(QEvent *pEvent)
TYPositionEditor * _pPositionEditor
Editor for moving elements.
void setEditorModeToCamera()
TYCameraZoneEditor * _pCameraZoneEditor
Editor to define a zoom area for the camera.
OGLTextElement * _pOGLTextElement
2D label to display the type of view.
virtual void resizeEvent(QResizeEvent *pEvent)
TYAbstractSceneEditor * _pCurrentEditor
The current editor.
void setKeepRays(bool keepRays)
virtual ~TYModelerFrame()
void editorModeChanged(int mode)
OGLLineElement * _pOGLLineElementAxeX
Geometry of the Axes.
void setGridLinesActorsVisibility(bool showGridXY, bool showGridXZ, bool showGridZY)
QToolButton * _pShowPlafondBtn
Button for displaying the ceiling of buildings.
void viewTypeChanged(int)
bool _wireframeOnMovingCamera
Indicates whether to switch to wireframe rendering during camera movement.
QToolButton * _pShowNormalsBtn
Button for displaying normals.
TYElementPicker * getElementPicker()
virtual void focusInEvent(QFocusEvent *pEvent)
bool _snapGridActive
Indicates whether or not to activate the magnetic grid.
void setWireframeOnMovingCamera(bool state)
TYActionManager _actionManager
For managing the history.
OGLLightElement * _pLightElement
The default light.
QBoxLayout * _pCtrlLayout
The layout where buttons, etc., are located.
virtual void mouseMoveEvent(QMouseEvent *pEvent)
QGridLayout * _pLayout
The layout of this frame.
void setElement(LPTYElement pElement)
QToolButton * _pShowSourcesBtn
Button for displaying point sources.
OGLTextElement * _pOGLTextElementLabelY
virtual void setViewType(int view)
TYActionManager * getActionManager()
OGLLineElement * _pOGLLineElementX
X and Y axes of the grid.
QToolButton * _pGridBtn
Button to activate the grid.
bool isElementInCurrentProjet()
void setDefaultZCoord(float fDefaultZCoord)
sets default Z coordinate for editors
OGLGridElement * _pOGLGridElement
TYRenderWindowInteractor * _pView
The graphics window.
QToolButton * _pCopyBtn
Button for taking a screenshot.
virtual float getDefaultZCoord()
Returns default Z coordinate for editors This value will depend on the type of modeler and of the fix...
OBox getGlobalBoundingBox()
bool _showPlafond
Indicates whether or not to display or hide the ceiling of buildings.
void stopMovingRenderMode()
void showNormals(bool show)
OGLLineElement * _pOGLLineElementAxeZ
QComboBox * _pRenderModeBox
Combo box for rendering mode.
OGLTextElement * _pOGLTextElementLabelX
TYOpenGLRenderer::RenderMode getRenderMode()
bool _showGrid
Indicates whether to display the grid or not.
TYModelerFrame(QWidget *parent=0, const char *name=0, Qt::WindowFlags f=Qt::SubWindow)
bool _showNormals
Indicates whether or not to display or hide normals.
void setCameraCoordinates()
OGLTextElement * _pOGLTextElementLabelZ
bool isElementInCurrentCalcul()
bool askForResetResultat()
bool _showScale
Indicates whether to display the scale or not.
void eltModified(LPTYElement pElt)
int _lastEditorMode
To keep track of the last editing mode.
TYCameraEditor * getCameraEditor()
QToolButton * _pSetCameraCoordinatesBtn
Button to specify camera coordinates.
TYOpenGLRenderer::RenderMode _lastRenderMode
The last current rendering mode.
OGLLineElement * _pOGLLineElementAxeY
void updateCurPosInfo(int x, int y)
float _gridDimX
Grid dimension in X.
float _gridDimY
Grid dimension in Y.
void startMovingRenderMode()
TYElementPicker * _pPicker
For picking.
virtual void setRenderMode(TYOpenGLRenderer::RenderMode mode, bool bUpdateGL)
OGLCamera * _pOGLCameras[NbOfViews]
Cameras for each type of view.
float _gridStep
Grid step.
virtual void updatePreferences()
bool _showRays
Indicates whether or not to display rays.
TYPickEditor * _pPickEditor
Manages the context menu.
OGLLineElement * _pOGLLineElementY
float _gridMagnStep
Magnetic grid step.
QToolButton * _pScreenShotBtn
Button for saving a screenshot.
TYPickEditor * getPickEditor()
virtual void keyPressEvent(QKeyEvent *pEvent)
TYAbstractSceneEditor * getCurrentEditor()
TYDistanceEditor * _pDistanceEditor
Tools for measuring.
virtual void setEditorMode(int mode)
virtual void updateView(bool clipping=true, bool axesAndGrid=true)
virtual void showEvent(QShowEvent *pEvent)
virtual void keyReleaseEvent(QKeyEvent *pEvent)
static double getDouble(const QString &title, const QString &txt, double min, double max, double val, bool &ok, int dec=2)
float _defaultZCoord
Default Z coordinate for editors.
TYOpenGLRenderer * getRenderer()
bool _showSources
Indicates whether or not to display point sources.
QComboBox * _pViewTypeBox
Combo box for selecting the current camera.
Realise le rendu VTK et le rendu OpenGL.
RenderMode getRenderMode()
gestion de l'element actionne par picking
gestion de la position selon les modes 'moving', 'rotation', 'edition'
Le role de cette classe est limite a emettre des signaux pouvant etre utilise pour interagir sur le r...
TYOpenGLRenderer * getRenderer()