Simple 3D viewer. More...
#include "Viewer.h"
Public Member Functions | |
Viewer ()=delete | |
Viewer (ot::UID modelID, ot::UID viewerID, double scaleWidth, double scaleHeight, int backgroundR, int backgroundG, int backgroundB, int overlayTextR, int overlayTextG, int overlayTextB) | |
virtual | ~Viewer () |
void | reset () |
void | refresh (bool _ignoreUpdateSettingsRequest=true) |
void | setClearColorAutomatic (int backgroundR, int backgroundG, int backgroundB, int foregroundR, int foregroundG, int foregroundB) |
void | removeOverlay (void) |
void | setOverlayText (const std::string &text) |
ot::UID | getViewerID (void) |
void | detachFromModel (void) |
ot::PlotManagerView * | get1DPlot (void) const |
void | setTabNames (const std::string &_osgViewTabName, const std::string &_plotTabName, const std::string &_versionGraphTabName) |
void | set1DPlotItemSelected (unsigned long long treeItemID, bool controlPressed) |
void | reset1DPlotItemSelection (void) |
Rubberband * | getRubberband (void) |
void | createRubberband (ot::serviceID_t _senderId, std::string &_note, const std::string &_configurationJson) |
void | finishRubberbandExecution (void) |
void | cancelRubberband (void) |
void | settingsItemChanged (const ot::Property *_property) |
bool | workingPlaneSettingsItemChanged (const std::string &_logicalName, const ot::Property *_item, bool &_settingsUpdateRequired) |
bool | axisCrossSettingsItemChanged (const std::string &_logicalName, const ot::Property *_item, bool &_settingsUpdateRequired) |
bool | geometrySettingsItemChanged (const std::string &_logicalName, const ot::Property *_item, bool &_settingsUpdateRequired) |
bool | displaySettingsItemChanged (const std::string &_logicalName, const ot::Property *_item, bool &_settingsUpdateRequired) |
void | toggleWorkingPlane (void) |
void | setWorkingPlaneTransform (osg::Matrix matrix) |
osg::Matrix | getWorkingPlaneTransform (void) |
void | toggleAxisCross (void) |
void | toggleCenterAxisCross (void) |
void | toggleCutplane (void) |
void | setLightSourceDistance (const std::string &value) |
void | freeze3DView (bool flag) |
void | addHandler (HandlerBase *handler) |
void | removeHandler (HandlerBase *handler) |
bool | hasHandlers (void) |
void | processHoverViewHandlers (osgUtil::LineSegmentIntersector *intersector) |
HandlerBase * | getCurrentHandler (void) |
Model * | getModel (void) |
bool | propertyGridValueChanged (const ot::Property *_property) |
void | enableClipPlane (osg::Vec3d normal, osg::Vec3d point) |
void | updateClipPlane (osg::Vec3d normal, osg::Vec3d point) |
void | disableClipPlane (void) |
void | showClipPlaneHandles (void) |
void | hideClipPlaneHandles (void) |
void | setCursorText (const std::string &text) |
void | setFreezeWorkingPlane (bool flag) |
bool | getFreezeWorkingPlane () |
Viewer (const int left, const int top, const int width, const int height) | |
Viewer & | operator<< (const TopoDS_Shape &shape) |
void | AddShape (const TopoDS_Shape &shape) |
void | StartMessageLoop () |
Starts message loop. | |
Protected Member Functions | |
virtual void | paintGL () override |
virtual void | resizeGL (int width, int height) override |
virtual void | initializeGL () override |
virtual void | mouseDoubleClickEvent (QMouseEvent *event) override |
virtual void | mouseMoveEvent (QMouseEvent *event) override |
virtual void | mousePressEvent (QMouseEvent *event) override |
virtual void | mouseReleaseEvent (QMouseEvent *event) override |
virtual void | leaveEvent (QEvent *event) override |
virtual void | enterEvent (QEnterEvent *event) override |
virtual void | wheelEvent (QWheelEvent *event) override |
virtual bool | event (QEvent *evnt) override |
virtual void | keyPressEvent (QKeyEvent *event) override |
virtual void | keyReleaseEvent (QKeyEvent *event) override |
Simple 3D viewer.
|
delete |
Viewer::Viewer | ( | ot::UID | modelID, |
ot::UID | viewerID, | ||
double | scaleWidth, | ||
double | scaleHeight, | ||
int | backgroundR, | ||
int | backgroundG, | ||
int | backgroundB, | ||
int | overlayTextR, | ||
int | overlayTextG, | ||
int | overlayTextB ) |
|
virtual |
Viewer::Viewer | ( | const int | left, |
const int | top, | ||
const int | width, | ||
const int | height ) |
void Viewer::addHandler | ( | HandlerBase * | handler | ) |
void Viewer::AddShape | ( | const TopoDS_Shape & | shape | ) |
bool Viewer::axisCrossSettingsItemChanged | ( | const std::string & | _logicalName, |
const ot::Property * | _item, | ||
bool & | _settingsUpdateRequired ) |
void Viewer::cancelRubberband | ( | void | ) |
void Viewer::createRubberband | ( | ot::serviceID_t | _senderId, |
std::string & | _note, | ||
const std::string & | _configurationJson ) |
void Viewer::detachFromModel | ( | void | ) |
void Viewer::disableClipPlane | ( | void | ) |
bool Viewer::displaySettingsItemChanged | ( | const std::string & | _logicalName, |
const ot::Property * | _item, | ||
bool & | _settingsUpdateRequired ) |
void Viewer::enableClipPlane | ( | osg::Vec3d | normal, |
osg::Vec3d | point ) |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
void Viewer::finishRubberbandExecution | ( | void | ) |
void Viewer::freeze3DView | ( | bool | flag | ) |
bool Viewer::geometrySettingsItemChanged | ( | const std::string & | _logicalName, |
const ot::Property * | _item, | ||
bool & | _settingsUpdateRequired ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
osg::Matrix Viewer::getWorkingPlaneTransform | ( | void | ) |
|
inline |
void Viewer::hideClipPlaneHandles | ( | void | ) |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
|
inline |
|
overrideprotectedvirtual |
void Viewer::processHoverViewHandlers | ( | osgUtil::LineSegmentIntersector * | intersector | ) |
bool Viewer::propertyGridValueChanged | ( | const ot::Property * | _property | ) |
void Viewer::refresh | ( | bool | _ignoreUpdateSettingsRequest = true | ) |
void Viewer::removeHandler | ( | HandlerBase * | handler | ) |
void Viewer::removeOverlay | ( | void | ) |
void Viewer::reset | ( | ) |
void Viewer::reset1DPlotItemSelection | ( | void | ) |
|
overrideprotectedvirtual |
void Viewer::set1DPlotItemSelected | ( | unsigned long long | treeItemID, |
bool | controlPressed ) |
void Viewer::setClearColorAutomatic | ( | int | backgroundR, |
int | backgroundG, | ||
int | backgroundB, | ||
int | foregroundR, | ||
int | foregroundG, | ||
int | foregroundB ) |
void Viewer::setCursorText | ( | const std::string & | text | ) |
|
inline |
void Viewer::setLightSourceDistance | ( | const std::string & | value | ) |
void Viewer::setOverlayText | ( | const std::string & | text | ) |
void Viewer::setTabNames | ( | const std::string & | _osgViewTabName, |
const std::string & | _plotTabName, | ||
const std::string & | _versionGraphTabName ) |
void Viewer::settingsItemChanged | ( | const ot::Property * | _property | ) |
void Viewer::setWorkingPlaneTransform | ( | osg::Matrix | matrix | ) |
void Viewer::showClipPlaneHandles | ( | void | ) |
void Viewer::StartMessageLoop | ( | ) |
Starts message loop.
void Viewer::toggleAxisCross | ( | void | ) |
void Viewer::toggleCenterAxisCross | ( | void | ) |
void Viewer::toggleCutplane | ( | void | ) |
void Viewer::toggleWorkingPlane | ( | void | ) |
void Viewer::updateClipPlane | ( | osg::Vec3d | normal, |
osg::Vec3d | point ) |
|
overrideprotectedvirtual |
bool Viewer::workingPlaneSettingsItemChanged | ( | const std::string & | _logicalName, |
const ot::Property * | _item, | ||
bool & | _settingsUpdateRequired ) |