50#include "user_colors.h"
53#include "user_colors.h"
63 if (NULL != rpn) *rpn = r;
65 if (!
RoutePointGui(m_point).IsVisibleSelectable(canvas, boverride_viz))
69 if ((abs(r.x) > canvas->GetCanvasWidth() * 4) ||
70 (abs(r.y) > canvas->GetCanvasHeight() * 4))
74 if ((abs(r.x) == INVALID_COORD) || (abs(r.y) == INVALID_COORD))
return;
77 if (m_point.m_IconName ==
"empty" && !m_point.
m_bShowName &&
91 if ((m_point.
m_bIsActive) && (m_point.m_IconName !=
"mob"))
92 pbm = pWayPointMan->GetIconBitmap(
"activepoint");
94 pbm = m_point.m_pbmIcon;
96 wxBitmap *pbms = NULL;
97 if ((g_MarkScaleFactorExp > 1.0) && !m_point.m_bPreScaled) {
98 if (m_point.m_IconScaleFactor != g_MarkScaleFactorExp) {
99 wxImage scaled_image = pbm->ConvertToImage();
100 int new_width = pbm->GetWidth() * g_MarkScaleFactorExp;
101 int new_height = pbm->GetHeight() * g_MarkScaleFactorExp;
102 m_point.m_ScaledBMP = wxBitmap(
103 scaled_image.Scale(new_width, new_height, wxIMAGE_QUALITY_HIGH));
105 m_point.m_IconScaleFactor = g_MarkScaleFactorExp;
107 if (m_point.m_ScaledBMP.IsOk()) pbm = &m_point.m_ScaledBMP;
110 int sx2 = pbm->GetWidth() / 2;
111 int sy2 = pbm->GetHeight() / 2;
114 wxRect r1(r.x - sx2, r.y - sy2, sx2 * 2, sy2 * 2);
118 wxFont *dFont = FontMgr::Get().
GetFont(_(
"Marks"));
119 int font_size = wxMax(8, dFont->GetPointSize());
123 font_size, dFont->GetFamily(), dFont->GetStyle(), dFont->GetWeight(),
124 false, dFont->GetFaceName());
127 m_point.CalculateNameExtents();
143 hilitebox.Inflate(20);
146 hilitebox.Inflate(4);
150 wxColour hi_colour = pen->GetColour();
151 unsigned char transparency = 100;
153 hi_colour = GetGlobalColor(
"YELO1");
159 AlphaBlending(dc, r.x + hilitebox.x, r.y + hilitebox.y, hilitebox.width,
160 hilitebox.height, radius, hi_colour, transparency);
163 bool bDrawHL =
false;
165 if (m_point.
m_bBlink && (g_blinker_tick & 1)) bDrawHL =
true;
167 if ((!bDrawHL) && (NULL != m_point.m_pbmIcon)) {
168 dc.DrawBitmap(*pbm, r.x - sx2, r.y - sy2,
true);
171 dc.CalcBoundingBox(r.x - sx2, r.y - sy2);
172 dc.CalcBoundingBox(r.x + sx2, r.y + sy2);
175 if (m_point.
m_bShowName && m_point.m_MarkName.Length()) {
188 double factor = 1.00;
196 ll_gc_ll(m_point.m_lat, m_point.m_lon, 0, factor, &tlat, &tlon);
200 sqrt(pow((
double)(r.x - r1.x), 2) + pow((
double)(r.y - r1.y), 2));
201 int pix_radius = (int)lpp;
204 wxBrush saveBrush = dc.GetBrush();
205 wxPen savePen = dc.GetPen();
208 wxBRUSHSTYLE_TRANSPARENT));
211 dc.StrokeCircle(r.x, r.y, i * pix_radius);
213 dc.SetBrush(saveBrush);
231 bool use_cached_screen_coords,
bool bVizOverride) {
232 if (!
RoutePointGui(m_point).IsVisibleSelectable(canvas, bVizOverride))
return;
235 if (m_point.m_IconName ==
"empty" && !m_point.
m_bShowName &&
241 vp.
rotation == m_point.m_wpBBox_rotation) {
243 LLBBox vpBBox = vp.GetBBox();
244 if (vpBBox.IntersectOut(m_point.
m_wpBBox)) {
248 double factor = 1.00;
255 LLBBox radar_box = m_point.
m_wpBBox;
256 radar_box.EnLarge(radius * 2);
257 if (vpBBox.IntersectOut(radar_box)) {
267 unsigned char transparency = 150;
274 if (r.x == INVALID_COORD)
return;
279 if ((m_point.
m_bIsActive) && (m_point.m_IconName !=
"mob"))
280 pbm = pWayPointMan->GetIconBitmap(
"activepoint");
282 pbm = m_point.m_pbmIcon;
285 if (!pbm || !pbm->IsOk())
return;
287 int sx2 = pbm->GetWidth() / 2;
288 int sy2 = pbm->GetHeight() / 2;
291 wxRect r1(r.x - sx2, r.y - sy2, sx2 * 2, sy2 * 2);
296 wxFont *dFont = FontMgr::Get().
GetFont(_(
"Marks"));
297 int font_size = wxMax(8, dFont->GetPointSize());
301 font_size, dFont->GetFamily(), dFont->GetStyle(), dFont->GetWeight(),
302 false, dFont->GetFaceName());
310 m_point.CalculateNameExtents();
325 if (!m_point.m_bPreScaled) {
326 hilitebox.x *= g_MarkScaleFactorExp;
327 hilitebox.y *= g_MarkScaleFactorExp;
328 hilitebox.width *= g_MarkScaleFactorExp;
329 hilitebox.height *= g_MarkScaleFactorExp;
334 hilitebox.Inflate(20);
337 hilitebox.Inflate(4);
344 vp.
rotation != m_point.m_wpBBox_rotation) {
345 double lat1, lon1, lat2, lon2;
347 r.y + hilitebox.y + hilitebox.height, lat1, lon1);
349 r.y + hilitebox.y, lat2, lon2);
352 m_point.
m_wpBBox.Set(lat1, lon1, lat2, lon2 + 360);
354 m_point.
m_wpBBox.Set(lat1, lon1, lat2, lon2);
357 m_point.m_wpBBox_rotation = vp.
rotation;
369 wxPen *pen =
g_pRouteMan->GetActiveRoutePointPen();
370 hi_colour = pen->GetColour();
372 hi_colour = GetGlobalColor(
"YELO1");
375 AlphaBlending(dc, r.x + hilitebox.x, r.y + hilitebox.y, hilitebox.width,
376 hilitebox.height, radius, hi_colour, transparency);
379 bool bDrawHL =
false;
381 if (m_point.
m_bBlink && (g_blinker_tick & 1)) bDrawHL =
true;
383 if ((!bDrawHL) && (NULL != m_point.m_pbmIcon)) {
385 unsigned int IconTexture =
388 glBindTexture(GL_TEXTURE_2D, IconTexture);
390 glEnable(GL_TEXTURE_2D);
393 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
394 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
396 int w = r1.width, h = r1.height;
399 if (!m_point.m_bPreScaled) {
400 scale = g_MarkScaleFactorExp;
406 float ws = r1.width *
scale;
407 float hs = r1.height *
scale;
408 float xs = r.x - ws / 2.;
409 float ys = r.y - hs / 2.;
410 float u = (float)w / glw, v = (
float)h / glh;
431 coords[6] = xs, coords[7] = ys + hs;
433 glChartCanvas::RenderSingleTexture(dc, coords, uv, &vp, 0, 0, 0);
436 glDisable(GL_TEXTURE_2D);
445 dc.SelectObject(tbm);
446 dc.SetBackground(wxBrush(*wxBLACK));
448 dc.SetFont(*m_pMarkFont);
449 dc.SetTextForeground(*wxWHITE);
450 dc.DrawText(m_MarkName, 0, 0);
451 dc.SelectObject(wxNullBitmap);
454 wxImage image = tbm.ConvertToImage();
455 unsigned char *d = image.GetData();
456 unsigned char *e =
new unsigned char[w * h];
458 for (
int p = 0; p < w * h; p++) e[p] = d[3 * p + 0];
462 glGenTextures(1, &m_iTextTexture);
463 glBindTexture(GL_TEXTURE_2D, m_iTextTexture);
465 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
466 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
468 m_iTextTextureWidth = NextPow2(w);
469 m_iTextTextureHeight = NextPow2(h);
470 glTexImage2D(GL_TEXTURE_2D, 0, GL_ALPHA, m_iTextTextureWidth,
471 m_iTextTextureHeight, 0, GL_ALPHA, GL_UNSIGNED_BYTE, NULL);
472 glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, w, h, GL_ALPHA, GL_UNSIGNED_BYTE,
482 temp_dc.SelectObject(bmp);
485 temp_dc.SetBackground(wxBrush(wxColour(0, 0, 0)));
490 temp_dc.SetTextForeground(wxColour(255, 255, 255));
491 temp_dc.DrawText(m_point.m_MarkName, 0, 0);
492 temp_dc.SelectObject(wxNullBitmap);
496 wxImage image = bmp.ConvertToImage();
498 unsigned char *data =
new unsigned char[w * h * 4];
499 unsigned char *im = image.GetData();
505 for (
int i = 0; i < h; i++) {
506 for (
int j = 0; j < w; j++) {
507 unsigned int index = ((i * w) + j) * 4;
511 data[index + 3] = im[((i * w) + j) * 3];
520 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
521 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
528 glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE,
533 glEnable(GL_TEXTURE_2D);
535 glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
544 glEnable(GL_TEXTURE_2D);
570 coords[6] = x, coords[7] = y + h;
572 glChartCanvas::RenderSingleTexture(dc, coords, uv, &vp, 0, 0, 0);
575 glDisable(GL_TEXTURE_2D);
582 double factor = 1.00;
590 ll_gc_ll(m_point.m_lat, m_point.m_lon, 0, factor, &tlat, &tlon);
594 sqrt(pow((
double)(r.x - r1.x), 2) + pow((
double)(r.y - r1.y), 2));
595 int pix_radius = (int)lpp;
597 wxColor ring_dim_color =
601 double platform_pen_width =
602 wxRound(wxMax(1.0, g_Platform->GetDisplayDPmm() / 2));
603 wxPen ppPen1(ring_dim_color, platform_pen_width);
604 wxBrush saveBrush = dc.GetBrush();
605 wxPen savePen = dc.GetPen();
607 dc.SetBrush(wxBrush(ring_dim_color, wxBRUSHSTYLE_TRANSPARENT));
610 dc.StrokeCircle(r.x, r.y, i * pix_radius);
612 dc.SetBrush(saveBrush);
616 if (m_point.m_bDrawDragHandle) {
618 double platform_pen_width = wxRound(
619 wxMax(1.0, g_Platform->GetDisplayDPmm() /
622 wxColor dh_color = GetGlobalColor(
"YELO1");
623 wxPen ppPen1(dh_color, 3 * platform_pen_width);
625 dc.DrawLine(r.x + hilitebox.width / 4, r.y + hilitebox.height / 4,
626 r.x + m_point.m_drag_line_length_man,
627 r.y + m_point.m_drag_line_length_man);
629 dh_color = wxColor(0, 0, 0);
630 wxPen ppPen2(dh_color, platform_pen_width);
632 dc.DrawLine(r.x + hilitebox.width / 4, r.y + hilitebox.height / 4,
633 r.x + m_point.m_drag_line_length_man,
634 r.y + m_point.m_drag_line_length_man);
637 glBindTexture(GL_TEXTURE_2D, m_point.m_dragIconTexture);
639 glEnable(GL_TEXTURE_2D);
642 int x = r.x + m_point.m_drag_icon_offset,
643 y = r.y + m_point.m_drag_icon_offset, w = m_point.m_dragIcon.GetWidth(),
644 h = m_point.m_dragIcon.GetHeight();
648 float ws = w *
scale;
649 float hs = h *
scale;
650 float xs = x - ws / 2.;
651 float ys = y - hs / 2.;
652 float u = (float)w / m_point.m_dragIconTextureWidth,
653 v = (
float)h / m_point.m_dragIconTextureWidth;
674 coords[6] = xs, coords[7] = ys + hs;
676 glChartCanvas::RenderSingleTexture(dc, coords, uv, &vp, 0, 0, 0);
679 glDisable(GL_TEXTURE_2D);
696void RoutePointGui::CalculateDCRect(wxDC &dc,
ChartCanvas *canvas,
699 dc.ResetBoundingBox();
700 dc.DestroyClippingRegion();
704 odc.SetVP(canvas->GetVP());
706 Draw(odc, canvas, NULL);
709 prect->x = dc.MinX() - 1;
710 prect->y = dc.MinY() - 1;
711 prect->width = dc.MaxX() - dc.MinX() + 2;
712 prect->height = dc.MaxY() - dc.MinY() + 2;
716bool RoutePointGui::IsVisibleSelectable(
ChartCanvas *cc,
bool boverrideViz) {
717 return m_point.IsVisibleSelectable(cc->GetScaleValue(), boverrideViz);
720wxPoint2DDouble RoutePointGui::GetDragHandlePoint(
ChartCanvas *canvas) {
721 if (!m_point.m_bDrawDragHandle)
722 return wxPoint2DDouble(m_point.m_lon, m_point.m_lat);
724 return computeDragHandlePoint(canvas);
727void RoutePointGui::SetPointFromDraghandlePoint(
ChartCanvas *canvas,
double lat,
733 r.y - m_point.m_drag_icon_offset, tlat, tlon);
734 m_point.m_lat = tlat;
735 m_point.m_lon = tlon;
738void RoutePointGui::SetPointFromDraghandlePoint(
ChartCanvas *canvas,
int x,
742 x - m_point.m_drag_icon_offset - m_point.m_draggingOffsetx,
743 y - m_point.m_drag_icon_offset - m_point.m_draggingOffsety, tlat, tlon);
744 m_point.m_lat = tlat;
745 m_point.m_lon = tlon;
748void RoutePointGui::PresetDragOffset(
ChartCanvas *canvas,
int x,
int y) {
752 m_point.m_draggingOffsetx = x - (r.x + m_point.m_drag_icon_offset);
753 m_point.m_draggingOffsety = y - (r.y + m_point.m_drag_icon_offset);
756wxPoint2DDouble RoutePointGui::computeDragHandlePoint(
ChartCanvas *canvas) {
761 r.y + m_point.m_drag_icon_offset, lat, lon);
764 m_point.m_dragHandleLat = lat;
765 m_point.m_dragHandleLon = lon;
767 return wxPoint2DDouble(lon, lat);
770void RoutePointGui::ShowScaleWarningMessage(
ChartCanvas *canvas) {
771 wxString strA = _(
"The ScaMin value for new waypoints is set to");
772 wxString strB = _(
"but current chartscale is");
774 _(
"Therefore the new waypoint will not be visible at this zoom level.");
776 wxString::Format(
"%s %li,\n %s %.0f.\n%s", strA, m_point.GetScaMin(),
777 strB, canvas->GetScaleValue(), strC);
778 OCPNMessageBox(canvas, MessStr);
781void RoutePointGui::EnableDragHandle(
bool bEnable) {
782 m_point.m_bDrawDragHandle = bEnable;
784 if (!m_point.m_dragIcon.IsOk()) {
787 int bm_size = g_Platform->GetDisplayDPmm() * 9;
790 wxString UserIconPath = g_Platform->GetSharedDataDir() +
"uidata" +
791 wxFileName::GetPathSeparator();
793 m_point.m_dragIcon =
LoadSVG(UserIconPath +
"DragHandle.svg", bm_size,
794 bm_size, m_point.m_pbmIcon);
799 if (m_point.m_dragIconTexture == 0) {
800 glGenTextures(1, &m_point.m_dragIconTexture);
801 glBindTexture(GL_TEXTURE_2D, m_point.m_dragIconTexture);
803 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
804 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
805 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP);
807 wxImage image = m_point.m_dragIcon.ConvertToImage();
808 int w = image.GetWidth(), h = image.GetHeight();
810 m_point.m_dragIconTextureWidth = NextPow2(w);
811 m_point.m_dragIconTextureHeight = NextPow2(h);
813 unsigned char *d = image.GetData();
814 unsigned char *a = image.GetAlpha();
816 unsigned char mr, mg, mb;
817 image.GetOrFindMaskColour(&mr, &mg, &mb);
819 unsigned char *e =
new unsigned char[4 * w * h];
821 for (
int y = 0; y < h; y++)
822 for (
int x = 0; x < w; x++) {
823 unsigned char r, g, b;
824 int off = (y * image.GetWidth() + x);
833 a ? a[off] : ((r == mr) && (g == mg) && (b == mb) ? 0 : 255);
837 glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, m_point.m_dragIconTextureWidth,
838 m_point.m_dragIconTextureHeight, 0, GL_RGBA,
839 GL_UNSIGNED_BYTE, NULL);
840 glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, w, h, GL_RGBA, GL_UNSIGNED_BYTE,
848 if (m_point.m_dragIcon.IsOk()) {
849 m_point.m_drag_line_length_man = bm_size;
850 m_point.m_drag_icon_offset = bm_size;
852 m_point.m_drag_line_length_man = 64;
853 m_point.m_drag_icon_offset = 64;
859void RoutePointGui::ReLoadIcon() {
860 if (!pWayPointMan)
return;
861 bool icon_exists = pWayPointMan->DoesIconExist(m_point.m_IconName);
863 wxString iconUse = m_point.m_IconName;
867 wxString tentative_icon = m_point.m_IconName.Lower();
868 if (pWayPointMan->DoesIconExist(tentative_icon)) {
870 m_point.m_IconName = tentative_icon;
871 iconUse = m_point.m_IconName;
876 if (!pWayPointMan->DoesIconExist(
"tempsub")) {
879 wxBitmap bmp = style->GetIcon(
"circle");
881 wxImage image = bmp.ConvertToImage();
883 .ProcessIcon(image,
"tempsub",
"tempsub");
891 m_point.m_pbmIcon = pWayPointMan->GetIconBitmap(iconUse);
892 m_point.m_bPreScaled = pWayPointMan->GetIconPrescaled(iconUse);
895 m_point.m_wpBBox_view_scale_ppm = -1;
900 m_point.m_IconScaleFactor = -1;
905bool RoutePointGui::SendToGPS(
const wxString &com_name,
SendToGpsDlg *dialog) {
907 ::wxBeginBusyCursor();
908 int result = SendWaypointToGPS_N0183(&m_point, com_name, *g_pMUX, dlg_ctx);
913 msg = _(
"Waypoint(s) Transmitted.");
917 msg = _(
"Error on Waypoint Upload. Garmin GPS not connected");
920 msg = _(
"Error on Waypoint Upload. GPS driver not available");
924 msg = _(
"Error on Waypoint Upload. Please check logfiles...");
929 OCPNMessageBox(NULL, msg, _(
"OpenCPN Info"), wxOK | wxICON_INFORMATION);
931 return (result == 0);
934int RoutePointGui::GetIconImageIndex() {
935 if (m_point.IsShared()) {
937 wxArrayPtrVoid *proute_array =
941 bool brp_viz =
false;
943 for (
unsigned int ir = 0; ir < proute_array->GetCount(); ir++) {
945 if (pr->IsVisible()) {
956 if (m_point.IsVisible())
957 return (pWayPointMan->GetIconImageListIndex(GetIconBitmap()));
964 if (m_point.IsVisible())
965 return (pWayPointMan->GetIconImageListIndex(GetIconBitmap()));
ChartCanvas - Main chart display and interaction component.
bool GetCanvasPointPix(double rlat, double rlon, wxPoint *r)
Convert latitude/longitude to canvas pixel coordinates (physical pixels) rounded to nearest integer.
void GetCanvasPixPoint(double x, double y, double &lat, double &lon)
Convert canvas pixel coordinates (physical pixels) to latitude/longitude.
wxFont * FindOrCreateFont(int point_size, wxFontFamily family, wxFontStyle style, wxFontWeight weight, bool underline=false, const wxString &facename=wxEmptyString, wxFontEncoding encoding=wxFONTENCODING_DEFAULT)
Creates or finds a matching font in the font cache.
wxColour GetFontColor(const wxString &TextElement) const
Gets the text color for a UI element.
wxFont * GetFont(const wxString &TextElement, int requested_font_size=0)
Get a font object for a UI element.
wxColour m_wxcWaypointRangeRingsColour
Color for the range rings display.
LLBBox m_wpBBox
Bounding box for the waypoint.
int m_iWaypointRangeRingsNumber
Number of range rings to display around the waypoint.
int m_NameLocationOffsetX
Horizontal offset for waypoint name placement relative to the icon.
bool m_bRPIsBeingEdited
Flag indicating if this waypoint is currently being edited.
wxRect CurrentRect_in_DC
Current rectangle occupied by the waypoint in the display.
unsigned int m_iTextTexture
Texture identifier for rendered text.
int m_NameLocationOffsetY
Vertical offset for waypoint name placement relative to the icon.
bool m_pos_on_screen
Flag indicating if the waypoint is currently visible on screen.
bool m_bIsActive
Flag indicating if this waypoint is active for navigation.
int m_iTextTextureHeight
Height of the text texture in pixels.
bool m_IconIsDirty
Flag indicating if the waypoint icon needs to be reloaded or redrawn.
wxFont * m_pMarkFont
Font used for rendering the waypoint name.
bool m_bShowName
Flag indicating if the waypoint name should be shown.
bool m_bBlink
Flag indicating if the waypoint should blink when displayed.
bool m_bPtIsSelected
Flag indicating if this waypoint is currently selected.
int m_iTextTextureWidth
Width of the text texture in pixels.
wxColour m_FontColor
Color used for rendering the waypoint name.
wxSize m_NameExtents
Size of the waypoint name text when rendered.
int m_iWaypointRangeRingsStepUnits
Units for the range rings step (0=nm, 1=km).
float m_fWaypointRangeRingsStep
Distance between consecutive range rings.
wxPoint2DDouble m_screen_pos
Cached screen position of the waypoint for drawing arrows and points.
bool m_bShowWaypointRangeRings
Flag indicating if range rings should be shown around the waypoint.
Represents a navigational route in the navigation system.
wxArrayPtrVoid * GetRouteArrayContaining(RoutePoint *pWP)
Find all routes that contain the given waypoint.
Dialog for sending routes/waypoints to a GPS device.
ViewPort - Core geographic projection and coordinate transformation engine.
double view_scale_ppm
Requested view scale in physical pixels per meter (ppm), before applying projections.
double rotation
Rotation angle of the viewport in radians.
int GetXIconImageListIndex(const wxBitmap *pbm) const
index of "X-ed out" icon in the image list
int GetFIconImageListIndex(const wxBitmap *pbm) const
index of "fixed viz" icon in the image list
Device context class that can use either wxDC or OpenGL for drawing.
Global color handling by name.
NMEA Data Multiplexer Object.
#define ERR_GPS_DRIVER_NOT_AVAILAIBLE
GPS driver not available.
#define ERR_GARMIN_SEND_MESSAGE
Failed to send message to Garmin device.
#define ERR_GARMIN_INITIALIZE
Failed to initialize Garmin device.
Extern C linked utilities.
OpenGL chart rendering canvas.
Miscellaneous globals primarely used by gui layer, not persisted in configuration file.
Multiplexer class and helpers.
Wrapper creating a N0183DlgCtx based on a SendToGpsDlg instance.
PlugIn Object Definition/API.
wxWindow * GetOCPNCanvasWindow()
Gets OpenCPN's main canvas window.
double OCPN_GetWinDIPScaleFactor()
Gets Windows-specific DPI scaling factor.
wxRect g_blink_rect
Global instance.
Purpose: Track and Trackpoint drawing stuff.
Routeman * g_pRouteMan
Global instance.
wxBitmap LoadSVG(const wxString filename, const unsigned int width, const unsigned int height, wxBitmap *default_bitmap, bool use_cache)
Load SVG file and return it's bitmap representation of requested size In case file can't be loaded an...
Geographic projection and coordinate transformations.
WaypointMan drawing stuff.