DGtal
0.9.2
|
#include <DGtal/io/readers/LongvolReader.h>
Data Structures | |
struct | HeaderField |
Public Types | |
typedef TImageContainer | ImageContainer |
typedef TImageContainer::Value | Value |
typedef TFunctor | Functor |
Public Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CUnaryFunctor< TFunctor, DGtal::uint64_t, Value >)) | |
BOOST_STATIC_ASSERT (ImageContainer::Domain::dimension==3) | |
Static Public Member Functions | |
static ImageContainer | importLongvol (const std::string &filename, const Functor &aFunctor=Functor()) throw (DGtal::IOException) |
Private Types | |
typedef unsigned char | voxel |
Static Private Member Functions | |
template<typename Word > | |
static FILE * | read_word (FILE *fin, Word &aValue) |
static const char * | getHeaderValue (const char *type, const HeaderField *header) |
static int | getHeaderValueAsInt (const char *type, int *dest, const HeaderField *header) |
static int | getHeaderField (const char *type, const HeaderField *header) |
Static Private Attributes | |
static const char * | requiredHeaders [] |
Aim: implements methods to read a "Longvol" file format (with DGtal::uint64_t value type).
Description of template class 'LongvolReader'
The main import method "importLongvol" returns an instance of the template parameter TImageContainer.
The private methods have been backported from the Simplelvol project (see http://liris.cnrs.fr/david.coeurjolly).
Example usage:
TImageContainer | the image container to use. |
TFunctor | the type of functor used in the import (by default set to functors::Cast< TImageContainer::Value>). |
Definition at line 90 of file LongvolReader.h.
typedef TFunctor DGtal::LongvolReader< TImageContainer, TFunctor >::Functor |
Definition at line 96 of file LongvolReader.h.
typedef TImageContainer DGtal::LongvolReader< TImageContainer, TFunctor >::ImageContainer |
Definition at line 94 of file LongvolReader.h.
typedef TImageContainer::Value DGtal::LongvolReader< TImageContainer, TFunctor >::Value |
Definition at line 95 of file LongvolReader.h.
|
private |
Definition at line 138 of file LongvolReader.h.
DGtal::LongvolReader< TImageContainer, TFunctor >::BOOST_CONCEPT_ASSERT | ( | (concepts::CUnaryFunctor< TFunctor, DGtal::uint64_t, Value >) | ) |
DGtal::LongvolReader< TImageContainer, TFunctor >::BOOST_STATIC_ASSERT | ( | ImageContainer::Domain::dimension | = =3 | ) |
|
staticprivate |
Internal method which returns the index of a field or -1 if not found.
|
staticprivate |
Returns NULL if this field is not found.
|
staticprivate |
Returns non-zero if failure.
|
static |
Main method to import a Longvol into an instance of the template parameter ImageContainer.
filename | the file name to import. |
aFunctor | the functor used to import and cast the source image values into the type of the image container value (by default set to functors::Cast < TImageContainer::Value > . |
Referenced by DGtal::GenericReader< TContainer, 3, TValue >::importWithValueFunctor(), and DGtal::GenericReader< TContainer, 3, DGtal::uint32_t >::importWithValueFunctor().
|
inlinestaticprivate |
Generic read word (binary mode) in little-endian mode.
fin | input FILE. |
aValue | value to write. |
Definition at line 130 of file LongvolReader.h.
|
staticprivate |
Global list of required fields in a .longvol file.
Definition at line 187 of file LongvolReader.h.