ChamplainBoundingBox

ChamplainBoundingBox — A basic struct to describe a bounding box

Synopsis

struct              ChamplainBoundingBox;
ChamplainBoundingBox * champlain_bounding_box_new       (void);
ChamplainBoundingBox * champlain_bounding_box_copy      (const ChamplainBoundingBox *bbox);
void                champlain_bounding_box_free         (ChamplainBoundingBox *bbox);
void                champlain_bounding_box_get_center   (ChamplainBoundingBox *bbox,
                                                         gdouble *lat,
                                                         gdouble *lon);

Object Hierarchy

  GBoxed
   +----ChamplainBoundingBox

Description

A basic struct to describe a bounding box.

Details

struct ChamplainBoundingBox

struct ChamplainBoundingBox {
  gdouble left;
  gdouble bottom;
  gdouble right;
  gdouble top;
};

Defines the area of a ChamplainMapDataSource that contains data.

gdouble left;

left coordinate

gdouble bottom;

bottom coordinate

gdouble right;

right coordinate

gdouble top;

top coordinate

Since 0.6


champlain_bounding_box_new ()

ChamplainBoundingBox * champlain_bounding_box_new       (void);

Creates a newly allocated ChamplainBoundingBox to be freed with champlain_bounding_box_free().

Returns :

a ChamplainBoundingBox

Since 0.6


champlain_bounding_box_copy ()

ChamplainBoundingBox * champlain_bounding_box_copy      (const ChamplainBoundingBox *bbox);

Makes a copy of the bounding box structure. The result must be freed using champlain_bounding_box_free().

bbox :

a ChamplainBoundingBox

Returns :

an allocated copy of bbox.

Since 0.6


champlain_bounding_box_free ()

void                champlain_bounding_box_free         (ChamplainBoundingBox *bbox);

Frees a bounding box structure created with champlain_bounding_box_new() or champlain_bounding_box_copy().

Since 0.6


champlain_bounding_box_get_center ()

void                champlain_bounding_box_get_center   (ChamplainBoundingBox *bbox,
                                                         gdouble *lat,
                                                         gdouble *lon);

Sets the latitude and longitude of the box to lat and lon.

bbox :

a ChamplainBoundingBox

lat :

the latitude of the box center. [out]

lon :

the longitude of the box center. [out]

Since 0.6