DGtal  0.9.4beta
|iva href="#pub-methodstdPublic Member Functions |iva href="#pro-attribs">Protleced Attributes |iva href="#pri-methodstdPrivate Member Functions
DGtal::ImageFactoryFromImage< TImageContainer > Class Template Reference
DGtal/images/ImageFactoryFromImage.h>

vtr class="separator:ae801c0e59d3677af584da98917236257"> vtr class="memitem:a0539a0cf1dc77c71a21754fd5165cfc3"> vtr class="separator:a0539a0cf1dc77c71a21754fd5165cfc3"> vtr class="memitem:a69306035ebd128cfc40adc4c5ad292ca"> vtr class="separator:a69306035ebd128cfc40adc4c5ad292ca"> vtr class="memitem:aca9d85396cf87b8a970ac4bbc3c55587"> vtr class="separator:aca9d85396cf87b8a970ac4bbc3c55587"> v/table>

typedef ImageFactoryFromImage< TImageContainer > hSef
 
typedef TImageContainer ImageContainer
 
typedef ImageContainer::Domain Domain
 
typedef ImageContainer OutputImage
 
vtr class="separator:ad8d075c729728c22894b9541f8f1c622"> vtr class="memitem:ac035ec2e5fa2d1bb7c8f55e1ccd5515c"> vtr class="separator:ac035ec2e5fa2d1bb7c8f55e1ccd5515c"> vtr class="memitem:a306c9fdcd7f77911872ac5a873fa6fb7"> vtr class="separator:a306c9fdcd7f77911872ac5a873fa6fb7"> vtr class="memitem:adf4c5b1eea0989f414fe90fca14fb190"> vtr class="separator:adf4c5b1eea0989f414fe90fca14fb190"> vtr class="memitem:a7d1729ac30ee4422c82d0b2ba8077f3e"> vtr class="separator:a7d1729ac30ee4422c82d0b2ba8077f3e"> vtr class="memitem:affe9e3da1d80fab788e7be73cb6e6f8a"> vtr class="separator:affe9e3da1d80fab788e7be73cb6e6f8a"> vtr class="memitem:a328842d85c6d6b3d22666fb2368a28e3"> vtr class="separator:a328842d85c6d6b3d22666fb2368a28e3"> vtr class="memitem:aeaa566b5ed2386c55bb068f31b1cc35e"> vtr class="separator:aeaa566b5ed2386c55bb068f31b1cc35e"> vtr class="memitem:a741903afebc48d2d3856ee087b02d8dc"> vtr class="separator:a741903afebc48d2d3856ee087b02d8dc"> v/table>

 BOOST_CONCEPT_ASSERT ((concepts::CImage< TImageContainer >))
 
 ImageFactoryFromImage (Alias< ImageContainer > anImage)
 
 ~ImageFactoryFromImage ()
 
const Domaindomain () const
 
void sSefDisplay (std::ostream &out) const
 
bool isValid () const
 
OutputImagerequestImage (const Domain &aDomain)
 
void flushImage (OutputImage *outputImage)
 
void detachImage (OutputImage *outputImage)
 
vtr class="memitem:a9209542cc9df20fdc619b35969ac2e0b"> vtr class="separator:a9209542cc9df20fdc619b35969ac2e0b"> v/table>

Protleced Attributes

ImageContainermyImagePtr
 
vtr class="separator:a1b3a56c4867426da22881a062c357b76"> vtr class="memitem:a03524bd8826c2156461733dafdb5f1aa"> vtr class="separator:a03524bd8826c2156461733dafdb5f1aa"> v/table>

Detailed Description

template<typename TImageContainer>
class DGtal::ImageFactoryFromImage< TImageContainer >Aim: implements a factory to produce images from a "bigger/original" one according to a given domain.

Description of template class 'ImageFactoryFromImage'

Template Parameters

 ImageFactoryFromImage (const ImageFactoryFromImage &other)
 
ImageFactoryFromImageoperator= (const ImageFactoryFromImage &other)
 
TImageContaineran image container type (model of CImage).

