SUMO - Simulation of Urban MObility
GNEViewNet Class Reference

#include <GNEViewNet.h>

Inheritance diagram for GNEViewNet:
Inheritance graph
Collaboration diagram for GNEViewNet:
Collaboration graph

Public Member Functions

void abortOperation (bool clearSelection=true)
 
void addDecals (const std::vector< Decal > &decals)
 
bool autoSelectNodes ()
 
virtual void buildViewToolBars (GUIGlChildWindow &)
 builds the view toolbars More...
 
virtual void centerTo (GUIGlID id, bool applyZoom, SUMOReal zoomDist=20)
 centers to the chosen artifact More...
 
void centerTo (const Boundary &bound)
 centers to the chosen artifact More...
 
bool changeAllPhases () const
 
void destroyPopup ()
 destoys the popup More...
 
GUIPerspectiveChangergetChanger () const
 
FXComboBox & getColoringSchemesCombo ()
 
SUMOReal getDelay () const
 Returns the delay of the parent application. More...
 
SUMOReal getGridHeight () const
 
SUMOReal getGridWidth () const
 
GNENetgetNet ()
 
Position getPositionInformation () const
 Returns the cursor's x/y position within the network. More...
 
GNESelectorgetSelector ()
 
GNETLSEditorgetTLSEditor ()
 
virtual int getTrackedID () const
 
GUIDialog_EditViewportgetViewportEditor ()
 get the viewport and create it on first access More...
 
Boundary getVisibleBoundary () const
 
GUIVisualizationSettingsgetVisualisationSettings () const
 
GUIVisualizationSettingsgetVisualisationSettings ()
 
 GNEViewNet (FXComposite *tmpParent, FXComposite *actualParent, GUIMainWindow &app, GNEViewParent *viewParent, GNENet *net, FXGLVisual *glVis, FXGLCanvas *share, FXToolBar *toolBar)
 
void hotkeyDel ()
 
void hotkeyEnter ()
 
bool isInEditMode ()
 returns true, if the edit button was pressed More...
 
SUMOReal m2p (SUMOReal meter) const
 meter-to-pixels conversion method More...
 
FXbool makeCurrent ()
 A reimplementation due to some internal reasons. More...
 
void markPopupPosition ()
 
long onCmdAddReversedEdge (FXObject *, FXSelector, void *)
 add reversed edge More...
 
long onCmdChangeMode (FXObject *, FXSelector, void *)
 sets edit mode via combo box More...
 
long onCmdDeleteGeometry (FXObject *, FXSelector, void *)
 delete the closes geometry point More...
 
long onCmdDuplicateLane (FXObject *, FXSelector, void *)
 duplicate selected lane More...
 
long onCmdNodeReplace (FXObject *, FXSelector, void *)
 replace node by geometry More...
 
long onCmdNodeShape (FXObject *, FXSelector, void *)
 input custom node shape More...
 
long onCmdResetEdgeEndpoint (FXObject *, FXSelector, void *)
 restore geometry endpoint to node position More...
 
long onCmdReverseEdge (FXObject *, FXSelector, void *)
 reverse edge More...
 
long onCmdSetEdgeEndpoint (FXObject *, FXSelector, void *)
 set non-default geometry endpoint More...
 
long onCmdSimplifyShape (FXObject *, FXSelector, void *)
 simply shape of current polygon More...
 
long onCmdSplitEdge (FXObject *, FXSelector, void *)
 split edge at cursor position More...
 
long onCmdSplitEdgeBidi (FXObject *, FXSelector, void *)
 split edge at cursor position More...
 
long onCmdStraightenEdges (FXObject *, FXSelector, void *)
 makes selected edges straight More...
 
virtual long onConfigure (FXObject *, FXSelector, void *)
 
virtual void onGamingClick (Position)
 
virtual long onKeyPress (FXObject *o, FXSelector sel, void *data)
 
virtual long onKeyRelease (FXObject *o, FXSelector sel, void *data)
 
virtual long onMiddleBtnPress (FXObject *, FXSelector, void *)
 
virtual long onMiddleBtnRelease (FXObject *, FXSelector, void *)
 
virtual long onMouseLeft (FXObject *, FXSelector, void *)
 
virtual long onMouseWheel (FXObject *, FXSelector, void *)
 
virtual long onPaint (FXObject *, FXSelector, void *)
 
virtual long onRightBtnPress (FXObject *, FXSelector, void *)
 
virtual long onRightBtnRelease (FXObject *, FXSelector, void *)
 
virtual void openObjectDialog ()
 
SUMOReal p2m (SUMOReal pixel) const
 pixels-to-meters conversion method More...
 
virtual void recenterView ()
 recenters the view More...
 
void remove (GUIDialog_EditViewport *)
 
