Skip to content

Class SFCGAL::Envelope

ClassList > SFCGAL > Envelope

More...

  • #include <Envelope.h>

Public Functions

Type Name
Envelope ()
Envelope (const double & xmin, const double & xmax, const double & ymin, const double & ymax)
Envelope (const double & xmin, const double & xmax, const double & ymin, const double & ymax, const double & zmin, const double & zmax)
Envelope (const Coordinate & p)
Envelope (const Coordinate & p1, const Coordinate & p2)
Envelope (const Envelope & other)
detail::Interval & boundsN (const size_t & n)
const detail::Interval & boundsN (const size_t & n) const
void expandToInclude (const Coordinate & coordinate)
bool is3D () const
bool isEmpty () const
Envelope & operator= (const Envelope & other)
std::ostream & print (std::ostream & ostr) const
CGAL::Bbox_2 toBbox_2 () const
CGAL::Bbox_3 toBbox_3 () const
std::unique_ptr< Polygon > toPolygon () const
convenience method to convert to 2D Polygon __
std::unique_ptr< LineString > toRing () const
convenience method to convert to 2D Polygon ring
std::unique_ptr< PolyhedralSurface > toShell () const
convenience method to convert to 3D Shell
std::unique_ptr< Solid > toSolid () const
convenience method to convert to 3D Solid __
const double & xMax () const
const double & xMin () const
const double & yMax () const
const double & yMin () const
const double & zMax () const
const double & zMin () const

Public Static Functions

Type Name
bool contains (const Envelope & a, const Envelope & b)
bool overlaps (const Envelope & a, const Envelope & b)

Detailed Description

Represents a bounding box

Todo

add asText instead of "print"?

add basic operations (especialy intersects/intersects3D)

Public Functions Documentation

function Envelope [1/6]

SFCGAL::Envelope::Envelope () 

default constructor (empty bounding box)


function Envelope [2/6]

SFCGAL::Envelope::Envelope (
    const double & xmin,
    const double & xmax,
    const double & ymin,
    const double & ymax
) 

2D box constructor with min,max values


function Envelope [3/6]

SFCGAL::Envelope::Envelope (
    const double & xmin,
    const double & xmax,
    const double & ymin,
    const double & ymax,
    const double & zmin,
    const double & zmax
) 

3D box constructor with min,max values


function Envelope [4/6]

SFCGAL::Envelope::Envelope (
    const Coordinate & p
) 

default constructor (empty bounding box)


function Envelope [5/6]

SFCGAL::Envelope::Envelope (
    const Coordinate & p1,
    const Coordinate & p2
) 

default constructor (empty bounding box)


function Envelope [6/6]

SFCGAL::Envelope::Envelope (
    const Envelope & other
) 

copy constructor


function boundsN [1/2]

inline detail::Interval & SFCGAL::Envelope::boundsN (
    const size_t & n
) 

returns the n-th bound


function boundsN [2/2]

inline const detail::Interval & SFCGAL::Envelope::boundsN (
    const size_t & n
) const

returns the n-th bound


function expandToInclude

void SFCGAL::Envelope::expandToInclude (
    const Coordinate & coordinate
) 

expand the box to include coordinate


function is3D

bool SFCGAL::Envelope::is3D () const

indicates if the bounding box has a 3D component


function isEmpty

bool SFCGAL::Envelope::isEmpty () const

indicates if the bounding box is empty


function operator=

Envelope & SFCGAL::Envelope::operator= (
    const Envelope & other
) 

assign operator


function print

std::ostream & SFCGAL::Envelope::print (
    std::ostream & ostr
) const

function toBbox_2

inline CGAL::Bbox_2 SFCGAL::Envelope::toBbox_2 () const

Convenience function. Convert to CGAL::BBox_2


function toBbox_3

inline CGAL::Bbox_3 SFCGAL::Envelope::toBbox_3 () const

Convenience function. Convert to CGAL::BBox_3


function toPolygon

convenience method to convert to 2D Polygon __

std::unique_ptr< Polygon > SFCGAL::Envelope::toPolygon () const

Warning:

empty Polygon for empty Envelope, may be X or Y collapsed


function toRing

convenience method to convert to 2D Polygon ring

std::unique_ptr< LineString > SFCGAL::Envelope::toRing () const

Warning:

empty LineString for empty Envelope, may be X or Y collapsed


function toShell

convenience method to convert to 3D Shell

std::unique_ptr< PolyhedralSurface > SFCGAL::Envelope::toShell () const

Warning:

empty Solid for empty or non 3D Envelope, may be X, Y or Z collapsed


function toSolid

convenience method to convert to 3D Solid __

std::unique_ptr< Solid > SFCGAL::Envelope::toSolid () const

Warning:

empty Solid for empty or non 3D Envelope, may be X, Y or Z collapsed


function xMax

inline const double & SFCGAL::Envelope::xMax () const

function xMin

inline const double & SFCGAL::Envelope::xMin () const

function yMax

inline const double & SFCGAL::Envelope::yMax () const

function yMin

inline const double & SFCGAL::Envelope::yMin () const

function zMax

inline const double & SFCGAL::Envelope::zMax () const

function zMin

inline const double & SFCGAL::Envelope::zMin () const

Public Static Functions Documentation

function contains

static bool SFCGAL::Envelope::contains (
    const Envelope & a,
    const Envelope & b
) 

Global binary operator on Envelopes. Test if A's bounding box contains B's FIXME: consider moving that outside of the class


function overlaps

static bool SFCGAL::Envelope::overlaps (
    const Envelope & a,
    const Envelope & b
) 

Global binary operator on Envelopes. Test if A's bounding box overlaps B's



The documentation for this class was generated from the following file /builds/sfcgal/SFCGAL/src/Envelope.h