DGtal
1.5.beta
|
Computation of a distance field from a given point
More...
#include <iostream>
#include <iomanip>
#include <functional>
#include "DGtal/base/Common.h"
#include "DGtal/kernel/SpaceND.h"
#include "DGtal/kernel/domains/HyperRectDomain.h"
#include "DGtal/kernel/sets/DigitalSetFromMap.h"
#include "DGtal/images/ImageContainerBySTLMap.h"
#include "DGtal/topology/SCellsFunctors.h"
#include "DGtal/shapes/ShapeFactory.h"
#include "DGtal/shapes/Shapes.h"
#include "DGtal/helpers/StdDefs.h"
#include "DGtal/topology/helpers/Surfaces.h"
#include "DGtal/shapes/GaussDigitizer.h"
#include "DGtal/geometry/volumes/distance/FMM.h"
#include "DGtal/io/colormaps/HueShadeColorMap.h"
#include "DGtal/io/boards/Board2D.h"
Go to the source code of this file.
Functions | |
template<typename TImage > | |
void | draw (const TImage aImg, const double &aMaxValue, std::string aBasename) |
void | example () |
We use FMM to compute a distance field from a given point. More... | |
int | main (int argc, char **argv) |
Computation of a distance field from a given point
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
This file is part of the DGtal library.
Definition in file exampleFMM2D.cpp.
void draw | ( | const TImage | aImg, |
const double & | aMaxValue, | ||
std::string | aBasename | ||
) |
Function that displays an image with Board2D
aImg | an image |
aMaxValue | maximal value used in the color map |
aBasename | base name of the file |
TImage | a model of CImage |
Definition at line 89 of file exampleFMM2D.cpp.
References LibBoard::Board::setUnit(), and LibBoard::Board::UCentimeter.
Referenced by example().
void example | ( | ) |
We use FMM to compute a distance field from a given point.
[FMMSimpleTypeDef]
[FMMSimpleTypeDef]
[FMMSimpleExternalData]
[FMMSimpleExternalData]
[FMMSimpleInit]
[FMMSimpleInit]
[FMMSimpleCtor]
[FMMSimpleCtor]
[FMMSimpleComputation]
[FMMSimpleComputation]
Definition at line 124 of file exampleFMM2D.cpp.
References DGtal::Trace::beginBlock(), DGtal::FMM< TImage, TSet, TPointPredicate, TPointFunctor >::compute(), domain, draw(), DGtal::Trace::endBlock(), DGtal::Trace::info(), DGtal::FMM< TImage, TSet, TPointPredicate, TPointFunctor >::max(), DGtal::HyperRectDomain< TSpace >::predicate(), and DGtal::trace.
Referenced by main().
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 181 of file exampleFMM2D.cpp.
References DGtal::Trace::beginBlock(), DGtal::Trace::endBlock(), example(), DGtal::Trace::info(), and DGtal::trace.