2d image based on an hexagonal mesh. More...
#include <image2d_h.hh>
Public Types | |
typedef hexa_bkd_piter_< box2d > | bkd_piter |
FIXME : should it be in box2d_h? Backward Site_Iterator associated type. | |
typedef Image< void > | category |
typedef image2d< V > | delegatee |
Delegatee associated type. | |
typedef box2d_h | domain_t |
Site_Set associated type. | |
typedef hexa< image2d< V > > | exact_t |
typedef hexa_fwd_piter_< box2d > | fwd_piter |
FIXME : should it be in box2d_h? Forward Site_Iterator associated type. | |
typedef image2d< V >::lvalue | lvalue |
Lvalue associated type. | |
typedef fwd_piter | piter |
Site_Iterator associated type; default definition is fwd_piter. | |
typedef point2d_h | psite |
Point site type. | |
typedef image2d< V >::rvalue | rvalue |
Return type of read-only access. | |
typedef box2d_h::site | site |
Site associated type. | |
typedef hexa< tag::image_ < image2d< V > > > | skeleton |
Skeleton. | |
typedef mln::value::set < image2d< V >::value > | t_eligible_values_set |
Eligible-value-set associated type. | |
typedef mln::value::set < typename mln::value::super_value < image2d< V >::value >::ret > | t_values_space |
Value space associated type. | |
typedef image2d< V > | unmorph |
Unmorph image associated type. | |
typedef image2d< V >::value | value |
Value associated type. | |
Public Member Functions | |
mln::metal::const_< image2d< V > >::ret * | delegatee_ () const |
Return the delegatee_ pointer; default code. | |
image2d< V > * | delegatee_ () |
Return the delegatee_ pointer (non-const version); default code. | |
void | destroy () |
Detach data from an image (free it if nobody else hold it). | |
const box2d_h & | domain () const |
Give the definition domain. | |
bool | has (const psite &p) const |
Test if p belongs to the image domain. | |
const util::tracked_ptr < internal::data< hexa < image2d< V > > > > & | hook_data_ () const |
Hook to the image data. | |
const void * | id_ () const |
Give an identifier of this image. | |
image2d_h (int nrows, int ncols, unsigned bdr=border::thickness) | |
Constructor with the numbers of rows and columns border thickness. | |
unsigned | index_of_point (const P &p) const |
Give the offset of the site p . | |
void | init_ (image2d< V > &ima) |
Initialization. | |
bool | is_valid () const |
Test if this image has been initialized; default impl. | |
std::size_t | nsites () const |
Give the number of sites of the image domain. | |
lvalue | operator() (const typename box2d_h::psite &p) |
Read and "write if possible" access of pixel value at point site p . | |
rvalue | operator() (const point2d_h &p) const |
Read-only access of pixel value at hexa point site p . | |
lvalue | operator() (const point2d_h &p) |
Read-write access of pixel value at hexa point site p . | |
rvalue | operator() (const typename box2d_h::psite &p) const |
Read-only access of pixel value at point site p . | |
hexa< image2d< V > > & | rw () |
State that the morpher is writable. | |
image2d< V > & | unmorph_ () |
Give the morphed image (mutable version). | |
mln::metal::const_< image2d< V > >::ret & | unmorph_ () const |
Give the morphed image (const version). | |
const t_eligible_values_set & | values_eligible () const |
const t_values_space & | values_space () const |
Return the value space of the image. | |
Protected Attributes | |
util::tracked_ptr < internal::data< hexa < image2d< V > > > > | data_ |
2d image based on an hexagonal mesh.
typedef hexa_bkd_piter_<box2d> mln::hexa< image2d< V > >::bkd_piter [inherited] |
FIXME : should it be in box2d_h? Backward Site_Iterator associated type.
Reimplemented from mln::internal::image_base< image2d< V >::value, box2d_h, hexa< image2d< V > > >.
typedef Image<void> mln::Image< hexa< image2d< V > > >::category [inherited] |
Reimplemented from mln::Object< hexa< image2d< V > > >.
typedef image2d< V > mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::delegatee [inherited] |
Delegatee associated type.
typedef box2d_h mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::domain_t [inherited] |
Site_Set associated type.
typedef hexa_fwd_piter_<box2d> mln::hexa< image2d< V > >::fwd_piter [inherited] |
FIXME : should it be in box2d_h? Forward Site_Iterator associated type.
Reimplemented from mln::internal::image_base< image2d< V >::value, box2d_h, hexa< image2d< V > > >.
Lvalue associated type.
Reimplemented from mln::internal::image_domain_morpher< image2d< V >, box2d_h, hexa< image2d< V > > >.
typedef fwd_piter mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::piter [inherited] |
Site_Iterator associated type; default definition is fwd_piter.
typedef point2d_h mln::image2d_h< V >::psite |
Point site type.
Reimplemented from mln::hexa< image2d< V > >.
Return type of read-only access.
Reimplemented from mln::internal::image_domain_morpher< image2d< V >, box2d_h, hexa< image2d< V > > >.
typedef box2d_h ::site mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::site [inherited] |
Site associated type.
Skeleton.
typedef mln::value::set<image2d< V >::value > mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::t_eligible_values_set [inherited] |
Eligible-value-set associated type.
typedef mln::value::set< typename mln::value::super_value<image2d< V >::value >::ret > mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::t_values_space [inherited] |
Value space associated type.
typedef image2d< V > mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::unmorph [inherited] |
Unmorph image associated type.
Value associated type.
Reimplemented from mln::internal::image_base< image2d< V >::value, box2d_h, hexa< image2d< V > > >.
mln::image2d_h< V >::image2d_h | ( | int | nrows, | |
int | ncols, | |||
unsigned | bdr = border::thickness | |||
) | [inline] |
Constructor with the numbers of rows and columns border thickness.
image2d_h(3,6) will build this hexa image :
1 3 5 0 2 4 -------------- 0| x x x | 2| x x x | 4| x x x
References mln::hexa< image2d< V > >::init_().
mln::metal::const_< image2d< V > >::ret* mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::delegatee_ | ( | ) | const [inherited] |
Return the delegatee_ pointer; default code.
image2d< V > * mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::delegatee_ | ( | ) | [inherited] |
Return the delegatee_ pointer (non-const version); default code.
void mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::destroy | ( | ) | [inherited] |
Detach data from an image (free it if nobody else hold it).
Test if p
belongs to the image domain.
Reimplemented from mln::internal::image_base< image2d< V >::value, box2d_h, hexa< image2d< V > > >.
const util::tracked_ptr< internal::data<hexa< image2d< V > > > >& mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::hook_data_ | ( | ) | const [inherited] |
Hook to the image data.
const void* mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::id_ | ( | ) | const [inherited] |
Give an identifier of this image.
When several image variables designate the same image, they share the same identifier.
unsigned mln::internal::check::image_fastest_< hexa< image2d< V > > , mln::metal::equal< mln_trait_image_speed(hexa< image2d< V > >), trait::image::speed::fastest >::eval >::index_of_point | ( | const P & | p | ) | const [inherited] |
Give the offset of the site p
.
[in] | p | A site. |
p
. Initialization.
Referenced by mln::image2d_h< V >::image2d_h().
bool mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::is_valid | ( | ) | const [inherited] |
Test if this image has been initialized; default impl.
Reimplemented from mln::internal::image_base< image2d< V >::value, box2d_h, hexa< image2d< V > > >.
std::size_t mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::nsites | ( | ) | const [inherited] |
Give the number of sites of the image domain.
Read-only access of pixel value at hexa point site p
.
Read-write access of pixel value at hexa point site p
.
rvalue mln::internal::image_domain_morpher< image2d< V > , box2d_h , hexa< image2d< V > > >::operator() | ( | const typename box2d_h ::psite & | p | ) | const [inherited] |
Read-only access of pixel value at point site p
.
lvalue mln::internal::image_domain_morpher< image2d< V > , box2d_h , hexa< image2d< V > > >::operator() | ( | const typename box2d_h ::psite & | p | ) | [inherited] |
Read and "write if possible" access of pixel value at point site p
.
hexa< image2d< V > > & mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::rw | ( | ) | [inherited] |
State that the morpher is writable.
This allows for C++ to use it as a mutable object even if it is a temporary object.
mln::metal::const_< image2d< V > >::ret& mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::unmorph_ | ( | ) | const [inherited] |
Give the morphed image (const version).
image2d< V > & mln::internal::image_morpher< image2d< V > , image2d< V >::value , box2d_h , hexa< image2d< V > > >::unmorph_ | ( | ) | [inherited] |
Give the morphed image (mutable version).
const t_eligible_values_set& mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::values_eligible | ( | ) | const [inherited] |
const t_values_space& mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::values_space | ( | ) | const [inherited] |
Return the value space of the image.
util::tracked_ptr< internal::data<hexa< image2d< V > > > > mln::internal::image_base< image2d< V >::value , box2d_h , hexa< image2d< V > > >::data_ [protected, inherited] |