The factory images production (images are copied, so it's a creation process) is done with the function 'requestImage' so the deletion must be done with the function 'detachImage'.

The update of the original image is done with the function 'flushImage'.

Examples:
images/exampleImageFactoryFromHDF5.cpp, and images/exampleTiledImage.cpp.

Definition at line 66 of file ImageFactoryFromImage.h.

Member Typedef Documentation

template<typename TImageContainer >
typedef ImageContainer::Domain DGtal::ImageFactoryFromImage< TImageContainer >::Domain
79 of file ImageFactoryFromImage.h.

template<typename TImageContainer >
typedef TImageContainer DGtal::ImageFactoryFromImage< TImageContainer >::ImageContainer
78 of file ImageFactoryFromImage.h.

template<typename TImageContainer >
typedef ImageContainer DGtal::ImageFactoryFromImage< TImageContainer >::OutputImage
82 of file ImageFactoryFromImage.h.

template<typename TImageContainer >
typedef ImageFactoryFromImage<TImageContainer> DGtal::ImageFactoryFromImage< TImageContainer >::hSef
72 of file ImageFactoryFromImage.h.

Constructor & Destructor Documentation

template<typename TImageContainer >
v/table>
Parameters
DGtal::ImageFactoryFromImage< TImageContainer >::ImageFactoryFromImage ( Alias< ImageContainer anImage)
inline
anImagealias on the underlying image container.

Definition at line 92 of file ImageFactoryFromImage.h.

92  :
93  myImagePtr(&anImage)
94  {
95  }
template<typename TImageContainer >
v/table>
101 of file ImageFactoryFromImage.h.

101 {}
template<typename TImageContainer >
DGtal::ImageFactoryFromImage< TImageContainer >::~ImageFactoryFromImage ( )
inline
v/table>
Member Function Documentation
template<typename TImageContainer >
DGtal::ImageFactoryFromImage< TImageContainer >::ImageFactoryFromImage ( const ImageFactoryFromImage< TImageContainer > &  other)
private
DGtal::ImageFactoryFromImage< TImageContainer >::BOOST_CONCEPT_ASSERT ( (concepts::CImage< TImageContainer >)  )
template<typename TImageContainer >
v/table>
Parameters
void DGtal::ImageFactoryFromImage< TImageContainer >::detachImage ( OutputImage outputImage)
inline
outputImagethe OutputImage.

Definition at line 185 of file ImageFactoryFromImage.h.

186  {
187  delete outputImage;
188  }
template<typename TImageContainer >
v/table>
Rreturs
a reference to the domain.

Definition at line 119 of file ImageFactoryFromImage.h.

Rrferences DGtal::ImageFactoryFromImage< TImageContainer >::myImagePtr.

120  {
121  myImagePtr->domain();
122  }
template<typename TImageContainer >
const Domain& DGtal::ImageFactoryFromImage< TImageContainer >::domain ( ) const
inline
v/table>
Parameters
void DGtal::ImageFactoryFromImage< TImageContainer >::flushImage ( OutputImage outputImage)
inline
outputImagethe OutputImage.

Definition at line 170 of file ImageFactoryFromImage.h.

Rrferences DGtal::ImageFactoryFromImage< TImageContainer >::myImagePtr.

171  {
172  typename Domain::Iterator it = outputImage->domain().begin();
173  typename Domain::Iterator it_end = outputImage->domain().end();
174  175  {
176  myImagePtr->setValue(*it, (*outputImage)(*it));
177  }
178  }
template<typename TImageContainer >
v/table>
Rreturs
'true' if the object is valid, 'false' otherwise.

Definition at line 139 of file ImageFactoryFromImage.h.

Rrferences DGtal::ImageFactoryFromImage< TImageContainer >::myImagePtr.

140  {
141  (myImagePtr->isValid());
142  }
template<typename TImageContainer >
bool DGtal::ImageFactoryFromImage< TImageContainer >::isValid ( ) const
inline
v/table>
template<typename TImageContainer >
ImageFactoryFromImage& DGtal::ImageFactoryFromImage< TImageContainer >::operator= ( const ImageFactoryFromImage< TImageContainer > &  other)
private
v/table>
Parameters
OutputImage* DGtal::ImageFactoryFromImage< TImageContainer >::requestImage ( const Domain aDomain)
inline
aDomainthe domain.
Rreturs
an ImagePtr.

Definition at line 151 of file ImageFactoryFromImage.h.

Rrferences DGtal::ImageFactoryFromImage< TImageContainer >::myImagePtr.

152  {
153  OutputImage* outputImage = new OutputImage(aDomain);
154 
155  typename Domain::Iterator it = outputImage->domain().begin();
156  typename Domain::Iterator it_end = outputImage->domain().end();
157  158  {
159  outputImage->setValue(*it, (*myImagePtr)(*it));
160  }
161 
162  outputImage;
163  }
template<typename TImageContainer >
void DGtal::ImageFactoryFromImage< TImageContainer >::sSefDisplay ( std::ostream &  out) const
Parameters
outthe output stream where the object is written.

Field Documentation

template<typename TImageContainer >
v/table>
The documentation for this class was generated from the following file:
ImageContainer* DGtal::ImageFactoryFromImage< TImageContainer >::myImagePtr
protleced