Champlain.BoundingBox¶
Fields¶
Name |
Type |
Access |
Description |
|---|---|---|---|
bottom |
r/w |
bottom coordinate |
|
left |
r/w |
left coordinate |
|
right |
r/w |
right coordinate |
|
top |
r/w |
top coordinate |
Methods¶
class |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- class Champlain.BoundingBox¶
Defines the area of a ChamplainMapDataSource that contains data.
New in version 0.6.
- classmethod new()¶
- Returns:
- Return type:
Creates a newly allocated
Champlain.BoundingBoxto be freed withChamplain.BoundingBox.free().New in version 0.6.
- compose(other)¶
- Parameters:
other (
Champlain.BoundingBox) – aChamplain.BoundingBox
Sets bbox equal to the bounding box containing both self and other.
New in version 0.10.
- copy()¶
- Returns:
an allocated copy of self.
- Return type:
Makes a copy of the bounding box structure. The result must be freed using
Champlain.BoundingBox.free().New in version 0.6.
- covers(latitude, longitude)¶
- Parameters:
- Returns:
Truewhen the bounding box covers given coordinates,Falseotherwise.- Return type:
Checks whether self covers the given coordinates.
New in version 0.12.4.
- extend(latitude, longitude)¶
- Parameters:
Extend the bounding box so it contains a point with latitude and longitude. Do nothing if the point is already inside the bounding box.
New in version 0.10.
- free()¶
Frees a bounding box structure created with
Champlain.BoundingBox.new() orChamplain.BoundingBox.copy().New in version 0.6.
- get_center()¶
- Returns:
- latitude:
the latitude of the box center
- longitude:
the longitude of the box center
- Return type:
Gets the center’s latitude and longitude of the box to latitude and longitude.
New in version 0.6.