Coords Class Reference

[Kflog Index] [Kflog Hierarchy] [Headers]


This class provides basic functions for handling the different coordinates More...

#include <coords.h>

Inherits: QObject (qt)

Public Members

Private Members


Detailed Description

This class provides basic functions for handling the different coordinates.


Coords() [public]

***************************************************************************\n ***************************************************************************\n

void setProjection(const char* procType) [public]

set the type of projection either to "Lambert" or to "Mercator"

bool isLambert() [public]

returns TRUE, if current projectiontype ist Lambert

bool isMercator() [public]

returns TRUE, if current projectiontype ist Mercator

long degreeToNum(const char* degree) [public]

Converts the longitute or latitute into the internal format suitable for the Location-class. "degree" is a string in the format: [g]gg.mm'ss"X where g,m,s are any digits from 0 to 9 and X is one of N, S, E, W

double numToRad(long internal) [public]

Convert internal representation to radians.

long calc_X_Y() [public]

Calculates the coordinates for drawing.

double calc_X_Lambert(double latitude, double longitude) [public]

Returns the x-coordinate for the Lambert-projection

double calc_Y_Lambert(double latitude, double longitude) [public]

Returns the y-coordinate for the Lambert-projection

double calc_X_Mercator(double latitude, double longitude) [public]

Returns the x-coordinates for the Mercator-projection.

double calc_Y_Mercator(double latitude, double longitude) [public]

Returns the y-coordinates for the Mercator-projection.

Note: We return negative values, because the the point (0/0) is the upper left corner of the painter. Therefore we must mirror the coordinates.

double deg(double rad) [public]

Converts radians to degree.

double rad(double deg) [public]

Converts degree to radians.

void pointList(QPainter* painter) [public]

Returns the pointlist

double mercatorScale[private]

The earth's radius used for calculation.

double v1[private]

standard parallels for conical projection

double v2[private]

The second standard parallel. It doesn't matter which one is which.

char* projectionType[private]

contains the current projectiontype


  • Author: Heiner Lamprecht
  • Documentation generated by heiner@Tharbad on Mon Jul 5 21:28:49 CEST 1999
Kdoc