|
SUMO - Simulation of Urban MObility
|
#include <config.h>#include <GL/gl.h>#include <cmath>#include <vector>#include <string>#include <foreign/polyfonts/polyfonts.h>#include <utils/common/StringUtils.h>#include <utils/common/SUMOVehicleParameter.h>#include <utils/gui/windows/GUISUMOAbstractView.h>#include <utils/gui/windows/GUIAppEnum.h>#include <utils/gui/div/GUIParameterTableWindow.h>#include <utils/gui/div/GUIGlobalSelection.h>#include <utils/gui/div/GLHelper.h>#include <utils/gui/div/GLObjectValuePassConnector.h>#include <microsim/MSVehicle.h>#include <microsim/logging/CastingFunctionBinding.h>#include <microsim/logging/FunctionBinding.h>#include <microsim/MSVehicleControl.h>#include <microsim/MSAbstractLaneChangeModel.h>#include <microsim/devices/MSDevice_Vehroutes.h>#include <gui/GUIApplicationWindow.h>#include <gui/GUIGlobals.h>#include "GUIVehicle.h"#include "GUINet.h"#include "GUIEdge.h"Go to the source code of this file.
Defines | |
| #define | BLINKER_POS_BACK .5 |
| #define | BLINKER_POS_FRONT .5 |
| #define | BRAKELIGHT_POS 1.2 |
Functions | |
| void | drawAction_drawBlinker (const GUIVehicle &veh, double dir) |
| void | drawAction_drawVehicleAsBoxPlus (const GUIVehicle &veh, SUMOReal upscale) |
| void | drawAction_drawVehicleAsPoly (const GUIVehicle &veh, SUMOReal upscale) |
| void | drawAction_drawVehicleAsTrianglePlus (const GUIVehicle &veh, SUMOReal upscale) |
| void | drawAction_drawVehicleBlinker (const GUIVehicle &veh) |
| void | drawAction_drawVehicleBrakeLight (const GUIVehicle &veh) |
| void | drawPoly (double *poses, SUMOReal offset) |
| FXDEFMAP (GUIVehicle::GUIVehiclePopupMenu) GUIVehiclePopupMenuMap[] | |
Variables | |
| double | vehiclePoly_DeliveryMediumLeftGlass [] = { 0.21,.43, 0.20,.47, 0.38,.47, 0.38,.37, 0.31,.37, 0.20,.47, -10000 } |
| double | vehiclePoly_DeliveryMediumRightGlass [] = { 0.21,-.43, 0.20,-.47, 0.38,-.47, 0.38,-.37, 0.31,-.37, 0.20,-.47, -10000 } |
| double | vehiclePoly_EVehicleBackGlass [] = { 0.65,0, 0.9,0, 0.9,0.4, 0.57,0.3, 0.57,-0.3, 0.9,-0.4, 0.9,0, -10000 } |
| double | vehiclePoly_EVehicleBody [] = { .5,0, 0,0, 0,.3, 0.08,.44, 0.25,.5, 0.75,.5, .92,.44, 1,.3, 1,-.3, .92,-.44, .75,-.5, .25,-.5, 0.08,-.44, 0,-.3, 0,0, -1000 } |
| double | vehiclePoly_EVehicleFrontGlass [] = { .5,0, 0.05,.05, 0.05,.25, 0.13,.39, 0.3,.45, 0.70,.45, .87,.39, .95,.25, .95,-.25, .87,-.39, .70,-.45, .3,-.45, 0.13,-.39, 0.05,-.25, 0.05,0.05, -1000 } |
| double | vehiclePoly_PassengerCarBody [] = { .5,0, 0,0, 0,.3, 0.08,.44, 0.25,.5, 0.95,.5, 1.,.4, 1.,-.4, 0.95,-.5, 0.25,-.5, 0.08,-.44, 0,-.3, 0,0, -10000 } |
| double | vehiclePoly_PassengerCarBodyFront [] = { 0.1,0, 0.025,0, 0.025,0.25, 0.27,0.4, 0.27,-.4, 0.025,-0.25, 0.025,0, -10000 } |
| double | vehiclePoly_PassengerFrontGlass [] = { 0.35,0, 0.3,0, 0.3,0.4, 0.43,0.3, 0.43,-0.3, 0.3,-0.4, 0.3,0, -10000 } |
| double | vehiclePoly_PassengerHatchbackBackGlass [] = { 0.92,0, 0.80,0, 0.80,0.3, 0.95,0.4, 0.95,-.4, 0.80,-.3, 0.80,0, -10000 } |
| double | vehiclePoly_PassengerHatchbackLeftGlass [] = { 0.36,.43, 0.34,.47, 0.94,.47, 0.80,.37, 0.45,.37, 0.34,.47, -10000 } |
| double | vehiclePoly_PassengerHatchbackRightGlass [] = { 0.36,-.43, 0.34,-.47, 0.94,-.47, 0.80,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
| double | vehiclePoly_PassengerSedanBackGlass [] = { 0.80,0, 0.70,0, 0.70,0.3, 0.83,0.4, 0.83,-.4, 0.70,-.3, 0.70,0, -10000 } |
| double | vehiclePoly_PassengerSedanLeftGlass [] = { 0.36,.43, 0.34,.47, 0.77,.47, 0.67,.37, 0.45,.37, 0.34,.47, -10000 } |
| double | vehiclePoly_PassengerSedanRightGlass [] = { 0.36,-.43, 0.34,-.47, 0.77,-.47, 0.67,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
| double | vehiclePoly_PassengerVanBackGlass [] = { 0.95,0, 0.94,0, 0.94,0.3, 0.98,0.4, 0.98,-.4, 0.94,-.3, 0.94,0, -10000 } |
| double | vehiclePoly_PassengerVanBody [] = { .5,0, 0,0, 0,.4, 0.1,.5, 0.97,.5, 1.,.47, 1.,-.47, 0.97,-.5, 0.1,-.5, 0,-.4, 0,0, -10000 } |
| double | vehiclePoly_PassengerVanBodyFront [] = { 0.1,0, 0.025,0, 0.025,0.25, 0.13,0.4, 0.13,-.4, 0.025,-0.25, 0.025,0, -10000 } |
| double | vehiclePoly_PassengerVanFrontGlass [] = { 0.21,0, 0.16,0, 0.16,0.4, 0.29,0.3, 0.29,-0.3, 0.16,-0.4, 0.16,0, -10000 } |
| double | vehiclePoly_PassengerVanLeftGlass [] = { 0.36,.43, 0.20,.47, 0.98,.47, 0.91,.37, 0.31,.37, 0.20,.47, -10000 } |
| double | vehiclePoly_PassengerVanRightGlass [] = { 0.36,-.43, 0.20,-.47, 0.98,-.47, 0.91,-.37, 0.31,-.37, 0.20,-.47, -10000 } |
| double | vehiclePoly_PassengerWagonBackGlass [] = { 0.92,0, 0.90,0, 0.90,0.3, 0.95,0.4, 0.95,-.4, 0.90,-.3, 0.90,0, -10000 } |
| double | vehiclePoly_PassengerWagonLeftGlass [] = { 0.36,.43, 0.34,.47, 0.94,.47, 0.87,.37, 0.45,.37, 0.34,.47, -10000 } |
| double | vehiclePoly_PassengerWagonRightGlass [] = { 0.36,-.43, 0.34,-.47, 0.94,-.47, 0.87,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
| double | vehiclePoly_TransportBody [] = { .5,0, 0,0, 0,.45, 0.05,.5, 2.25,.5, 2.25,-.5, 0.05,-.5, 0,-.45, 0,0, -10000 } |
| double | vehiclePoly_TransportFrontGlass [] = { 0.1,0, 0.05,0, 0.05,0.45, 0.25,0.4, 0.25,-.4, 0.05,-0.45, 0.05,0, -10000 } |
| double | vehiclePoly_TransportLeftGlass [] = { 0.36,.47, 0.10,.48, 1.25,.48, 1.25,.4, 0.3,.4, 0.10,.48, -10000 } |
| double | vehiclePoly_TransportRightGlass [] = { 0.36,-.47, 0.10,-.48, 1.25,-.48, 1.25,-.4, 0.3,-.4, 0.10,-.48, -10000 } |
Definition in file GUIVehicle.cpp.
| #define BLINKER_POS_BACK .5 |
Definition at line 802 of file GUIVehicle.cpp.
Referenced by drawAction_drawBlinker().
| #define BLINKER_POS_FRONT .5 |
Definition at line 801 of file GUIVehicle.cpp.
Referenced by drawAction_drawBlinker().
| #define BRAKELIGHT_POS 1.2 |
Definition at line 803 of file GUIVehicle.cpp.
Referenced by drawAction_drawVehicleBrakeLight().
| void drawAction_drawBlinker | ( | const GUIVehicle & | veh, |
| double | dir | ||
| ) | [inline] |
Definition at line 806 of file GUIVehicle.cpp.
References BLINKER_POS_BACK, BLINKER_POS_FRONT, GLHelper::drawFilledCircle(), MSVehicleType::getLengthWithGap(), MSVehicleType::getMinGap(), and MSBaseVehicle::getVehicleType().
Referenced by drawAction_drawVehicleBlinker().
| void drawAction_drawVehicleAsBoxPlus | ( | const GUIVehicle & | veh, |
| SUMOReal | upscale | ||
| ) | [inline] |
Definition at line 359 of file GUIVehicle.cpp.
References MSVehicleType::getGuiWidth(), MSVehicleType::getLengthWithGap(), MSVehicleType::getMinGap(), MSBaseVehicle::getVehicleType(), and SUMOReal.
Referenced by GUIVehicle::drawGL().
| void drawAction_drawVehicleAsPoly | ( | const GUIVehicle & | veh, |
| SUMOReal | upscale | ||
| ) | [inline] |
Definition at line 399 of file GUIVehicle.cpp.
References RGBColor::changedBrightness(), GLHelper::drawBoxLine(), GLHelper::drawFilledCircle(), drawPoly(), GLHelper::getColor(), MSVehicleType::getGuiShape(), MSVehicleType::getGuiWidth(), MSVehicleType::getLengthWithGap(), MSVehicleType::getMinGap(), MSBaseVehicle::getVehicleType(), GUIVehicle::setColor(), SUMOReal, SVS_ANT, SVS_BICYCLE, SVS_BUS, SVS_BUS_CITY, SVS_BUS_CITY_FLEXIBLE, SVS_BUS_OVERLAND, SVS_BUS_TROLLEY, SVS_DELIVERY, SVS_E_VEHICLE, SVS_MOTORCYCLE, SVS_PASSENGER, SVS_PASSENGER_HATCHBACK, SVS_PASSENGER_SEDAN, SVS_PASSENGER_VAN, SVS_PASSENGER_WAGON, SVS_PEDESTRIAN, SVS_RAIL, SVS_RAIL_CARGO, SVS_RAIL_CITY, SVS_RAIL_FAST, SVS_RAIL_LIGHT, SVS_RAIL_SLOW, SVS_TRANSPORT, SVS_TRANSPORT_1TRAILER, SVS_TRANSPORT_SEMITRAILER, SVS_UNKNOWN, and vehiclePoly_PassengerCarBody.
Referenced by GUIVehicle::drawGL().
| void drawAction_drawVehicleAsTrianglePlus | ( | const GUIVehicle & | veh, |
| SUMOReal | upscale | ||
| ) | [inline] |
Definition at line 331 of file GUIVehicle.cpp.
References MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), and SUMOReal.
Referenced by GUIVehicle::drawGL().
| void drawAction_drawVehicleBlinker | ( | const GUIVehicle & | veh | ) | [inline] |
Definition at line 820 of file GUIVehicle.cpp.
References drawAction_drawBlinker(), MSVehicleType::getGuiWidth(), MSBaseVehicle::getVehicleType(), MSVehicle::signalSet(), MSVehicle::VEH_SIGNAL_BLINKER_EMERGENCY, MSVehicle::VEH_SIGNAL_BLINKER_LEFT, and MSVehicle::VEH_SIGNAL_BLINKER_RIGHT.
Referenced by GUIVehicle::drawGL().
| void drawAction_drawVehicleBrakeLight | ( | const GUIVehicle & | veh | ) | [inline] |
Definition at line 841 of file GUIVehicle.cpp.
References BRAKELIGHT_POS, GLHelper::drawFilledCircle(), MSVehicleType::getGuiWidth(), MSVehicleType::getLengthWithGap(), MSBaseVehicle::getVehicleType(), MSVehicle::signalSet(), and MSVehicle::VEH_SIGNAL_BRAKELIGHT.
Referenced by GUIVehicle::drawGL().
| void drawPoly | ( | double * | poses, |
| SUMOReal | offset | ||
| ) |
Definition at line 383 of file GUIVehicle.cpp.
Referenced by drawAction_drawVehicleAsPoly().
| FXDEFMAP | ( | GUIVehicle::GUIVehiclePopupMenu | ) |
| double vehiclePoly_DeliveryMediumLeftGlass[] = { 0.21,.43, 0.20,.47, 0.38,.47, 0.38,.37, 0.31,.37, 0.20,.47, -10000 } |
Definition at line 112 of file GUIVehicle.cpp.
| double vehiclePoly_DeliveryMediumRightGlass[] = { 0.21,-.43, 0.20,-.47, 0.38,-.47, 0.38,-.37, 0.31,-.37, 0.20,-.47, -10000 } |
Definition at line 111 of file GUIVehicle.cpp.
| double vehiclePoly_EVehicleBackGlass[] = { 0.65,0, 0.9,0, 0.9,0.4, 0.57,0.3, 0.57,-0.3, 0.9,-0.4, 0.9,0, -10000 } |
Definition at line 122 of file GUIVehicle.cpp.
| double vehiclePoly_EVehicleBody[] = { .5,0, 0,0, 0,.3, 0.08,.44, 0.25,.5, 0.75,.5, .92,.44, 1,.3, 1,-.3, .92,-.44, .75,-.5, .25,-.5, 0.08,-.44, 0,-.3, 0,0, -1000 } |
Definition at line 119 of file GUIVehicle.cpp.
| double vehiclePoly_EVehicleFrontGlass[] = { .5,0, 0.05,.05, 0.05,.25, 0.13,.39, 0.3,.45, 0.70,.45, .87,.39, .95,.25, .95,-.25, .87,-.39, .70,-.45, .3,-.45, 0.13,-.39, 0.05,-.25, 0.05,0.05, -1000 } |
Definition at line 120 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerCarBody[] = { .5,0, 0,0, 0,.3, 0.08,.44, 0.25,.5, 0.95,.5, 1.,.4, 1.,-.4, 0.95,-.5, 0.25,-.5, 0.08,-.44, 0,-.3, 0,0, -10000 } |
Definition at line 91 of file GUIVehicle.cpp.
Referenced by drawAction_drawVehicleAsPoly().
| double vehiclePoly_PassengerCarBodyFront[] = { 0.1,0, 0.025,0, 0.025,0.25, 0.27,0.4, 0.27,-.4, 0.025,-0.25, 0.025,0, -10000 } |
Definition at line 92 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerFrontGlass[] = { 0.35,0, 0.3,0, 0.3,0.4, 0.43,0.3, 0.43,-0.3, 0.3,-0.4, 0.3,0, -10000 } |
Definition at line 93 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerHatchbackBackGlass[] = { 0.92,0, 0.80,0, 0.80,0.3, 0.95,0.4, 0.95,-.4, 0.80,-.3, 0.80,0, -10000 } |
Definition at line 99 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerHatchbackLeftGlass[] = { 0.36,.43, 0.34,.47, 0.94,.47, 0.80,.37, 0.45,.37, 0.34,.47, -10000 } |
Definition at line 98 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerHatchbackRightGlass[] = { 0.36,-.43, 0.34,-.47, 0.94,-.47, 0.80,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
Definition at line 97 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerSedanBackGlass[] = { 0.80,0, 0.70,0, 0.70,0.3, 0.83,0.4, 0.83,-.4, 0.70,-.3, 0.70,0, -10000 } |
Definition at line 96 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerSedanLeftGlass[] = { 0.36,.43, 0.34,.47, 0.77,.47, 0.67,.37, 0.45,.37, 0.34,.47, -10000 } |
Definition at line 95 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerSedanRightGlass[] = { 0.36,-.43, 0.34,-.47, 0.77,-.47, 0.67,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
Definition at line 94 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanBackGlass[] = { 0.95,0, 0.94,0, 0.94,0.3, 0.98,0.4, 0.98,-.4, 0.94,-.3, 0.94,0, -10000 } |
Definition at line 109 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanBody[] = { .5,0, 0,0, 0,.4, 0.1,.5, 0.97,.5, 1.,.47, 1.,-.47, 0.97,-.5, 0.1,-.5, 0,-.4, 0,0, -10000 } |
Definition at line 104 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanBodyFront[] = { 0.1,0, 0.025,0, 0.025,0.25, 0.13,0.4, 0.13,-.4, 0.025,-0.25, 0.025,0, -10000 } |
Definition at line 105 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanFrontGlass[] = { 0.21,0, 0.16,0, 0.16,0.4, 0.29,0.3, 0.29,-0.3, 0.16,-0.4, 0.16,0, -10000 } |
Definition at line 106 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanLeftGlass[] = { 0.36,.43, 0.20,.47, 0.98,.47, 0.91,.37, 0.31,.37, 0.20,.47, -10000 } |
Definition at line 108 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerVanRightGlass[] = { 0.36,-.43, 0.20,-.47, 0.98,-.47, 0.91,-.37, 0.31,-.37, 0.20,-.47, -10000 } |
Definition at line 107 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerWagonBackGlass[] = { 0.92,0, 0.90,0, 0.90,0.3, 0.95,0.4, 0.95,-.4, 0.90,-.3, 0.90,0, -10000 } |
Definition at line 102 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerWagonLeftGlass[] = { 0.36,.43, 0.34,.47, 0.94,.47, 0.87,.37, 0.45,.37, 0.34,.47, -10000 } |
Definition at line 101 of file GUIVehicle.cpp.
| double vehiclePoly_PassengerWagonRightGlass[] = { 0.36,-.43, 0.34,-.47, 0.94,-.47, 0.87,-.37, 0.45,-.37, 0.34,-.47, -10000 } |
Definition at line 100 of file GUIVehicle.cpp.
| double vehiclePoly_TransportBody[] = { .5,0, 0,0, 0,.45, 0.05,.5, 2.25,.5, 2.25,-.5, 0.05,-.5, 0,-.45, 0,0, -10000 } |
Definition at line 114 of file GUIVehicle.cpp.
| double vehiclePoly_TransportFrontGlass[] = { 0.1,0, 0.05,0, 0.05,0.45, 0.25,0.4, 0.25,-.4, 0.05,-0.45, 0.05,0, -10000 } |
Definition at line 115 of file GUIVehicle.cpp.
| double vehiclePoly_TransportLeftGlass[] = { 0.36,.47, 0.10,.48, 1.25,.48, 1.25,.4, 0.3,.4, 0.10,.48, -10000 } |
Definition at line 117 of file GUIVehicle.cpp.
| double vehiclePoly_TransportRightGlass[] = { 0.36,-.47, 0.10,-.48, 1.25,-.48, 1.25,-.4, 0.3,-.4, 0.10,-.48, -10000 } |
Definition at line 116 of file GUIVehicle.cpp.