## OsmGpsMapPoint

OsmGpsMapPoint — A geographic location (latitude, longitude)

## Stability Level

Stable, unless otherwise indicated

## Functions

void | osm_gps_map_point_get_degrees ()
void | osm_gps_map_point_get_radians ()
gpointer | osm_gps_map_point_get_user_data ()
OsmGpsMapPoint * | osm_gps_map_point_new_degrees ()
OsmGpsMapPoint * | osm_gps_map_point_new_degrees_with_user_data ()
OsmGpsMapPoint * | osm_gps_map_point_new_radians ()
OsmGpsMapPoint * | osm_gps_map_point_new_radians_with_user_data ()
void | osm_gps_map_point_set_degrees ()
void | osm_gps_map_point_set_radians ()
void | osm_gps_map_point_set_user_data ()
OsmGpsMapPoint * | osm_gps_map_point_copy ()
void | osm_gps_map_point_free ()

## Types and Values

struct | OsmGpsMapPoint

## Object Hierarchy

        GBoxed
        ╰── OsmGpsMapPoint

## Includes

    #include <osm-gps-map.h>

## Description

OsmGpsMapPoint describes a geographic location (latitude, longitude). Helper functions exist to create such a point from either radian co-ordinates (`osm_gps_map_point_new_radians()`) or degrees (`osm_gps_map_new_degrees()`).

## Functions

### osm_gps_map_point_get_degrees ()

    void
    osm_gps_map_point_get_degrees (OsmGpsMapPoint *point,
                                   float *lat,
                                   float *lon);

Returns the lagitude and longitude in degrees.

#### Parameters

point | The point ( latitude and longitude in radian ) |
lat | latitude in degrees. | [out]
lon | longitude in degrees. | [out]

Since: 0.7.0

### osm_gps_map_point_get_radians ()

    void
    osm_gps_map_point_get_radians (OsmGpsMapPoint *point,
                                   float *rlat,
                                   float *rlon);

Returns the lagitude and longitude in radians.

#### Parameters

point | The OsmGpsMapPoint point ( latitude and longitude in radian ) |
rlat | latitude in radians. | [out]
rlon | longitude in radians. | [out]

Since: 0.7.0

### osm_gps_map_point_get_user_data ()

    gpointer
    osm_gps_map_point_get_user_data (OsmGpsMapPoint *point);

Get user data stored in point

#### Parameters

point | The OsmGpsMapPoint point |

#### Returns

The OsmGpsMapPoint user data.

[transfer none]

Since: 1.2.0

### osm_gps_map_point_new_degrees ()

    OsmGpsMapPoint *
    osm_gps_map_point_new_degrees (float lat,
                                   float lon);

Create point with specified params

#### Parameters

lat | latitude in degrees. | [in]
lon | longtitude in degrees. | [in]

#### Returns

new point object.

[transfer full]

Since: 0.7.0

### osm_gps_map_point_new_degrees_with_user_data ()

    OsmGpsMapPoint *
    osm_gps_map_point_new_degrees_with_user_data
                                   (float lat,
                                    float lon,
                                    gpointer user_data);

Create point with specified params

#### Parameters

lat | latitude in degrees. | [in]
lon | longtitude in degrees. | [in]
user_data | user data. | [in]

#### Returns

new point object.

[transfer full]

Since: 1.2.0

### osm_gps_map_point_new_radians ()

    OsmGpsMapPoint *
    osm_gps_map_point_new_radians (float rlat,
                                   float rlon);

Create point with specified params

#### Parameters

rlat | latitude in radians. | [in]
rlon | longtitude in radians. | [in]

#### Returns

new point object.

[transfer full]

Since: 0.7.0

### osm_gps_map_point_new_radians_with_user_data ()

    OsmGpsMapPoint *
    osm_gps_map_point_new_radians_with_user_data
                                   (float rlat,
                                    float rlon,
                                    gpointer user_data);

Create point with specified params

#### Parameters

rlat | latitude in radians. | [in]
rlon | longtitude in radians. | [in]
user_data | user data. | [in]

#### Returns

new point object.

[transfer full]

Since: 1.2.0

### osm_gps_map_point_set_degrees ()

    void
    osm_gps_map_point_set_degrees (OsmGpsMapPoint *point,
                                   float lat,
                                   float lon);

Sets the lagitude and longitude in degrees.

#### Parameters

point | The OsmGpsMapPoint point ( latitude and longitude in radian ) |
lat | latitude in degrees. | [in]
lon | longitude in degrees. | [in]

Since: 0.7.0

### osm_gps_map_point_set_radians ()

    void
    osm_gps_map_point_set_radians (OsmGpsMapPoint *point,
                                   float rlat,
                                   float rlon);

Sets the lagitude and longitude in radians.

#### Parameters

point | The OsmGpsMapPoint point ( latitude and longitude in radian ) |
rlat | latitude in radians. | [in]
rlon | longitude in radians. | [in]

Since: 0.7.0

### osm_gps_map_point_set_user_data ()

    void
    osm_gps_map_point_set_user_data (OsmGpsMapPoint *point,
                                     gpointer user_data);

Store user data in point

#### Parameters

point | The OsmGpsMapPoint point |
user_data | user data. | [in]

Since: 1.2.0

### osm_gps_map_point_copy ()

    OsmGpsMapPoint *
    osm_gps_map_point_copy (const OsmGpsMapPoint *point);

Create a copy of a point

#### Parameters

point | a OsmGpsMapPoint object. | [in]

#### Returns

Copied point.

[transfer full]

Since: 0.7.2

### osm_gps_map_point_free ()

    void
    osm_gps_map_point_free (OsmGpsMapPoint *point);

Free point object

#### Parameters

point | a OsmGpsMapPoint object |

Since: 0.7.2

## Types and Values

### struct OsmGpsMapPoint

    struct OsmGpsMapPoint {
        /* radians */
        float  rlat;
        float  rlon;
        gpointer user_data;
    };