SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Polygon.cpp
Go to the documentation of this file.
1 /****************************************************************************/
9 // A 2D-polygon
10 /****************************************************************************/
11 // SUMO, Simulation of Urban MObility; see http://sumo-sim.org/
12 // Copyright (C) 2004-2014 DLR (http://www.dlr.de/) and contributors
13 /****************************************************************************/
14 //
15 // This file is part of SUMO.
16 // SUMO is free software: you can redistribute it and/or modify
17 // it under the terms of the GNU General Public License as published by
18 // the Free Software Foundation, either version 3 of the License, or
19 // (at your option) any later version.
20 //
21 /****************************************************************************/
22 
23 
24 // ===========================================================================
25 // included modules
26 // ===========================================================================
27 #ifdef _MSC_VER
28 #include <windows_config.h>
29 #else
30 #include <config.h>
31 #endif
32 
33 #include "Polygon.h"
34 using namespace SUMO;
35 
36 #ifdef CHECK_MEMORY_LEAKS
37 #include <foreign/nvwa/debug_new.h>
38 #endif // CHECK_MEMORY_LEAKS
39 
40 
41 // ===========================================================================
42 // member definitions
43 // ===========================================================================
44 Polygon::Polygon(const std::string& id, const std::string& type,
45  const RGBColor& color, const PositionVector& shape, bool fill,
46  SUMOReal layer, SUMOReal angle, const std::string& imgFile) :
47  Shape(id, type, color, layer, angle, imgFile),
48  myShape(shape),
49  myFill(fill)
50 {}
51 
52 
54 
55 
56 
57 /****************************************************************************/
58 
Polygon(const std::string &id, const std::string &type, const RGBColor &color, const PositionVector &shape, bool fill, SUMOReal layer=DEFAULT_LAYER, SUMOReal angle=DEFAULT_ANGLE, const std::string &imgFile=DEFAULT_IMG_FILE)
Constructor.
Definition: Polygon.cpp:44
A list of positions.
A 2D- or 3D-Shape.
Definition: Shape.h:46
#define SUMOReal
Definition: config.h:215
virtual ~Polygon()
Destructor.
Definition: Polygon.cpp:53