DGtal
1.5.beta
|
Aim: Provide a mechanism to load with the bestloader according to an image (2D or 3D) filename (by parsing the extension). More...
#include <DGtal/io/readers/GenericReader.h>
Public Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CImage< TContainer >)) | |
Static Public Member Functions | |
static TContainer | import (const std::string &filename, std::vector< unsigned int > dimSpace=std::vector< unsigned int >()) |
template<typename TFunctor > | |
static TContainer | importWithValueFunctor (const std::string &filename, const TFunctor &aFunctor, std::vector< unsigned int > dimSpace=std::vector< unsigned int >()) |
template<typename TFunctor > | |
static TContainer | importWithColorFunctor (const std::string &filename, const TFunctor &aFunctor, std::vector< unsigned int > dimSpace=std::vector< unsigned int >()) |
Aim: Provide a mechanism to load with the bestloader according to an image (2D or 3D) filename (by parsing the extension).
Description of template class 'GenericReader'
The typical use is very simple:
TContainer | the container (mainly an ImageContainer like ImageContainerBySTLVector or ImageContainerBySTLMap). |
Tdim | the dimension of the container (by default given by the container). |
Definition at line 99 of file GenericReader.h.
DGtal::GenericReader< TContainer, Tdim, TValue >::BOOST_CONCEPT_ASSERT | ( | (concepts::CImage< TContainer >) | ) |
Referenced by DGtal::GenericReader< TContainer, Tdim, TValue >::importWithColorFunctor(), DGtal::GenericReader< TContainer, 2, TValue >::importWithColorFunctor(), DGtal::GenericReader< TContainer, 2, DGtal::uint32_t >::importWithColorFunctor(), DGtal::GenericReader< TContainer, Tdim, TValue >::importWithValueFunctor(), DGtal::GenericReader< TContainer, 2, TValue >::importWithValueFunctor(), DGtal::GenericReader< TContainer, 2, DGtal::uint32_t >::importWithValueFunctor(), DGtal::GenericReader< TContainer, 3, TValue >::importWithValueFunctor(), and DGtal::GenericReader< TContainer, 3, DGtal::uint32_t >::importWithValueFunctor().
|
static |
Import a volume nd image file. For the special format of raw image, the default parameter of the image size must be given in the optional function vector parameter (dimSpace).
filename | the image filename to imported. |
dimSpace | a vector containing the n dimensional image size. |
Referenced by get_mean_binarizer_from_an_image(), main(), DGtal::Shortcuts< TKSpace >::makeBinaryImage(), DGtal::Shortcuts< TKSpace >::makeDoubleImage(), DGtal::Shortcuts< TKSpace >::makeFloatImage(), DGtal::Shortcuts< TKSpace >::makeGrayScaleImage(), testGenericReader(), and testGenericWriter().
|
inlinestatic |
Import a volume nd image file by specifying a value functor.
TFunctor | The type of the functor (should verify the concept CUnaryFunctor<TFunctor, TValue , TContainer::Value > ) |
dimSpace | a vector containing the n dimensional image size. |
filename | the image filename to be imported. |
aFunctor | an ColorRGBEncoder. The type of the functor (should verify the concept CUnaryFunctor<TFunctor, TContainer::Value, DGtal::Color >). |
Definition at line 174 of file GenericReader.h.
References DGtal::GenericReader< TContainer, Tdim, TValue >::BOOST_CONCEPT_ASSERT(), DGtal::Trace::error(), and DGtal::trace.
|
inlinestatic |
Import a volume nd image file by specifying a value functor.
TFunctor | The type of the functor (should verify the concept CUnaryFunctor<TFunctor, TValue , TContainer::Value > ) |
dimSpace | a vector containing the n dimensional image size.. |
filename | the image filename to be imported. |
aFunctor | to transform the input type of image value (TValue) into the given image type (TContainer::Value). |
Definition at line 129 of file GenericReader.h.
References DGtal::GenericReader< TContainer, Tdim, TValue >::BOOST_CONCEPT_ASSERT(), DGtal::Trace::error(), and DGtal::trace.
Referenced by testGenericReader().