void remove (GUIDialog_ViewSettings *)
 
bool selectEdges ()
 
bool setColorScheme (const std::string &name)
 
void setDelay (SUMOReal delay)
 Sets the delay of the parent application. More...
 
void setEditModeFromHotkey (FXushort selid)
 sets edit mode (from hotkey) More...
 
void setSelectionScaling (SUMOReal selectionScale)
 
void setStatusBarText (const std::string &text)
 
virtual void setViewport (const Position &lookFrom, const Position &lookAt)
 applies the given viewport settings More...
 
void setWindowCursorPosition (FXint x, FXint y)
 Returns the information whether rotation is allowd. More...
 
void showToolTips (bool val)
 
virtual void showViewportEditor ()
 
void showViewschemeEditor ()
 
virtual void startTrack (int)
 
virtual void stopTrack ()
 
void updateControls ()
 update control contents after undo/redo or recompute More...
 
void updateToolTip ()
 A method that updates the tooltip. More...
 
virtual ~GNEViewNet ()
 destructor More...
 
long onLeftBtnPress (FXObject *, FXSelector, void *)
 
long onLeftBtnRelease (FXObject *, FXSelector, void *)
 
long onMouseMove (FXObject *, FXSelector, void *)
 
Dealing with snapshots
void setSnapshots (std::map< SUMOTime, std::string > snaps)
 Sets the snapshot time to file map. More...
 
std::string makeSnapshot (const std::string &destFile)
 Takes a snapshots and writes it into the given file. More...
 
virtual void saveFrame (const std::string &destFile, FXColor *buf)
 Adds a frame to a video snapshot which will be initialized if neccessary. More...
 
virtual void endSnapshot ()
 Ends a video snapshot. More...
 
virtual void checkSnapshots ()
 Checks whether it is time for a snapshot. More...
 
virtual SUMOTime getCurrentTimeStep () const
 get the current simulation time More...
 
Additional visualisations
bool addAdditionalGLVisualisation (GUIGlObject *const which)
 Adds an object to call its additional visualisation method. More...
 
bool removeAdditionalGLVisualisation (GUIGlObject *const which)
 Removes an object from the list of objects that show additional things. More...
 

Protected Member Functions

void applyGLTransform (bool fixRatio=true)
 
FXImage * checkGDALImage (Decal &d)
 check whether we can read image data or position with gdal More...
 
void displayLegend ()
 
void doInit ()
 called after some features are already initialized More...
 
int doPaintGL (int mode, const Boundary &bound)
 
void drawDecals ()
 Draws the stored decals. More...
 
GUIGlID getObjectAtPosition (Position pos)
 returns the id of the object at position using GL_SELECT More...
 
std::vector< GUIGlIDgetObjectsAtPosition (Position pos, SUMOReal radius)
 returns the ids of the object at position within the given (rectangular) radius using GL_SELECT More...
 
std::vector< GUIGlIDgetObjectsInBoundary (const Boundary &bound)
 returns the ids of all objects in the given boundary More...
 
GUIGlID getObjectUnderCursor ()
 returns the id of the object under the cursor using GL_SELECT More...
 
 GNEViewNet ()
 FOX needs this. More...
 
void paintGL ()
 performs the painting of the simulation More...
 
void paintGLGrid ()
 paints a grid More...
 
void showToolTipFor (unsigned int id)
 invokes the tooltip for the given object More...
 
void updatePositionInformation () const
 

Protected Attributes

std::map< GUIGlObject *, int > myAdditionallyDrawn
 List of objects for which GUIGlObject::drawGLAdditional is called. More...
 
bool myAmInitialised
 Internal information whether doInit() was called. More...
 
GUIMainWindowmyApp
 The application. More...
 
GUIPerspectiveChangermyChanger
 The perspective changer. More...
 
SUMORTreemyGrid
 The visualization speed-up. More...
 
bool myInEditMode
 Information whether too-tip informations shall be generated. More...
 
int myMouseHotspotX
 Offset to the mouse-hotspot from the mouse position. More...
 
int myMouseHotspotY
 
GUIGlChildWindowmyParent
 The parent window. More...
 
MFXMutex myPolyDrawLock
 
GUIGLObjectPopupMenumyPopup
 The current popup-menu. More...
 
std::map< SUMOTime, std::string > mySnapshots
 
bool myUseToolTips
 
GUIDialog_EditViewportmyViewportChooser
 
GUIDialog_ViewSettingsmyVisualizationChanger
 
GUIVisualizationSettingsmyVisualizationSettings
 
FXint myWindowCursorPositionX
 Position of the cursor relative to the window. More...
 
FXint myWindowCursorPositionY
 
Optionally shown decals
std::vector< DecalmyDecals
 The list of decals to show. More...
 
