31 #if defined(PPMWriter_RECURSES) 32 #error Recursive header files inclusion detected in PPMWriter.h 33 #else // defined(PPMWriter_RECURSES) 35 #define PPMWriter_RECURSES 37 #if !defined PPMWriter_h 45 #include <boost/static_assert.hpp> 46 #include <boost/type_traits.hpp> 47 #include "DGtal/base/Common.h" 48 #include "DGtal/io/Color.h" 49 #include "DGtal/base/CUnaryFunctor.h" 50 #include "DGtal/base/BasicFunctors.h" 71 template <
typename TImage,
typename TFunctor>
80 (TImage::Domain::dimension == 3));
92 static bool exportPPM(
const std::string & filename,
const Image &aImage,
93 const Functor & aFunctor =
Functor(),
bool topbottomOrder=
true);
105 static bool exportPPM3D(
const std::string & filename,
const Image &aImage,
106 const Functor & aFunctor =
Functor());
113 #include "DGtal/io/writers/PPMWriter.ih" 118 #endif // !defined PPMWriter_h 120 #undef PPMWriter_RECURSES 121 #endif // else defined(PPMWriter_RECURSES)
Aim: Export a 2D and a 3D Image using the Netpbm PPM formats (ASCII mode).
BOOST_CONCEPT_ASSERT((concepts::CUnaryFunctor< TFunctor, Value, DGtal::Color >))
Aim: Defines a unary functor, which associates arguments to results.
static bool exportPPM(const std::string &filename, const Image &aImage, const Functor &aFunctor=Functor(), bool topbottomOrder=true)
BOOST_STATIC_ASSERT((TImage::Domain::dimension==2)||(TImage::Domain::dimension==3))
DGtal is the top-level namespace which contains all DGtal functions and types.
static bool exportPPM3D(const std::string &filename, const Image &aImage, const Functor &aFunctor=Functor())