DGtal 2.0.0
|
Aim: Parallelepidec region of a digital space, model of a 'CDomain'. More...
#include <DGtal/kernel/domains/HyperRectDomain.h>
Data Structures | |
struct | ConstSubRange |
Aim: range through some subdomain of all the points in the domain. Defines a constructor taking a domain in parameter plus some additional parameters to specify the subdomain, begin and end methods returning ConstIterator, and rbegin and rend methods returning ConstReverseIterator. More... |
Public Types | |
typedef HyperRectDomain< TSpace > | Self |
typedef TSpace | Space |
typedef HyperRectDomain< Space > | Domain |
typedef Space::Point | Point |
typedef Space::Integer | Integer |
typedef Space::Vector | Vector |
typedef Space::Dimension | Dimension |
typedef Space::Size | Size |
typedef Point::Coordinate | Coordinate |
typedef HyperRectDomain_Iterator< Point > | Iterator |
Typedef of domain iterators. | |
typedef HyperRectDomain_ReverseIterator< Iterator > | ReverseIterator |
typedef Iterator | ConstIterator |
typedef ReverseIterator | ConstReverseIterator |
typedef functors::IsWithinPointPredicate< Point > | Predicate |
Public Member Functions | |
BOOST_STATIC_CONSTANT (Dimension, dimension=Space::dimension) | |
HyperRectDomain () | |
HyperRectDomain (const Point &lowerPoint, const Point &upperPoint) | |
HyperRectDomain (const typename Space::RealPoint &lowerPoint, const typename Space::RealPoint &upperPoint) | |
~HyperRectDomain () | |
HyperRectDomain (const HyperRectDomain &other) | |
HyperRectDomain & | operator= (const HyperRectDomain &other) |
const ConstIterator & | begin () const |
ConstIterator | begin (const Point &aPoint) const |
const ConstIterator & | end () const |
ConstReverseIterator | rbegin () const |
ConstReverseIterator | rbegin (const Point &aPoint) const |
ConstReverseIterator | rend () const |
ConstSubRange | subRange (const std::vector< Dimension > &permutation) const |
ConstSubRange | subRange (const std::vector< Dimension > &permutation, const Point &startingPoint) const |
ConstSubRange | subRange (Dimension adim, const Point &startingPoint) const |
ConstSubRange | subRange (Dimension adim1, Dimension adim2, const Point &startingPoint) const |
ConstSubRange | subRange (Dimension adim1, Dimension adim2, Dimension adim3, const Point &startingPoint) const |
ConstSubRange | subRange (std::initializer_list< Dimension > permutation) |
ConstSubRange | subRange (std::initializer_list< Dimension > permutation, const Point &startingPoint) |
Size | size () const |
const Point & | lowerBound () const |
const Point & | upperBound () const |
bool | isInside (const Point &p) const |
bool | isEmpty () const |
const Predicate & | predicate () const |
std::string | className () const |
void | selfDisplay (std::ostream &out) const |
bool | isValid () const |
Data Fields | |
Point | myLowerBound |
The lowest point of the space diagonal. | |
Point | myUpperBound |
The highest point of the space diagonal. |
Private Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CSpace< TSpace >)) |
Private Attributes | |
Predicate | myPredicate |
"IsInside" predicate. | |
ConstIterator | myIteratorBegin |
Begin iterator. | |
ConstIterator | myIteratorEnd |
End iterator. |
Aim: Parallelepidec region of a digital space, model of a 'CDomain'.
Description of class 'HyperRectDomain'
The following code snippet demonstrates how to use HyperRectDomain
More informations can be found in the module page about Digital Spaces, Points, Vectors and Domains .
Definition at line 99 of file HyperRectDomain.h.
typedef Iterator DGtal::HyperRectDomain< TSpace >::ConstIterator |
Definition at line 125 of file HyperRectDomain.h.
typedef ReverseIterator DGtal::HyperRectDomain< TSpace >::ConstReverseIterator |
Definition at line 126 of file HyperRectDomain.h.
typedef Point::Coordinate DGtal::HyperRectDomain< TSpace >::Coordinate |
Definition at line 118 of file HyperRectDomain.h.
typedef Space::Dimension DGtal::HyperRectDomain< TSpace >::Dimension |
Definition at line 116 of file HyperRectDomain.h.
typedef HyperRectDomain<Space> DGtal::HyperRectDomain< TSpace >::Domain |
Definition at line 112 of file HyperRectDomain.h.
typedef Space::Integer DGtal::HyperRectDomain< TSpace >::Integer |
Definition at line 114 of file HyperRectDomain.h.
typedef HyperRectDomain_Iterator<Point> DGtal::HyperRectDomain< TSpace >::Iterator |
Typedef of domain iterators.
Definition at line 123 of file HyperRectDomain.h.
typedef Space::Point DGtal::HyperRectDomain< TSpace >::Point |
Definition at line 113 of file HyperRectDomain.h.
typedef functors::IsWithinPointPredicate<Point> DGtal::HyperRectDomain< TSpace >::Predicate |
Definition at line 128 of file HyperRectDomain.h.
typedef HyperRectDomain_ReverseIterator<Iterator> DGtal::HyperRectDomain< TSpace >::ReverseIterator |
Definition at line 124 of file HyperRectDomain.h.
typedef HyperRectDomain<TSpace> DGtal::HyperRectDomain< TSpace >::Self |
Definition at line 106 of file HyperRectDomain.h.
typedef Space::Size DGtal::HyperRectDomain< TSpace >::Size |
Definition at line 117 of file HyperRectDomain.h.
typedef TSpace DGtal::HyperRectDomain< TSpace >::Space |
Definition at line 110 of file HyperRectDomain.h.
typedef Space::Vector DGtal::HyperRectDomain< TSpace >::Vector |
Definition at line 115 of file HyperRectDomain.h.
DGtal::HyperRectDomain< TSpace >::HyperRectDomain | ( | ) |
Default Constructor.
Referenced by DGtal::HyperRectDomain< TSpace >::ConstSubRange::ConstSubRange(), DGtal::HyperRectDomain< TSpace >::ConstSubRange::ConstSubRange(), DGtal::HyperRectDomain< TSpace >::ConstSubRange::ConstSubRange(), DGtal::HyperRectDomain< TSpace >::ConstSubRange::ConstSubRange(), and DGtal::HyperRectDomain< TSpace >::ConstSubRange::ConstSubRange().
DGtal::HyperRectDomain< TSpace >::HyperRectDomain | ( | const Point & | lowerPoint, |
const Point & | upperPoint ) |
Constructor from two points
lowerPoint | and |
upperPoint | defining the space diagonal. |
DGtal::HyperRectDomain< TSpace >::HyperRectDomain | ( | const typename Space::RealPoint & | lowerPoint, |
const typename Space::RealPoint & | upperPoint ) |
Constructor from two points
lowerPoint | and |
upperPoint | with real coordinates and that define the space diagonal. |
The domain actualy defined is the smallest domain with integer bounds that contains the two given points.
DGtal::HyperRectDomain< TSpace >::~HyperRectDomain | ( | ) |
Destructor.
DGtal::HyperRectDomain< TSpace >::HyperRectDomain | ( | const HyperRectDomain< TSpace > & | other | ) |
Copy constructor.
other | the object to clone. Forbidden by default. |
|
inline |
begin method.
Definition at line 176 of file HyperRectDomain.h.
Referenced by checkVoronoi(), DGtal::ImageFactoryFromImage< TImageContainer >::flushImage(), main(), DGtal::Shortcuts< Z3i::KSpace >::makeBinaryImage(), DGtal::Shortcuts< Z3i::KSpace >::makeBinaryImage(), DGtal::HyperRectDomain< Space >::rbegin(), DGtal::HyperRectDomain< Space >::rend(), DGtal::ImageFactoryFromHDF5< TImageContainer >::requestImage(), DGtal::ImageFactoryFromImage< TImageContainer >::requestImage(), TEST_CASE(), TEST_CASE(), testImage(), and testImageAdapter().
|
inline |
begin method from a given point.
aPoint | the initial point. |
Definition at line 187 of file HyperRectDomain.h.
|
private |
DGtal::HyperRectDomain< TSpace >::BOOST_STATIC_CONSTANT | ( | Dimension | , |
dimension | = Space::dimension ) |
std::string DGtal::HyperRectDomain< TSpace >::className | ( | ) | const |
|
inline |
end method.
Definition at line 201 of file HyperRectDomain.h.
Referenced by checkVoronoi(), DGtal::ImageFactoryFromImage< TImageContainer >::flushImage(), main(), DGtal::Shortcuts< Z3i::KSpace >::makeBinaryImage(), DGtal::Shortcuts< Z3i::KSpace >::makeBinaryImage(), DGtal::HyperRectDomain< Space >::rbegin(), DGtal::ImageFactoryFromHDF5< TImageContainer >::requestImage(), DGtal::ImageFactoryFromImage< TImageContainer >::requestImage(), TEST_CASE(), TEST_CASE(), testImage(), and testImageAdapter().
bool DGtal::HyperRectDomain< TSpace >::isEmpty | ( | ) | const |
Referenced by TEST_CASE().
bool DGtal::HyperRectDomain< TSpace >::isInside | ( | const Point & | p | ) | const |
p | any point. |
Referenced by DGtal::HyperRectDomain< Space >::begin(), main(), and DGtal::HyperRectDomain< Space >::rbegin().
bool DGtal::HyperRectDomain< TSpace >::isValid | ( | ) | const |
Checks the validity/consistency of the object.
Referenced by TEST_CASE().
const Point & DGtal::HyperRectDomain< TSpace >::lowerBound | ( | ) | const |
Returns the lowest point of the space diagonal.
Referenced by DGtal::ArrayImageAdapter< TArrayIterator, HyperRectDomain< TSpace > >::ArrayImageAdapter(), checkPowerMap(), Fixture_complex_diamond::create_complex_from_set(), Fixture_complex_fig4::create_complex_from_set(), Fixture_isthmus::create_complex_from_set(), Fixture_X::create_complex_from_set(), DGtal::ImageFactoryFromHDF5< TImageContainer >::flushImage(), main(), main(), randomSeeds(), TEST_CASE(), test_image(), testConsistence(), testGenericReader(), testImageOnRef(), and testITKImageWithShiftDomain().
HyperRectDomain & DGtal::HyperRectDomain< TSpace >::operator= | ( | const HyperRectDomain< TSpace > & | other | ) |
Assignment.
other | the object to copy. |
const Predicate & DGtal::HyperRectDomain< TSpace >::predicate | ( | ) | const |
NB: Could have used template class DomainPredicate but, for performance reason, directly used the IsWithinPointPredicate which fits perfectly.
|
inline |
reverse begin method.
Definition at line 210 of file HyperRectDomain.h.
Referenced by TEST_CASE().
|
inline |
reverse begin method from a given point.
aPoint | the initial point. |
Definition at line 221 of file HyperRectDomain.h.
|
inline |
reverse end method.
Definition at line 236 of file HyperRectDomain.h.
Referenced by TEST_CASE().
void DGtal::HyperRectDomain< TSpace >::selfDisplay | ( | std::ostream & | out | ) | const |
Writes/Displays the object on an output stream.
out | the output stream where the object is written. |
|
inline |
Definition at line 565 of file HyperRectDomain.h.
Referenced by TEST_CASE(), and testForwardBackwardFFT().
|
inline |
get a subRange.
permutation | a vector containing the dimensions used for the subrange. Dimensions are iterated in the given order. |
Definition at line 472 of file HyperRectDomain.h.
Referenced by DGtal::ImageFactoryFromHDF5< TImageContainer >::flushImage().
|
inline |
get a subRange from an initial point.
permutation | a vector containing the dimensions used for the subrange. Dimensions are iterated in the given order. |
startingPoint | the initial point. |
Definition at line 485 of file HyperRectDomain.h.
|
inline |
get a subRange of one dimension.
adim | the dimension of the subrange. |
startingPoint | the initial point. |
Definition at line 498 of file HyperRectDomain.h.
|
inline |
get a subRange of two dimensions.
adim1 | the first dimension of the subrange. |
adim2 | the second dimension of the subrange. |
startingPoint | the initial point. |
Definition at line 512 of file HyperRectDomain.h.
|
inline |
get a subRange of three dimensions.
adim1 | the first dimension of the subrange. |
adim2 | the second dimension of the subrange. |
adim3 | the third dimension of the subrange. |
startingPoint | the initial point. |
Definition at line 527 of file HyperRectDomain.h.
|
inline |
get a subRange.
permutation | an initializer_list containing the dimensions used for the subrange. Dimensions are iterated in the given order. |
Definition at line 539 of file HyperRectDomain.h.
|
inline |
get a subRange from an initial point.
permutation | an initializer_list containing the dimensions used for the subrange. Dimensions are iterated in the given order. |
startingPoint | the initial point. |
Definition at line 552 of file HyperRectDomain.h.
const Point & DGtal::HyperRectDomain< TSpace >::upperBound | ( | ) | const |
Returns the highest point of the space diagonal.
Referenced by DGtal::ArrayImageAdapter< TArrayIterator, HyperRectDomain< TSpace > >::ArrayImageAdapter(), checkPowerMap(), Fixture_complex_diamond::create_complex_from_set(), Fixture_complex_fig4::create_complex_from_set(), Fixture_isthmus::create_complex_from_set(), Fixture_X::create_complex_from_set(), main(), main(), randomSeeds(), TEST_CASE(), test_image(), testConsistence(), testGenericReader(), testImage(), testImageOnRef(), and testITKImageWithShiftDomain().
|
private |
Begin iterator.
Definition at line 652 of file HyperRectDomain.h.
|
private |
End iterator.
Definition at line 654 of file HyperRectDomain.h.
Point DGtal::HyperRectDomain< TSpace >::myLowerBound |
The lowest point of the space diagonal.
Definition at line 642 of file HyperRectDomain.h.
|
private |
"IsInside" predicate.
Definition at line 649 of file HyperRectDomain.h.
Point DGtal::HyperRectDomain< TSpace >::myUpperBound |
The highest point of the space diagonal.
Definition at line 644 of file HyperRectDomain.h.