MFXMutex myDecalsLock
 The mutex to use before accessing the decals list in order to avoid thread conficts. More...
 

Private Member Functions

void buildEditModeControls ()
 adds controls for setting the edit mode More...
 
void deleteSelectedEdges ()
 delete all currently selected edges More...
 
void deleteSelectedJunctions ()
 delete all currently selected junctions More...
 
GNEEdgegetEdgeAtCursorPosition (Position &pos)
 try to retrieve an edge at the given position More...
 
std::set< GNEEdge * > getEdgesAtCursorPosition (Position &pos)
 try to retrieve multiple edges at the given position More...
 
GNEJunctiongetJunctionAtCursorPosition (Position &pos)
 try to retrieve a junction at the given position More...
 
GNELanegetLaneAtCurserPosition (Position &pos)
 try to retrieve a lane at the given position More...
 
bool mergeJunctions (GNEJunction *moved)
 try to merge moved junction with another junction in that spot return true if merging did take place More...
 
void removeCurrentPoly ()
 remove the currently edited polygon More...
 
void setEditMode (EditMode mode)
 
void updateModeSpecificControls ()
 updates mode specific controls More...
 

Private Attributes

FXMenuCheck * myChangeAllPhases
 
GNEConnectormyConnector
 
GNEPolymyCurrentPoly
 
EditMode myEditMode
 
FXMenuCheck * myExtendToEdgeNodes
 
GNEInspectormyInspector
 
GNENetmyNet
 
Position myPopupSpot
 
EditMode myPreviousEditMode
 
FXMenuCheck * mySelectEdges
 
GNESelectormySelector
 
GNETLSEditormyTLSEditor
 
GNEUndoListmyUndoList
 a reference to the undolist maintained in the application More...
 
the state-variables of the create-edge state-machine
GNEJunctionmyCreateEdgeSource
 
FXMenuCheck * myChainCreateEdge
 
FXMenuCheck * myAutoCreateOppositeEdge
 
the state-variables of the move state-machine
GNEJunctionmyJunctionToMove
 
GNEEdgemyEdgeToMove
 the edge of which geometry is being moved More...
 
GNEPolymyPolyToMove
 the poly of which geometry is being moved More...
 
Position myMoveSrc
 position from which to move edge geometry More...
 
bool myMoveSelection
 whether a selection is being moved More...
 
FXMenuCheck * myWarnAboutMerge
 whether we should warn about merging junctions More...
 
state-variables of select-mode
bool myAmInRectSelect
 
Position mySelCorner1
 
Position mySelCorner2
 
FXToolBar * myToolbar
 a reference to the toolbar in myParent More...
 
FXComboBox * myEditModesCombo
 combo box for selecting the edit mode More...
 
StringBijection< EditModemyEditModeNames
 since we cannot switch on strings we map the mode names to an enum More...
 

Detailed Description

Microsocopic view at the simulation

Definition at line 87 of file GNEViewNet.h.

Constructor & Destructor Documentation

GNEViewNet::GNEViewNet ( FXComposite *  tmpParent,
FXComposite *  actualParent,
GUIMainWindow app,
GNEViewParent viewParent,
GNENet net,
FXGLVisual *  glVis,
FXGLCanvas *  share,
FXToolBar *  toolBar 
)
GNEViewNet::~GNEViewNet ( )
virtual

destructor

Definition at line 252 of file GNEViewNet.cpp.

GNEViewNet::GNEViewNet ( )
inlineprotected

FOX needs this.

Definition at line 218 of file GNEViewNet.h.

Member Function Documentation

bool GUISUMOAbstractView::addAdditionalGLVisualisation ( GUIGlObject *const  which)
inherited

Adds an object to call its additional visualisation method.

Parameters
[in]whichThe object to add
Returns
Always true
See also
GUIGlObject::drawGLAdditional

Definition at line 1085 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::myAdditionallyDrawn.

Referenced by GUIBaseVehicle::addActiveAddVisualisation(), GUIPerson::addActiveAddVisualisation(), and GUISUMOAbstractView::onGamingClick().

void GUISUMOAbstractView::addDecals ( const std::vector< Decal > &  decals)
inlineinherited
bool GNEViewNet::autoSelectNodes ( )
inline

Definition at line 187 of file GNEViewNet.h.

References myExtendToEdgeNodes.

Referenced by GNESelector::handleIDs().

void GNEViewNet::buildViewToolBars ( GUIGlChildWindow cw)
virtual
void GUISUMOAbstractView::centerTo ( GUIGlID  id,
bool  applyZoom,
SUMOReal  zoomDist = 20 
)
virtualinherited

centers to the chosen artifact

Parameters
[in]idThe id of the artifact to center to
[in]applyZoomWhether to zoom in
[in]zoomDistThe distance in m to use for the zoom, values < 0 means: use the centeringBoundary
Note
caller is responsible for calling update

Definition at line 506 of file GUISUMOAbstractView.cpp.

References GUIPerspectiveChanger::centerTo(), Boundary::getCenter(), GUIGlObject::getCenteringBoundary(), GUIGlObjectStorage::getObjectBlocking(), GUIGlObjectStorage::gIDStorage, GUISUMOAbstractView::myChanger, GUIPerspectiveChanger::setViewport(), GUIGlObjectStorage::unblockObject(), and GUISUMOAbstractView::updatePositionInformation().

Referenced by GUISUMOAbstractView::buildViewToolBars(), GUIGLObjectPopupMenu::onCmdCenter(), GUISUMOAbstractView::paintGL(), TraCIServerAPI_GUI::processSet(), and GUIGlChildWindow::setView().

void GUISUMOAbstractView::centerTo ( const Boundary bound)
inherited

centers to the chosen artifact

Definition at line 523 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::myChanger, and GUIPerspectiveChanger::setViewport().

bool GNEViewNet::changeAllPhases ( ) const
inline

Definition at line 207 of file GNEViewNet.h.

References doInit(), doPaintGL(), and myChangeAllPhases.

Referenced by GNETLSEditor::handleChange().

void GUISUMOAbstractView::checkSnapshots ( )
virtualinherited
void GNEViewNet::deleteSelectedEdges ( )
private
void GNEViewNet::deleteSelectedJunctions ( )
private

delete all currently selected junctions

Definition at line 1158 of file GNEViewNet.cpp.

References GNENet::deleteJunction(), myNet, myUndoList, GNEUndoList::p_begin(), GNEUndoList::p_end(), and GNENet::retrieveJunctions().

Referenced by hotkeyDel().

void GUISUMOAbstractView::displayLegend ( )
protectedinherited

brief Draws the size legend

Draws a line with ticks, and the length information.

Definition at line 419 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::m2p(), pfDrawString(), pfSetPosition(), pfSetScaleXY(), and SUMOReal.

Referenced by GUISUMOAbstractView::doInit(), GUISUMOAbstractView::makeSnapshot(), and GUISUMOAbstractView::paintGL().

void GNEViewNet::doInit ( )
protectedvirtual

called after some features are already initialized

Reimplemented from GUISUMOAbstractView.

Definition at line 256 of file GNEViewNet.cpp.

Referenced by changeAllPhases().

virtual void GUISUMOAbstractView::endSnapshot ( )
inlinevirtualinherited

Ends a video snapshot.

Reimplemented in GUIViewTraffic.

Definition at line 193 of file GUISUMOAbstractView.h.

References GUISUMOAbstractView::checkSnapshots().

Referenced by GUISUMOViewParent::onCmdMakeSnapshot().

FXComboBox & GUISUMOAbstractView::getColoringSchemesCombo ( )
inherited
virtual SUMOTime GUISUMOAbstractView::getCurrentTimeStep ( ) const
inlinevirtualinherited
SUMOReal GUISUMOAbstractView::getDelay ( ) const
inherited

Returns the delay of the parent application.

Returns
delay in milliseconds

Definition at line 1134 of file GUISUMOAbstractView.cpp.

References GUIMainWindow::getDelay(), and GUISUMOAbstractView::myApp.

Referenced by GUISUMOAbstractView::getVisualisationSettings(), and GUIDialog_ViewSettings::onCmdExportSetting().

std::set< GNEEdge * > GNEViewNet::getEdgesAtCursorPosition ( Position pos)
private
SUMOReal GUISUMOAbstractView::getGridHeight ( ) const
inherited
SUMOReal GUISUMOAbstractView::getGridWidth ( ) const
inherited
GNELane * GNEViewNet::getLaneAtCurserPosition ( Position pos)
private
std::vector< GUIGlID > GUISUMOAbstractView::getObjectsAtPosition ( Position  pos,
SUMOReal  radius 
)
protectedinherited
GUIGlID GUISUMOAbstractView::getObjectUnderCursor ( )
protectedinherited
GNETLSEditor* GNEViewNet::getTLSEditor ( )
inline

Definition at line 203 of file GNEViewNet.h.

References myTLSEditor.

virtual int GUISUMOAbstractView::getTrackedID ( ) const
inlinevirtualinherited
Boundary GUISUMOAbstractView::getVisibleBoundary ( ) const
inherited
GUIVisualizationSettings* GUISUMOAbstractView::getVisualisationSettings ( ) const
inlineinherited
bool GUISUMOAbstractView::isInEditMode ( )
inherited

returns true, if the edit button was pressed

Definition at line 157 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::myInEditMode.

Referenced by GUISUMOAbstractView::buildViewToolBars().

std::string GUISUMOAbstractView::makeSnapshot ( const std::string &  destFile)
inherited

Takes a snapshots and writes it into the given file.

The format to use is determined from the extension. If compiled with ffmpeg and a video format is requested it will instantiate a video encoder.

Parameters
[in]destFileThe name of the file to write the snapshot into
Returns
The error message, if an error occcured; "" otherwise

Definition at line 731 of file GUISUMOAbstractView.cpp.

References RGBColor::alpha(), GUIVisualizationSettings::antialiase, GUISUMOAbstractView::applyGLTransform(), GUIVisualizationSettings::backgroundColor, RGBColor::blue(), GUISUMOAbstractView::displayLegend(), GUIVisualizationSettings::dither, GUISUMOAbstractView::doPaintGL(), GUISUMOAbstractView::drawDecals(), GUIPerspectiveChanger::getViewport(), RGBColor::green(), GUISUMOAbstractView::m2p(), GUISUMOAbstractView::makeCurrent(), GUISUMOAbstractView::myChanger, GUISUMOAbstractView::myGrid, GUISUMOAbstractView::myUseToolTips, GUISUMOAbstractView::myVisualizationSettings, GUISUMOAbstractView::paintGLGrid(), RGBColor::red(), GUISUMOAbstractView::saveFrame(), MFXImageHelper::saveImage(), GUIVisualizationSettings::scale, SUMORTree::Search(), GUIVisualizationSettings::showGrid, GUIVisualizationSettings::showSizeLegend, FXSingleEventThread::sleep(), SUMO_const_laneWidth, Boundary::xmax(), Boundary::xmin(), Boundary::ymax(), and Boundary::ymin().

Referenced by GUIViewTraffic::checkSnapshots(), GUISUMOAbstractView::checkSnapshots(), GUIApplicationWindow::handleEvent_Screenshot(), GNEViewParent::onCmdMakeSnapshot(), GUISUMOViewParent::onCmdMakeSnapshot(), and GUISUMOAbstractView::onMiddleBtnRelease().

void GNEViewNet::markPopupPosition ( )

Definition at line 743 of file GNEViewNet.cpp.

References GUISUMOAbstractView::getPositionInformation(), and myPopupSpot.

long GNEViewNet::onCmdAddReversedEdge ( FXObject *  ,
FXSelector  ,
void *   
)

add reversed edge

Definition at line 869 of file GNEViewNet.cpp.

References GNENet::addReversedEdge(), getEdgeAtCursorPosition(), myNet, myPopupSpot, and myUndoList.

long GNEViewNet::onCmdChangeMode ( FXObject *  ,
FXSelector  ,
void *  data 
)

sets edit mode via combo box

Definition at line 704 of file GNEViewNet.cpp.

References StringBijection< T >::get(), myEditModeNames, and setEditMode().

long GNEViewNet::onCmdDeleteGeometry ( FXObject *  ,
FXSelector  ,
void *   
)

delete the closes geometry point

Definition at line 930 of file GNEViewNet.cpp.

References GNEPoly::deleteGeometryNear(), myCurrentPoly, and myPopupSpot.

long GNEViewNet::onCmdDuplicateLane ( FXObject *  ,
FXSelector  ,
void *   
)
long GNEViewNet::onCmdNodeReplace ( FXObject *  ,
FXSelector  ,
void *   
)

replace node by geometry

Definition at line 1004 of file GNEViewNet.cpp.

References getJunctionAtCursorPosition(), myNet, myPopupSpot, myUndoList, and GNENet::replaceJunctionByGeometry().

long GNEViewNet::onCmdResetEdgeEndpoint ( FXObject *  ,
FXSelector  ,
void *   
)

restore geometry endpoint to node position

Definition at line 889 of file GNEViewNet.cpp.

References getEdgeAtCursorPosition(), myPopupSpot, myUndoList, and GNEEdge::resetEndpoint().

long GNEViewNet::onCmdReverseEdge ( FXObject *  ,
FXSelector  ,
void *   
)

reverse edge

Definition at line 859 of file GNEViewNet.cpp.

References getEdgeAtCursorPosition(), myNet, myPopupSpot, myUndoList, and GNENet::reverseEdge().

long GNEViewNet::onCmdSetEdgeEndpoint ( FXObject *  ,
FXSelector  ,
void *   
)

set non-default geometry endpoint

Definition at line 879 of file GNEViewNet.cpp.

References getEdgeAtCursorPosition(), myPopupSpot, myUndoList, and GNEEdge::setEndpoint().

long GNEViewNet::onCmdSimplifyShape ( FXObject *  ,
FXSelector  ,
void *   
)

simply shape of current polygon

Definition at line 920 of file GNEViewNet.cpp.

References myCurrentPoly, and GNEPoly::simplifyShape().

