22 #ifndef STDR_MAP_LOADER 23 #define STDR_MAP_LOADER 28 #define ZOOM_RATIO 1.1 118 void drawGrid(QImage *img,
float resolution);
void updateCenter(QPoint p)
Updates the image center.
QPoint map_max_
The original image size.
QPoint map_min_
The lower right point of map visualization.
Implements the low level Qt functionalities of the map widget. Inherits from Ui_mapWidget (generated ...
void drawGrid(QImage *img, float resolution)
Draws a grid in an image.
QPoint getGlobalPoint(QPoint p)
Calculates the "real" point in the image.
int argc_
< Number of input arguments
char ** argv_
Current zoom. Calculated as pow(2,zoom_) * initial image size.
CMapLoader(int argc, char **argv)
Default contructor.
void setInitialImageSize(QSize s)
Sets the initial image size.
void updateImage(QImage *img)
Updates the image.
int zoom_
Internal image used before a map is loaded.
void updateZoom(QPoint p, bool zoomIn)
Updates the zoom of the image.
void resizeEvent(QResizeEvent *e)
Captures the resize event.
QImage * internal_img_
The upper left point of map visualization.
The main namespace for STDR GUI.
std::pair< int, int > checkDimensions(int w, int h)
Return the dimensions according to the container size.
void resetZoom(void)
Resets the zoom of the image.
void moveDirectionally(int key)
Updates the image center by moving directionally.
QSize initial_image_size_
QPoint pointUnscaled(QPoint p)
Unscales the input point.