41#include "DGtal/images/ImageSelector.h"
42#include "DGtal/images/ImageContainerBySTLVector.h"
43#include "DGtal/images/ConstImageAdapter.h"
44#include "ConfigExamples.h"
45#include "DGtal/helpers/StdDefs.h"
46#include "DGtal/base/Common.h"
47#include "DGtal/io/readers/PGMReader.h"
48#include "DGtal/io/writers/GenericWriter.h"
50#include "DGtal/images/RigidTransformation2D.h"
56using namespace functors;
65 typedef ForwardRigidTransformation2D < Space > ForwardTrans;
66 typedef BackwardRigidTransformation2D < Space > BackwardTrans;
68 typedef DomainRigidTransformation2D < Domain, ForwardTrans > MyDomainTransformer;
69 typedef MyDomainTransformer::Bounds Bounds;
77 MyDomainTransformer domainTransformer ( forwardTrans );
83 Bounds bounds = domainTransformer ( image.domain() );
84 Domain transformedDomain ( bounds.first, bounds.second );
89 MyImageBackwardAdapter backwardImageAdapter ( image, transformedDomain , backwardTrans, idD );
91 backwardImageAdapter >>
"backward_transform.pgm";
95 Image forwardTransformedImage ( transformedDomain );
99 forwardTransformedImage.
setValue ( forwardTrans ( *it ), image ( *it ) );
102 forwardTransformedImage >>
"forward_transform.pgm";
Aim: implements a const image adapter with a given domain (i.e. a subdomain) and 2 functors : g for d...
Iterator for HyperRectDomain.
Aim: implements association bewteen points lying in a digital domain and values.
void setValue(const Point &aPoint, const Value &aValue)
Aim: Implements basic operations that will be used in Point and Vector classes.
void beginBlock(const std::string &keyword="")
Space::RealVector RealVector
DGtal is the top-level namespace which contains all DGtal functions and types.
static ImageContainer importPGM(const std::string &aFilename, const Functor &aFunctor=Functor(), bool topbotomOrder=true)
Aim: Define a simple default functor that just returns its argument.