long GNEViewNet::onCmdSplitEdge ( FXObject *  ,
FXSelector  ,
void *   
)

split edge at cursor position

Definition at line 839 of file GNEViewNet.cpp.

References getEdgeAtCursorPosition(), GNEEdge::getSplitPos(), myNet, myPopupSpot, myUndoList, and GNENet::splitEdge().

long GNEViewNet::onCmdSplitEdgeBidi ( FXObject *  ,
FXSelector  ,
void *   
)

split edge at cursor position

Definition at line 849 of file GNEViewNet.cpp.

References getEdgesAtCursorPosition(), myNet, myPopupSpot, myUndoList, and GNENet::splitEdgesBidi().

long GNEViewNet::onCmdStraightenEdges ( FXObject *  ,
FXSelector  ,
void *   
)
virtual void GUISUMOAbstractView::onGamingClick ( Position  )
inlinevirtualinherited
long GUISUMOAbstractView::onKeyPress ( FXObject *  o,
FXSelector  sel,
void *  data 
)
virtualinherited
long GUISUMOAbstractView::onKeyRelease ( FXObject *  o,
FXSelector  sel,
void *  data 
)
virtualinherited
long GNEViewNet::onLeftBtnPress ( FXObject *  obj,
FXSelector  sel,
void *  data 
)
virtual

overloaded handlers

Reimplemented from GUISUMOAbstractView.

Definition at line 375 of file GNEViewNet.cpp.

References GNENet::createEdge(), GNENet::createJunction(), GNENet::deleteGeometryOrEdge(), GNENet::deleteJunction(), GNENet::deleteLane(), GNETLSEditor::editJunction(), GNEInspector::getEdgeTemplate(), GUIGlObject::getGlID(), GUIGlObject::getMicrosimID(), GUIGlObjectStorage::getObjectBlocking(), GUISUMOAbstractView::getObjectUnderCursor(), GNELane::getParentEdge(), GUISUMOAbstractView::getPositionInformation(), GUISelectedStorage::getSelected(), GNENet::getShapeContainer(), GUIGlObject::getType(), GUIGlObjectStorage::gIDStorage, GLO_CROSSING, GLO_EDGE, GLO_JUNCTION, GLO_LANE, GLO_POI, GLO_POLYGON, GNE_MODE_CONNECT, GNE_MODE_CREATE_EDGE, GNE_MODE_DELETE, GNE_MODE_INSPECT, GNE_MODE_MOVE, GNE_MODE_SELECT, GNE_MODE_TLS, gSelected, GNEConnector::handleLaneClick(), GNEUndoList::hasCommandGroup(), GNEInspector::inspect(), GUISelectedStorage::isSelected(), GUISUMOAbstractView::makeCurrent(), GNEJunction::markAsCreateEdgeSource(), myAmInRectSelect, myAutoCreateOppositeEdge, myChainCreateEdge, myConnector, myCreateEdgeSource, myEdgeToMove, myEditMode, myInspector, myJunctionToMove, myMoveSelection, myMoveSrc, myNet, myPolyToMove, mySelCorner1, mySelCorner2, mySelectEdges, myTLSEditor, myUndoList, GUISUMOAbstractView::onLeftBtnPress(), GNEUndoList::p_begin(), GNEUndoList::p_end(), ShapeContainer::removePOI(), GNENet::retrieveAttributeCarriers(), selectEdges(), setStatusBarText(), GUISelectedStorage::toggleSelection(), GUIGlObjectStorage::unblockObject(), and GNEJunction::unMarkAsCreateEdgeSource().

virtual long GUISUMOAbstractView::onMiddleBtnPress ( FXObject *  ,
FXSelector  ,
void *   
)
inlinevirtualinherited

Definition at line 141 of file GUISUMOAbstractView.h.

long GUISUMOAbstractView::onMouseLeft ( FXObject *  ,
FXSelector  ,
void *   
)
virtualinherited

Definition at line 672 of file GUISUMOAbstractView.cpp.

Referenced by GUISUMOAbstractView::onMiddleBtnRelease().

long GUISUMOAbstractView::onMouseWheel ( FXObject *  ,
FXSelector  ,
void *  data 
)
virtualinherited
long GUISUMOAbstractView::onPaint ( FXObject *  ,
FXSelector  ,
void *   
)
virtualinherited
long GUISUMOAbstractView::onRightBtnPress ( FXObject *  ,
FXSelector  ,
void *  data 
)
virtualinherited
void GUISUMOAbstractView::remove ( GUIDialog_EditViewport )
inlineinherited
void GUISUMOAbstractView::remove ( GUIDialog_ViewSettings )
inlineinherited
bool GUISUMOAbstractView::removeAdditionalGLVisualisation ( GUIGlObject *const  which)
inherited

Removes an object from the list of objects that show additional things.

