#include "Grid.h"#include "../../../common/StringUtils.h"#include "../../../geometry/Envelope.h"#include "../../../geometry/MultiLineString.h"#include "../../../geometry/Utils.h"#include "../../../maptools/Utils.h"#include "../Utils.h"#include "MapDisplay.h"#include <QPainter>#include <QPixmap>#include <vector>Go to the source code of this file.
Classes | |
| class | WorldTransformer |
| This class is used to transform coordinates in world coordinate system to the screen coordinate system. More... | |
Functions | |
| std::vector< te::gm::LineString > | CalculateHorizontalLines (const te::gm::Envelope &world, const double &horizontalLineInitial, const double &horizontalLineGap, const int &maxGaps) |
| Calculates the lines in x-axis. More... | |
| std::vector< te::gm::LineString > | CalculateHorizontalLines (const te::gm::Envelope &planarBox, const te::gm::Envelope &geographicBox, const te::gm::Envelope &boxMM, const double &horizontalLineInitial, const double &horizontalLineGap, const int &maxGaps, const int &planarSRID, const int &geodesicSRID) |
| Calculates the horizontal lines of the grid. More... | |
| double | CalculateInitialX (const te::gm::Envelope &env, const double &verticalLineInitial, const double &verticalLineGap) |
| Calculates the initial coordinate in x-axis. More... | |
| double | CalculateInitialY (const te::gm::Envelope &env, const double &horizontalLineInitial, const double &horizontalLineGap) |
| Calculates the initial coordinate in y-axis. More... | |
| std::vector< te::gm::LineString > | CalculateVerticalLines (const te::gm::Envelope &planarBox, const double &verticalLineInitial, const double &verticalLineGap, const int &maxGaps) |
| Calculates the lines in y-axis. More... | |
| std::vector< te::gm::LineString > | CalculateVerticalLines (const te::gm::Envelope &planarBox, const te::gm::Envelope &geographicBox, const te::gm::Envelope &boxMM, const double &verticalLineInitial, const double &verticalLineGap, const int &maxGaps, const int &planarSRID, const int &geodesicSRID) |
| Calculates the vertical lines of the grid. More... | |
| std::string | ConvertDecimalToDegree (const double &value, bool bDegrees, bool bMinutes, bool bSeconds, int precision) |
| Converts a value to a degree-minute-second description. For presentation purposes. More... | |
| void | ConvertToMillimeter (const WorldTransformer &transf, te::gm::LineString *line) |
| Converts the line from world coordinate system to device coordinate system. More... | |
| void | DrawAllLines (WorldTransformer transf, QPainter *painter, const std::vector< te::gm::LineString > &vlines, const std::vector< te::gm::LineString > &hlines, const QFont &font) |
| Draw horizontal and vertical lines. More... | |
| void | DrawLine (QPainter *painter, QLineF &line, const int &txtOffSet, const bool &vertical) |
| Draws the line using the giving painter. More... | |
| void | DrawLines (WorldTransformer transf, QPainter *painter, const std::vector< te::gm::LineString > &lines, const int &txtOffSet, const bool &vertical) |
| Draws lines on painter. More... | |
| void | DrawTexts (WorldTransformer transf, QPainter *painter, const std::vector< te::gm::LineString > &vlines, const std::vector< te::gm::LineString > &hlines, const QFont &font) |
| Draws all texts of the lines on the grid. More... | |
| void | GetGeographicCoordLine (WorldTransformer transf, te::gm::LineString &line, const int &geoSRID) |
| Transforms a line from a coordinate system to another. More... | |
| double | GetInitialCoord (const double &initialCoord, const double &distance, double &gap) |
| Calculates a suggar initial coordinate in world coordinate system. More... | |
| void | GetTextDimensions (const QFont font, const QString &text, int &w, int &h) |
| Returns the dimensions of a text giving a font. More... | |
| QPixmap * | GetTextPixmap (const QString &txt, const QFont &font, const QPen &pen) |
| Returns a pixmap with the text. More... | |
| QPixmap * | GetTextsPixmap (WorldTransformer transf, const std::vector< te::gm::LineString > &lines, const QFont &font, const QPen &pen, const bool &vertical, const QSize &displayDimensions) |
| Returns an image with the headers of the grid. More... | |
| QPixmap * | GetTextsPixmap (WorldTransformer transf, const std::vector< te::gm::LineString > &lines, QPainter &painter, const bool &vertical, const bool &top, const int &geoSrid) |
| Returns a pixmap with the values of the coordinates to be presented. More... | |
| WorldTransformer | GetTransformGeo (te::gm::Envelope boxgeo, te::gm::Envelope boxmm) |
| Giving a box in world coordinate system and another in device coordinates, returns the WorldTransformer. More... | |
| int | PlanarSRID (const te::gm::Envelope &worldBox) |
| Giving a box in world coordinate system, calculates the better SRID we must use to transform. More... | |
| std::string | Proj4DescToGeodesic () |
| Returns a default description for a geodesic coordinate system. More... | |
| void | RemapToPlanar (te::gm::LineString *line, int sourceSRID, int planarSRID) |
| Transforms a LineString from a coordinate system to another. More... | |
| int | RoundNumber (const double &value) |
| Retuns an rounded number. If the decimal part of number is less than .5, rounds to the floor, otherwise it will be rounded up. More... | |
| void | SetSRID (std::vector< te::gm::LineString > &lines, const int &srid) |
| Sets the srid of a set of lines. More... | |
| int | ToGeographic (const te::gm::Envelope &worldBox, int sourceSRID) |
| Calculates the srid for the better geodesic coordinate system, given a bounding rectangle and it's srid. More... | |
| int | ToPlanar (const te::gm::Envelope &worldBox, int sourceSRID) |
| Calculates the srid for the better planar coordinate system, given a bounding rectangle and it's srid. More... | |
| te::common::UnitOfMeasurePtr | UnitMeasure (int srid) |
| Returns the unit of measure of the given srid. More... | |
| te::gm::Envelope | WorldBoxTo (const te::gm::Envelope &worldBox, const unsigned int &sourceSRID, const unsigned int &targetSRID) |
| Transforms the coordinates of an envelope from a system of coordinates to another. More... | |
| te::gm::Envelope | WorldBoxTo (const te::gm::Envelope &worldBox, int sourceSRID, int targetSRID) |
| Transforms a bounding rectangle from a srid into another one. More... | |
| std::vector<te::gm::LineString> CalculateHorizontalLines | ( | const te::gm::Envelope & | world, |
| const double & | horizontalLineInitial, | ||
| const double & | horizontalLineGap, | ||
| const int & | maxGaps | ||
| ) |
Calculates the lines in x-axis.
| world | Box in world coordinate system (MUST BE in a planar coordinate system). |
| horizontalLineInitial | Inital X. |
| horizontalLineGap | Distance between lines in x-axis. |
| maxGaps | Maximum number of lines to be presented on the grid. |
Definition at line 664 of file qt/widgets/canvas/Grid.cpp.
References CalculateInitialY(), te::gm::Envelope::getHeight(), te::gm::Envelope::getLowerLeftX(), te::gm::Envelope::getLowerLeftY(), te::gm::Envelope::getUpperRightX(), te::gm::Envelope::getUpperRightY(), te::gm::LineStringType, and te::gm::LineString::setPoint().
Referenced by te::qt::widgets::Grid::makeGeographicGrid(), and te::qt::widgets::Grid::makePlanarGrid().
| std::vector<te::gm::LineString> CalculateHorizontalLines | ( | const te::gm::Envelope & | planarBox, |
| const te::gm::Envelope & | geographicBox, | ||
| const te::gm::Envelope & | boxMM, | ||
| const double & | horizontalLineInitial, | ||
| const double & | horizontalLineGap, | ||
| const int & | maxGaps, | ||
| const int & | planarSRID, | ||
| const int & | geodesicSRID | ||
| ) |
Calculates the horizontal lines of the grid.
| planarBox | Bounding rectangle in planar coordinate system. |
| geographicBox | Bounding rectangle in geographic coordinates. |
| boxMM | Bounding rectangle of the device in pixel coordinate system. |
| horizontalLineInitial | Initial coordinate. |
| horizontalLineGap | Difference between the coordinates. |
| maxGaps | Maximum number of lines to be created. |
| planarSRID | Srid of a planar coordinate system. |
| geodesicSRID | Srid of a geographic coordinate system. |
Definition at line 1314 of file qt/widgets/canvas/Grid.cpp.
References CalculateInitialY(), ConvertToMillimeter(), te::mnt::CreateLine, te::gm::GeometryCollection::getGeometryN(), te::gm::GetGeomFromEnvelope(), te::gm::Envelope::getLowerLeftX(), te::gm::Envelope::getLowerLeftY(), te::gm::GeometryCollection::getNumGeometries(), te::gm::Geometry::getSRID(), GetTransformGeo(), te::gm::Envelope::getUpperRightX(), te::gm::Envelope::getUpperRightY(), te::gm::Geometry::intersection(), te::gm::Envelope::isValid(), line, te::gm::LineStringType, te::gm::MultiLineStringType, RemapToPlanar(), WorldTransformer::setMirroring(), and te::gm::LineString::setPoint().
| double CalculateInitialX | ( | const te::gm::Envelope & | env, |
| const double & | verticalLineInitial, | ||
| const double & | verticalLineGap | ||
| ) |
Calculates the initial coordinate in x-axis.
| env | Bounding rect in world coordinate system. |
| verticalLineInitial | Initial coordinate in y-axis. |
| verticalLineGap | Distance between two grid lines. |
Definition at line 564 of file qt/widgets/canvas/Grid.cpp.
References te::gm::Envelope::getLowerLeftX().
Referenced by CalculateVerticalLines().
| double CalculateInitialY | ( | const te::gm::Envelope & | env, |
| const double & | horizontalLineInitial, | ||
| const double & | horizontalLineGap | ||
| ) |
Calculates the initial coordinate in y-axis.
| env | Bounding rect in world coordinate system. |
| horizontalLineInitial | Initial coordinate in X-axis. |
| horizontalLineGap | Distance between two grid lines. |
Definition at line 592 of file qt/widgets/canvas/Grid.cpp.
References te::gm::Envelope::getLowerLeftY().
Referenced by CalculateHorizontalLines().
| std::vector<te::gm::LineString> CalculateVerticalLines | ( | const te::gm::Envelope & | planarBox, |
| const double & | verticalLineInitial, | ||
| const double & | verticalLineGap, | ||
| const int & | maxGaps | ||
| ) |
Calculates the lines in y-axis.
| planarBox | Box in world coordinate system (MUST BE in a planar coordinate system). |
| verticalLineInitial | Inital Y. |
| verticalLineGap | Distance between lines in y-axis. |
| maxGaps | Maximum number of lines to be presented on the grid. |
Definition at line 622 of file qt/widgets/canvas/Grid.cpp.
References CalculateInitialX(), te::gm::Envelope::getLowerLeftX(), te::gm::Envelope::getLowerLeftY(), te::gm::Envelope::getUpperRightX(), te::gm::Envelope::getUpperRightY(), te::gm::Envelope::getWidth(), te::gm::LineStringType, and te::gm::LineString::setPoint().
Referenced by te::qt::widgets::Grid::makeGeographicGrid(), and te::qt::widgets::Grid::makePlanarGrid().
| std::vector<te::gm::LineString> CalculateVerticalLines | ( | const te::gm::Envelope & | planarBox, |
| const te::gm::Envelope & | geographicBox, | ||
| const te::gm::Envelope & | boxMM, | ||
| const double & | verticalLineInitial, | ||
| const double & | verticalLineGap, | ||
| const int & | maxGaps, | ||
| const int & | planarSRID, | ||
| const int & | geodesicSRID | ||
| ) |
Calculates the vertical lines of the grid.
| planarBox | Bounding rectangle in planar coordinate system. |
| geographicBox | Bounding rectangle in geographic coordinates. |
| boxMM | Bounding rectangle of the device in pixel coordinate system. |
| verticalLineInitial | Initial coordinate. |
| verticalLineGap | Difference between the coordinates. |
| maxGaps | Maximum number of lines to be created. |
| planarSRID | Srid of a planar coordinate system. |
| geodesicSRID | Srid of a geographic coordinate system. |
Definition at line 1208 of file qt/widgets/canvas/Grid.cpp.
References CalculateInitialX(), ConvertToMillimeter(), te::mnt::CreateLine, te::gm::GeometryCollection::getGeometryN(), te::gm::GetGeomFromEnvelope(), te::gm::Envelope::getLowerLeftX(), te::gm::Envelope::getLowerLeftY(), te::gm::GeometryCollection::getNumGeometries(), te::gm::Geometry::getSRID(), GetTransformGeo(), te::gm::Envelope::getUpperRightX(), te::gm::Envelope::getUpperRightY(), te::gm::Geometry::intersection(), te::gm::Envelope::isValid(), line, te::gm::LineStringType, te::gm::MultiLineStringType, RemapToPlanar(), WorldTransformer::setMirroring(), and te::gm::LineString::setPoint().
| std::string ConvertDecimalToDegree | ( | const double & | value, |
| bool | bDegrees, | ||
| bool | bMinutes, | ||
| bool | bSeconds, | ||
| int | precision | ||
| ) |
Converts a value to a degree-minute-second description. For presentation purposes.
| value | Value to be converted. (MUST be in a geodesic coordinate system) |
| bDegrees | True to degrees section to be presented, false otherwise. |
| bMinutes | True to minutes section to be presented, false otherwise. |
| bSeconds | True to seconds section to be presented, false otherwise. |
| precision | Number of the decimals to be used. |
Definition at line 1577 of file qt/widgets/canvas/Grid.cpp.
References te::common::Convert2String(), and RoundNumber().
Referenced by GetTextsPixmap().
| void ConvertToMillimeter | ( | const WorldTransformer & | transf, |
| te::gm::LineString * | line | ||
| ) |
Converts the line from world coordinate system to device coordinate system.
| transf | WorldTransformer previously created with the both world rectangle and device rectangle. |
| line | The line to be converted. |
Definition at line 1162 of file qt/widgets/canvas/Grid.cpp.
References te::gm::LineString::computeMBR(), te::gm::LineString::getNPoints(), te::gm::LineString::getX(), te::gm::LineString::getY(), te::gm::LineString::setPoint(), te::gm::LineString::setSRID(), WorldTransformer::system1Tosystem2(), and TE_UNKNOWN_SRS.
Referenced by CalculateHorizontalLines(), and CalculateVerticalLines().
| void DrawAllLines | ( | WorldTransformer | transf, |
| QPainter * | painter, | ||
| const std::vector< te::gm::LineString > & | vlines, | ||
| const std::vector< te::gm::LineString > & | hlines, | ||
| const QFont & | font | ||
| ) |
Draw horizontal and vertical lines.
| transf | The world transformer being used. |
| painter | The painter being used. |
| vlines | Set of vertical lines. |
| hlines | Set of horizontal lines. |
| font | The font to be used to render the texts. |
Definition at line 868 of file qt/widgets/canvas/Grid.cpp.
References DrawLines(), and GetTextDimensions().
Referenced by te::qt::widgets::Grid::redraw().
Draws the line using the giving painter.
| painter | The painter being used for rendering. |
| line | The line to be drawed. |
| txtOffSet | Position of the text. |
| vertical | Sinalizes that the line analysed is a vertical or horizontal line. |
Definition at line 784 of file qt/widgets/canvas/Grid.cpp.
References te::qt::widgets::MillimetersToPixels().
Referenced by DrawLines().
| void DrawLines | ( | WorldTransformer | transf, |
| QPainter * | painter, | ||
| const std::vector< te::gm::LineString > & | lines, | ||
| const int & | txtOffSet, | ||
| const bool & | vertical | ||
| ) |
Draws lines on painter.
| transf | The world transformer being used. |
| painter | The painter being used. |
| lines | The set of lines to be drawed |
| txtOffSet | Position of the text. |
| vertical | Sinalizes that the lines being analysed are vertical or horizontal lines. |
Definition at line 833 of file qt/widgets/canvas/Grid.cpp.
References DrawLine(), line, and WorldTransformer::system1Tosystem2().
Referenced by DrawAllLines().
| void DrawTexts | ( | WorldTransformer | transf, |
| QPainter * | painter, | ||
| const std::vector< te::gm::LineString > & | vlines, | ||
| const std::vector< te::gm::LineString > & | hlines, | ||
| const QFont & | font | ||
| ) |
Draws all texts of the lines on the grid.
| transf | The world transformer being used. |
| painter | The painter being used. |
| vlines | Set of vertical lines. |
| hlines | Set of vertical lines. |
| font | The font being used to draw texts. |
Definition at line 1023 of file qt/widgets/canvas/Grid.cpp.
References dx, GetTextsPixmap(), and te::qt::widgets::MillimetersToPixels().
Referenced by te::qt::widgets::Grid::redraw().
| void GetGeographicCoordLine | ( | WorldTransformer | transf, |
| te::gm::LineString & | line, | ||
| const int & | geoSRID | ||
| ) |
Transforms a line from a coordinate system to another.
| transf | WorldTransformer created with a planar bounding rectangle and the device bounding rectangle. |
| line | A line in device coordinate system. |
| geoSRID | The srid of the geodesic coordinate system. |
Definition at line 1532 of file qt/widgets/canvas/Grid.cpp.
References te::gm::LineString::getNPoints(), te::gm::LineString::getPointN(), te::gm::LineString::setPointN(), WorldTransformer::system2Tosystem1(), and te::gm::LineString::transform().
Referenced by GetTextsPixmap().
| double GetInitialCoord | ( | const double & | initialCoord, |
| const double & | distance, | ||
| double & | gap | ||
| ) |
Calculates a suggar initial coordinate in world coordinate system.
| initialCoord | Initial coordinate. | |
| distance | The distance to be used. | |
| [out] | gap | The value of the distance between lines in axis. |
Definition at line 702 of file qt/widgets/canvas/Grid.cpp.
Referenced by te::qt::widgets::Grid::makeGeographicGrid(), and te::qt::widgets::Grid::makePlanarGrid().
Returns the dimensions of a text giving a font.
| font | The font being used for the texts. | |
| text | The text analysed. | |
| [out] | w | The calculated text width. |
| [out] | h | The calculated text height. |
Definition at line 765 of file qt/widgets/canvas/Grid.cpp.
Referenced by DrawAllLines(), GetTextPixmap(), and GetTextsPixmap().
| QPixmap* GetTextPixmap | ( | const QString & | txt, |
| const QFont & | font, | ||
| const QPen & | pen | ||
| ) |
Returns a pixmap with the text.
| txt | The text to be drawed. |
| font | The font to be used. |
| pen | The pen being used. |
Definition at line 891 of file qt/widgets/canvas/Grid.cpp.
References GetTextDimensions(), and p.
Referenced by GetTextsPixmap().
| QPixmap* GetTextsPixmap | ( | WorldTransformer | transf, |
| const std::vector< te::gm::LineString > & | lines, | ||
| const QFont & | font, | ||
| const QPen & | pen, | ||
| const bool & | vertical, | ||
| const QSize & | displayDimensions | ||
| ) |
Returns an image with the headers of the grid.
| transf | The world transformer being used. |
| lines | The calculated grid lines. |
| font | The font to be used. |
| pen | The pen being used. |
| vertical | Sinalizes that the lines being analysed are vertical or horizontal lines. |
| displayDimensions | Dimensions of the canvas being used. |
Definition at line 939 of file qt/widgets/canvas/Grid.cpp.
References col, GetTextDimensions(), GetTextPixmap(), p, and WorldTransformer::system1Tosystem2().
Referenced by DrawTexts(), and te::qt::widgets::Grid::redraw().
| QPixmap* GetTextsPixmap | ( | WorldTransformer | transf, |
| const std::vector< te::gm::LineString > & | lines, | ||
| QPainter & | painter, | ||
| const bool & | vertical, | ||
| const bool & | top, | ||
| const int & | geoSrid | ||
| ) |
Returns a pixmap with the values of the coordinates to be presented.
| transf | WorldTransformer object previously created. |
| lines | The lines that are being processed |
| painter | A QPainter object previously configured with the the color and font to use on presentation. |
| vertical | Flag that sinalyzes if the pixmap is for the vertical lines or horizontal. (Depends on what lines are passed) |
| top | Flag that sinalyzes in wich side will be placed the pixmap: true -> top and right, false -> bottom and left. |
| geoSrid | The srid of the geodesic coordinate system to be used. |
Definition at line 1649 of file qt/widgets/canvas/Grid.cpp.
References ConvertDecimalToDegree(), GetGeographicCoordLine(), te::gm::LineString::getNPoints(), te::gm::LineString::getPointN(), GetTextDimensions(), GetTextPixmap(), line, p, and WorldTransformer::system2Tosystem1().
| WorldTransformer GetTransformGeo | ( | te::gm::Envelope | boxgeo, |
| te::gm::Envelope | boxmm | ||
| ) |
Giving a box in world coordinate system and another in device coordinates, returns the WorldTransformer.
| boxgeo | Bounding rectangle in world coordinate system. |
| boxmm | Bounding rectangle in device coordinate system. |
Definition at line 533 of file qt/widgets/canvas/Grid.cpp.
References te::gm::Envelope::isValid(), and WorldTransformer::setTransformationParameters().
Referenced by CalculateHorizontalLines(), CalculateVerticalLines(), and te::qt::widgets::Grid::redraw().
| int PlanarSRID | ( | const te::gm::Envelope & | worldBox | ) |
Giving a box in world coordinate system, calculates the better SRID we must use to transform.
| worldBox | Box in world coordinate system. |
Definition at line 740 of file qt/widgets/canvas/Grid.cpp.
References te::map::CalculatePlanarZone(), te::gm::Envelope::getCenter(), te::gm::Coord2D::getY(), and TE_UNKNOWN_SRS.
Referenced by ToPlanar().
| std::string Proj4DescToGeodesic | ( | ) |
Returns a default description for a geodesic coordinate system.
Definition at line 1400 of file qt/widgets/canvas/Grid.cpp.
Referenced by ToGeographic().
| void RemapToPlanar | ( | te::gm::LineString * | line, |
| int | sourceSRID, | ||
| int | planarSRID | ||
| ) |
Transforms a LineString from a coordinate system to another.
| line | Line to be converted. |
| sourceSRID | Srid of the line. |
| planarSRID | Srid of the output. |
Definition at line 1104 of file qt/widgets/canvas/Grid.cpp.
References te::gm::LineString::computeMBR(), te::gm::LineString::getNPoints(), te::gm::LineString::getX(), te::gm::LineString::getY(), te::gm::LineString::makeEmpty(), te::gm::LineString::setNumCoordinates(), te::gm::LineString::setPoint(), and te::gm::LineString::setSRID().
Referenced by CalculateHorizontalLines(), and CalculateVerticalLines().
| int RoundNumber | ( | const double & | value | ) |
Retuns an rounded number. If the decimal part of number is less than .5, rounds to the floor, otherwise it will be rounded up.
| value | Value to be calculated. |
Definition at line 1554 of file qt/widgets/canvas/Grid.cpp.
Referenced by ConvertDecimalToDegree().
| void SetSRID | ( | std::vector< te::gm::LineString > & | lines, |
| const int & | srid | ||
| ) |
Sets the srid of a set of lines.
| lines | The lines to be updated. |
| srid | The new srid to be used. |
Definition at line 1746 of file qt/widgets/canvas/Grid.cpp.
Referenced by te::qt::widgets::Grid::redraw().
| int ToGeographic | ( | const te::gm::Envelope & | worldBox, |
| int | sourceSRID | ||
| ) |
Calculates the srid for the better geodesic coordinate system, given a bounding rectangle and it's srid.
| worldBox | Bounding rectangle in a planar coordinate system. |
| sourceSRID | The srid of the input bounding rectangle. |
Definition at line 1498 of file qt/widgets/canvas/Grid.cpp.
References te::common::Convert2UCase(), te::common::Singleton< SpatialReferenceSystemManager >::getInstance(), te::gm::Envelope::isValid(), Proj4DescToGeodesic(), TE_UNKNOWN_SRS, and UnitMeasure().
Referenced by te::qt::widgets::Grid::initialize().
| int ToPlanar | ( | const te::gm::Envelope & | worldBox, |
| int | sourceSRID | ||
| ) |
Calculates the srid for the better planar coordinate system, given a bounding rectangle and it's srid.
| worldBox | Bounding rectangle in a geodesic coordinate system. |
| sourceSRID | The srid of the input bounding rectangle. |
Definition at line 1470 of file qt/widgets/canvas/Grid.cpp.
References te::common::Convert2UCase(), te::gm::Envelope::isValid(), PlanarSRID(), TE_UNKNOWN_SRS, and UnitMeasure().
Referenced by te::qt::widgets::Grid::initialize(), and te::qt::widgets::Grid::makeGeographicGrid().
| te::common::UnitOfMeasurePtr UnitMeasure | ( | int | srid | ) |
Returns the unit of measure of the given srid.
| srid | Srid of interest. |
Definition at line 1419 of file qt/widgets/canvas/Grid.cpp.
References te::common::Singleton< SpatialReferenceSystemManager >::getInstance().
Referenced by ToGeographic(), and ToPlanar().
| te::gm::Envelope WorldBoxTo | ( | const te::gm::Envelope & | worldBox, |
| const unsigned int & | sourceSRID, | ||
| const unsigned int & | targetSRID | ||
| ) |
Transforms the coordinates of an envelope from a system of coordinates to another.
| worldBox | Bounding rectangle. |
| sourceSRID | Srid of the bounding rectangle. |
| targetSRID | Srid of the new bounding rectangle. |
Definition at line 1077 of file qt/widgets/canvas/Grid.cpp.
References te::common::Singleton< SpatialReferenceSystemManager >::getInstance(), te::gm::Envelope::isValid(), and te::gm::Envelope::transform().
Referenced by te::qt::widgets::Grid::makeGeographicGrid().
| te::gm::Envelope WorldBoxTo | ( | const te::gm::Envelope & | worldBox, |
| int | sourceSRID, | ||
| int | targetSRID | ||
| ) |
Transforms a bounding rectangle from a srid into another one.
| worldBox | Bounding rectangle in some coordinate system. |
| sourceSRID | The srid of the rectangle. |
| targetSRID | The srid of the output rectangle. |
Definition at line 1442 of file qt/widgets/canvas/Grid.cpp.
References te::common::Singleton< SpatialReferenceSystemManager >::getInstance(), te::gm::Envelope::isValid(), and te::gm::Envelope::transform().