DGtal 2.2.0
Loading...
Searching...
No Matches
3dBorderExtractionImg.cpp File Reference
#include <iostream>
#include "DGtal/base/Common.h"
#include "DGtal/io/readers/VolReader.h"
#include "DGtal/images/ImageSelector.h"
#include "DGtal/images/imagesSetsUtils/SetFromImage.h"
#include "DGtal/io/viewers/PolyscopeViewer.h"
#include "DGtal/helpers/StdDefs.h"
#include "ConfigExamples.h"
Include dependency graph for 3dBorderExtractionImg.cpp:

Go to the source code of this file.

Functions

int main ()

Detailed Description

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/.

Author
Bertrand Kerautret (kerau.nosp@m.tre@.nosp@m.loria.nosp@m..fr ) LORIA (CNRS, UMR 7503), University of Nancy, France
Date
2011/03/25

An example file named 3dBorderExtraction.

This file is part of the DGtal library.

Definition in file 3dBorderExtractionImg.cpp.

Function Documentation

◆ main()

int main ( void )

Definition at line 65 of file 3dBorderExtractionImg.cpp.

66{
67
68 std::string inputFilename = examplesPath + "samples/Al.100.vol";
69 PolyscopeViewer<> viewer;
70
75 Z3i::Object18_6 obj3d (Z3i::dt18_6, set3d);
76 Z3i::Object18_6 border = obj3d.border();
77 viewer << border;
78 viewer << ClippingPlane(0,1,0, -40);
79
80 viewer.show();
81 return 0;
82}
Aim: implements association between points lying in a digital domain and values.
Definition Image.h:70
const Domain & domain() const
Definition Image.h:192
void show() override
Starts the event loop and display of elements.
Object< DT18_6, DigitalSet > Object18_6
Definition StdDefs.h:178
DigitalSetSelector< Domain, BIG_DS+HIGH_BEL_DS >::Type DigitalSet
Definition StdDefs.h:173
ClippingPlane(double _a, double _b, double _c, double _d)
Definition Display3D.h:300
ImageContainerBySTLVector< Domain, Value > Type
static void append(Set &aSet, const ForegroundPredicate &isForeground, typename Image::Domain::ConstIterator itBegin, typename Image::Domain::ConstIterator itEnd)
static ImageContainer importVol(const std::string &filename, const Functor &aFunctor=Functor())
Image image(domain)

References DGtal::SetFromImage< TSet >::append(), DGtal::Object< TDigitalTopology, TDigitalSet >::border(), DGtal::ClippingPlane::ClippingPlane(), DGtal::Image< TImageContainer >::domain(), image(), DGtal::VolReader< TImageContainer, TFunctor >::importVol(), main(), and DGtal::PolyscopeViewer< Space, KSpace >::show().