Parameters
[in]whichThe object to remoe
Returns
True if the object was known, false otherwise
See also
GUIGlObject::drawGLAdditional

Definition at line 1097 of file GUISUMOAbstractView.cpp.

References GUIGlObject::getGlID(), GUISUMOAbstractView::getTrackedID(), GUISUMOAbstractView::myAdditionallyDrawn, and GUISUMOAbstractView::stopTrack().

Referenced by GUISUMOAbstractView::onGamingClick(), GUIBaseVehicle::removeActiveAddVisualisation(), and GUIPerson::removeActiveAddVisualisation().

void GNEViewNet::removeCurrentPoly ( )
private

remove the currently edited polygon

Definition at line 994 of file GNEViewNet.cpp.

References GNENet::getVisualisationSpeedUp(), myCurrentPoly, myNet, and SUMORTree::removeAdditionalGLObject().

Referenced by abortOperation(), hotkeyEnter(), and onCmdNodeShape().

virtual void GUISUMOAbstractView::saveFrame ( const std::string &  destFile,
FXColor *  buf 
)
inlinevirtualinherited

Adds a frame to a video snapshot which will be initialized if neccessary.

Reimplemented in GUIViewTraffic.

Definition at line 185 of file GUISUMOAbstractView.h.

References UNUSED_PARAMETER.

Referenced by GUISUMOAbstractView::makeSnapshot().

bool GNEViewNet::selectEdges ( )
inline

Definition at line 181 of file GNEViewNet.h.

References mySelectEdges.

Referenced by GNESelector::onCmdInvert(), onLeftBtnPress(), and onLeftBtnRelease().

void GUISUMOAbstractView::setDelay ( SUMOReal  delay)
inherited

Sets the delay of the parent application.

Definition at line 1140 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::myApp, and GUIMainWindow::setDelay().

Referenced by GUISUMOAbstractView::getVisualisationSettings(), and GUIDialog_ViewSettings::loadSettings().

void GNEViewNet::setSelectionScaling ( SUMOReal  selectionScale)
inline
void GUISUMOAbstractView::setSnapshots ( std::map< SUMOTime, std::string >  snaps)
inherited

Sets the snapshot time to file map.

Parameters
[in]snapsThe snapshots to take at certain times

Definition at line 725 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::mySnapshots.

Referenced by GUISUMOAbstractView::onMiddleBtnRelease(), and GUISettingsHandler::setSnapshots().

void GUISUMOAbstractView::setWindowCursorPosition ( FXint  x,
FXint  y 
)
inherited

Returns the information whether rotation is allowd.

Returns the gl-id of the object under the given coordinates

Definition at line 537 of file GUISUMOAbstractView.cpp.

References GUISUMOAbstractView::myMouseHotspotX, GUISUMOAbstractView::myMouseHotspotY, GUISUMOAbstractView::myWindowCursorPositionX, and GUISUMOAbstractView::myWindowCursorPositionY.

Referenced by GUISUMOAbstractView::buildViewToolBars(), and GUIDanielPerspectiveChanger::onMouseMove().

void GUISUMOAbstractView::showToolTips ( bool  val)
inherited
virtual void GUISUMOAbstractView::startTrack ( int  )
inlinevirtualinherited
void GNEViewNet::updateControls ( )

update control contents after undo/redo or recompute

Definition at line 1236 of file GNEViewNet.cpp.

References GNE_MODE_INSPECT, myEditMode, myInspector, and GNEInspector::update().

Referenced by setSelectionScaling(), and GNEApplicationWindow::updateControls().

void GUISUMOAbstractView::updateToolTip ( )
inherited

Field Documentation

std::map<GUIGlObject*, int> GUISUMOAbstractView::myAdditionallyDrawn
protectedinherited
bool GUISUMOAbstractView::myAmInitialised
protectedinherited

Internal information whether doInit() was called.

Definition at line 421 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::onConfigure(), GUISUMOAbstractView::onPaint(), and GUISUMOAbstractView::openObjectDialog().

bool GNEViewNet::myAmInRectSelect
private
FXMenuCheck* GNEViewNet::myAutoCreateOppositeEdge
private

Definition at line 246 of file GNEViewNet.h.

Referenced by buildEditModeControls(), onLeftBtnPress(), and updateModeSpecificControls().

FXMenuCheck* GNEViewNet::myChainCreateEdge
private

Definition at line 245 of file GNEViewNet.h.

Referenced by buildEditModeControls(), onLeftBtnPress(), and updateModeSpecificControls().

FXMenuCheck* GNEViewNet::myChangeAllPhases
private
GNEConnector* GNEViewNet::myConnector
private
GNEJunction* GNEViewNet::myCreateEdgeSource
private

Definition at line 240 of file GNEViewNet.h.

Referenced by abortOperation(), and onLeftBtnPress().

