DGtal 1.3.0
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions
DGtal::GenericWriter< TContainer, Tdim, TValue, TFunctor > Struct Template Reference

Aim: Provide a mechanism to save image (2D or 3D) into file with the best saver loader according to an filename (by parsing the extension). More...

#include <DGtal/io/writers/GenericWriter.h>

Public Member Functions

 BOOST_CONCEPT_ASSERT ((concepts::CConstImage< TContainer >))
 

Static Public Member Functions

static bool exportFile (const std::string &filename, const TContainer &anImage, const TFunctor &aFunctor=TFunctor())
 

Detailed Description

template<typename TContainer, int Tdim = TContainer::Point::dimension, typename TValue = typename TContainer::Value, typename TFunctor = functors::Identity>
struct DGtal::GenericWriter< TContainer, Tdim, TValue, TFunctor >

Aim: Provide a mechanism to save image (2D or 3D) into file with the best saver loader according to an filename (by parsing the extension).

Description of template class 'GenericWriter'

The typical use is very simple:

Examples
images/imageBasicSubsampling.cpp.

Definition at line 94 of file GenericWriter.h.

Member Function Documentation

◆ BOOST_CONCEPT_ASSERT()

template<typename TContainer , int Tdim = TContainer::Point::dimension, typename TValue = typename TContainer::Value, typename TFunctor = functors::Identity>
DGtal::GenericWriter< TContainer, Tdim, TValue, TFunctor >::BOOST_CONCEPT_ASSERT ( (concepts::CConstImage< TContainer >)  )

◆ exportFile()

template<typename TContainer , int Tdim = TContainer::Point::dimension, typename TValue = typename TContainer::Value, typename TFunctor = functors::Identity>
static bool DGtal::GenericWriter< TContainer, Tdim, TValue, TFunctor >::exportFile ( const std::string &  filename,
const TContainer &  anImage,
const TFunctor &  aFunctor = TFunctor() 
)
static

Export an image.

Parameters
filenamethe filename of the saved image (with a extension name).
anImagethe image to be saved.
aFunctorto apply image transformation before saving.

Referenced by main(), and testGenericWriter().


The documentation for this struct was generated from the following file: