Eclipse SUMO - Simulation of Urban MObility
GUIBaseVehicleHelper.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
14 // Functions used in GUIBaseVehicleHelper and GNEVehicle
15 /****************************************************************************/
16 #ifndef GUIBaseVehicleHelper_h
17 #define GUIBaseVehicleHelper_h
18 
19 
20 // ===========================================================================
21 // included modules
22 // ===========================================================================
23 #include <config.h>
24 
25 #include <string>
26 
27 
28 // ===========================================================================
29 // class declarations
30 // ===========================================================================
32 class GUIGlObject;
33 
34 
35 // ===========================================================================
36 // class definitions
37 // ===========================================================================
43 public:
44 
46  static void drawPoly(const double* poses, const double offset);
47 
49  static void drawAction_drawVehicleAsBoxPlus(const double width, const double length);
50 
52  static void drawAction_drawVehicleAsTrianglePlus(const double width, const double length);
53 
55  static void drawAction_drawVehicleAsPoly(const GUIVisualizationSettings& s, const SUMOVehicleShape shape, const double width, const double length,
56  int carriageIndex = -1);
57 
61  static bool drawAction_drawVehicleAsImage(const GUIVisualizationSettings& s, const std::string& file,
62  const GUIGlObject* o, const double width, double length);
63 };
64 
65 
66 #endif
67 
68 /****************************************************************************/
69 
GUIBaseVehicleHelper::drawPoly
static void drawPoly(const double *poses, const double offset)
draw poly
Definition: GUIBaseVehicleHelper.cpp:96
GUIBaseVehicleHelper::drawAction_drawVehicleAsImage
static bool drawAction_drawVehicleAsImage(const GUIVisualizationSettings &s, const std::string &file, const GUIGlObject *o, const double width, double length)
try to draw vehicle as raster image and return true if sucessful
Definition: GUIBaseVehicleHelper.cpp:619
GUIBaseVehicleHelper::drawAction_drawVehicleAsPoly
static void drawAction_drawVehicleAsPoly(const GUIVisualizationSettings &s, const SUMOVehicleShape shape, const double width, const double length, int carriageIndex=-1)
draw vehicle as a polygon
Definition: GUIBaseVehicleHelper.cpp:143
SUMOVehicleShape
SUMOVehicleShape
Definition of vehicle classes to differ between different appearences.
Definition: SUMOVehicleClass.h:50
GUIGlObject
Definition: GUIGlObject.h:65
GUIBaseVehicleHelper::drawAction_drawVehicleAsBoxPlus
static void drawAction_drawVehicleAsBoxPlus(const double width, const double length)
draw vehicle as a Box
Definition: GUIBaseVehicleHelper.cpp:111
GUIBaseVehicleHelper
A MSVehicle extended by some values for usage within the gui.
Definition: GUIBaseVehicleHelper.h:42
config.h
GUIVisualizationSettings
Stores the information about how to visualize structures.
Definition: GUIVisualizationSettings.h:345
GUIBaseVehicleHelper::drawAction_drawVehicleAsTrianglePlus
static void drawAction_drawVehicleAsTrianglePlus(const double width, const double length)
draw vehicle as a triangle
Definition: GUIBaseVehicleHelper.cpp:126