GNEPoly* GNEViewNet::myCurrentPoly
private
std::vector<Decal> GUISUMOAbstractView::myDecals
protectedinherited
MFXMutex GUISUMOAbstractView::myDecalsLock
protectedinherited

The mutex to use before accessing the decals list in order to avoid thread conficts.

Definition at line 438 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::drawDecals(), and GUISUMOAbstractView::showViewschemeEditor().

GNEEdge* GNEViewNet::myEdgeToMove
private

the edge of which geometry is being moved

Definition at line 258 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), onLeftBtnRelease(), and onMouseMove().

StringBijection<EditMode> GNEViewNet::myEditModeNames
private

since we cannot switch on strings we map the mode names to an enum

Definition at line 293 of file GNEViewNet.h.

Referenced by buildEditModeControls(), onCmdChangeMode(), and setEditModeFromHotkey().

FXComboBox* GNEViewNet::myEditModesCombo
private

combo box for selecting the edit mode

Definition at line 289 of file GNEViewNet.h.

Referenced by buildEditModeControls(), and setEditModeFromHotkey().

FXMenuCheck* GNEViewNet::myExtendToEdgeNodes
private
bool GUISUMOAbstractView::myInEditMode
protectedinherited

Information whether too-tip informations shall be generated.

Definition at line 408 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::isInEditMode().

GNEInspector* GNEViewNet::myInspector
private

Definition at line 301 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), updateControls(), and updateModeSpecificControls().

GNEJunction* GNEViewNet::myJunctionToMove
private

Definition at line 255 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), onLeftBtnRelease(), and onMouseMove().

int GUISUMOAbstractView::myMouseHotspotX
protectedinherited

Offset to the mouse-hotspot from the mouse position.

Definition at line 411 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::setWindowCursorPosition().

int GUISUMOAbstractView::myMouseHotspotY
protectedinherited

Definition at line 411 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::setWindowCursorPosition().

bool GNEViewNet::myMoveSelection
private

whether a selection is being moved

Definition at line 267 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), onLeftBtnRelease(), and onMouseMove().

Position GNEViewNet::myMoveSrc
private

position from which to move edge geometry

Definition at line 264 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), and onMouseMove().

GUIGlChildWindow* GUISUMOAbstractView::myParent
protectedinherited

The parent window.

Definition at line 399 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::getColoringSchemesCombo().

MFXMutex GUISUMOAbstractView::myPolyDrawLock
mutableprotectedinherited

Definition at line 444 of file GUISUMOAbstractView.h.

GNEPoly* GNEViewNet::myPolyToMove
private

the poly of which geometry is being moved

Definition at line 261 of file GNEViewNet.h.

Referenced by onLeftBtnPress(), onLeftBtnRelease(), and onMouseMove().

GUIGLObjectPopupMenu* GUISUMOAbstractView::myPopup
protectedinherited
EditMode GNEViewNet::myPreviousEditMode
private

Definition at line 228 of file GNEViewNet.h.

Referenced by setEditMode().

Position GNEViewNet::mySelCorner1
private

Definition at line 280 of file GNEViewNet.h.

Referenced by doPaintGL(), onLeftBtnPress(), and onLeftBtnRelease().

Position GNEViewNet::mySelCorner2
private

Definition at line 281 of file GNEViewNet.h.

Referenced by doPaintGL(), onLeftBtnPress(), onLeftBtnRelease(), and onMouseMove().

FXMenuCheck* GNEViewNet::mySelectEdges
private
GNESelector* GNEViewNet::mySelector
private

Definition at line 304 of file GNEViewNet.h.

Referenced by getSelector(), onLeftBtnRelease(), and updateModeSpecificControls().

std::map<SUMOTime, std::string> GUISUMOAbstractView::mySnapshots
protectedinherited
GNETLSEditor* GNEViewNet::myTLSEditor
private
FXToolBar* GNEViewNet::myToolbar
private

a reference to the toolbar in myParent

Definition at line 287 of file GNEViewNet.h.

Referenced by buildEditModeControls(), and updateModeSpecificControls().

FXMenuCheck* GNEViewNet::myWarnAboutMerge
private

whether we should warn about merging junctions

Definition at line 270 of file GNEViewNet.h.

Referenced by buildEditModeControls(), mergeJunctions(), and updateModeSpecificControls().

FXint GUISUMOAbstractView::myWindowCursorPositionX
protectedinherited

Position of the cursor relative to the window.

Definition at line 426 of file GUISUMOAbstractView.h.

Referenced by GUISUMOAbstractView::getPositionInformation(), and GUISUMOAbstractView::setWindowCursorPosition().

FXint GUISUMOAbstractView::myWindowCursorPositionY
protectedinherited

The documentation for this class was generated from the following files: