DGtal
0.9.3
|
#include <iostream>
#include <map>
#include <unordered_map>
#include "DGtal/base/Common.h"
#include "DGtal/kernel/domains/HyperRectDomain.h"
#include "DGtal/topology/KhalimskySpaceND.h"
#include "DGtal/topology/KhalimskyCellHashFunctions.h"
#include "DGtal/topology/CubicalComplex.h"
#include "DGtal/topology/CubicalComplexFunctions.h"
#include "DGtalCatch.h"
Go to the source code of this file.
Typedefs | |
typedef KSpace::Point | Point |
typedef KSpace::Cell | Cell |
typedef std::unordered_map< Cell, CubicalCellData > | Map |
typedef CubicalComplex< KSpace, Map > | CC |
typedef CC::CellMapConstIterator | CellMapConstIterator |
Functions | |
srand (0) | |
K | init (Point(0, 0, 0), Point(512, 512, 512), true) |
std::vector< int > | nbCoFaces (4, 0) |
std::vector< int > | nbFaces (6, 0) |
std::vector< int > | nbFaces2 (6, 0) |
std::vector< int > | nbBdry (10, 0) |
std::vector< int > | nbBdry2 (10, 0) |
GIVEN ("A cubical complex with random 3-cells") | |
SCENARIO ("CubicalComplex< K3,std::unordered_map<> > collapse tests", "[cubical_complex][collapse]") | |
SCENARIO ("CubicalComplex< K3,std::unordered_map<> > link tests", "[cubical_complex][link]") | |
SCENARIO ("CubicalComplex< K3,std::map<> > collapse tests", "[cubical_complex][collapse]") | |
SCENARIO ("CubicalComplex< K3,std::map<> > link tests", "[cubical_complex][link]") | |
SCENARIO ("CubicalComplex< K3,std::map<> > concept check tests", "[cubical_complex][concepts]") | |
SCENARIO ("CubicalComplex< K2,std::map<> > set operations and relations", "[cubical_complex][ccops]") | |
Variables | |
static const int | NBCELLS = 1000 |
KSpace | K |
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/.
Functions for testing class CubicalComplex.
This file is part of the DGtal library.
Definition in file testCubicalComplex.cpp.
typedef CubicalComplex< KSpace, Map > CC |
Definition at line 59 of file testCubicalComplex.cpp.
typedef KSpace::Cell Cell |
Definition at line 57 of file testCubicalComplex.cpp.
Definition at line 60 of file testCubicalComplex.cpp.
typedef std::map< Cell, CubicalCellData > Map |
Definition at line 58 of file testCubicalComplex.cpp.
typedef KSpace::Point Point |
Definition at line 54 of file testCubicalComplex.cpp.
GIVEN | ( | "A cubical complex with random 3-cells" | ) |
Definition at line 71 of file testCubicalComplex.cpp.
References DGtal::CubicalComplex< TKSpace, TCellContainer >::begin(), DGtal::CubicalComplex< TKSpace, TCellContainer >::cellBoundary(), DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), DGtal::CubicalComplex< TKSpace, TCellContainer >::directCoFaces(), DGtal::CubicalComplex< TKSpace, TCellContainer >::directFaces(), DGtal::CubicalComplex< TKSpace, TCellContainer >::end(), DGtal::CubicalComplex< TKSpace, TCellContainer >::faces(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), nbBdry(), nbBdry2(), NBCELLS, DGtal::CubicalComplex< TKSpace, TCellContainer >::nbCells(), nbCoFaces(), nbFaces(), nbFaces2(), and REQUIRE().
Referenced by SCENARIO(), and TEST_CASE_METHOD().
std::vector< int > nbBdry | ( | 10 | , |
0 | |||
) |
Referenced by GIVEN(), and SCENARIO().
std::vector< int > nbBdry2 | ( | 10 | , |
0 | |||
) |
Referenced by GIVEN(), and SCENARIO().
std::vector< int > nbCoFaces | ( | 4 | , |
0 | |||
) |
Referenced by GIVEN(), and SCENARIO().
std::vector< int > nbFaces | ( | 6 | , |
0 | |||
) |
Referenced by GIVEN(), and SCENARIO().
std::vector< int > nbFaces2 | ( | 6 | , |
0 | |||
) |
Referenced by GIVEN(), and SCENARIO().
SCENARIO | ( | "CubicalComplex< K3,std::unordered_map<> > collapse tests" | , |
"" | [cubical_complex][collapse] | ||
) |
Definition at line 196 of file testCubicalComplex.cpp.
References CAPTURE(), DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), DGtal::CubicalComplex< TKSpace, TCellContainer >::end(), DGtal::CubicalComplex< TKSpace, TCellContainer >::euler(), DGtal::CubicalComplex< TKSpace, TCellContainer >::findCell(), GIVEN(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), K, DGtal::CubicalComplex< TKSpace, TCellContainer >::nbCells(), REQUIRE(), and srand().
Referenced by SCENARIO().
SCENARIO | ( | "CubicalComplex< K3,std::unordered_map<> > link tests" | , |
"" | [cubical_complex][link] | ||
) |
Definition at line 257 of file testCubicalComplex.cpp.
References DGtal::CubicalComplex< TKSpace, TCellContainer >::begin(), DGtal::CubicalComplex< TKSpace, TCellContainer >::cellBoundary(), DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), DGtal::CubicalComplex< TKSpace, TCellContainer >::directCoFaces(), DGtal::CubicalComplex< TKSpace, TCellContainer >::directFaces(), DGtal::CubicalComplex< TKSpace, TCellContainer >::end(), DGtal::CubicalComplex< TKSpace, TCellContainer >::euler(), DGtal::CubicalComplex< TKSpace, TCellContainer >::faces(), GIVEN(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insert(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), K, DGtal::CubicalComplex< TKSpace, TCellContainer >::link(), nbBdry(), nbBdry2(), NBCELLS, DGtal::CubicalComplex< TKSpace, TCellContainer >::nbCells(), nbCoFaces(), nbFaces(), nbFaces2(), REQUIRE(), SCENARIO(), and srand().
SCENARIO | ( | "CubicalComplex< K3,std::map<> > collapse tests" | , |
"" | [cubical_complex][collapse] | ||
) |
Definition at line 455 of file testCubicalComplex.cpp.
References CAPTURE(), DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), DGtal::CubicalComplex< TKSpace, TCellContainer >::end(), DGtal::CubicalComplex< TKSpace, TCellContainer >::euler(), DGtal::CubicalComplex< TKSpace, TCellContainer >::findCell(), GIVEN(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), K, DGtal::CubicalComplex< TKSpace, TCellContainer >::nbCells(), REQUIRE(), and srand().
SCENARIO | ( | "CubicalComplex< K3,std::map<> > link tests" | , |
"" | [cubical_complex][link] | ||
) |
Definition at line 516 of file testCubicalComplex.cpp.
References DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), DGtal::CubicalComplex< TKSpace, TCellContainer >::euler(), GIVEN(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insert(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), K, DGtal::CubicalComplex< TKSpace, TCellContainer >::link(), REQUIRE(), and srand().
SCENARIO | ( | "CubicalComplex< K3,std::map<> > concept check tests" | , |
"" | [cubical_complex][concepts] | ||
) |
Definition at line 564 of file testCubicalComplex.cpp.
SCENARIO | ( | "CubicalComplex< K2,std::map<> > set operations and relations" | , |
"" | [cubical_complex][ccops] | ||
) |
Definition at line 577 of file testCubicalComplex.cpp.
References DGtal::CubicalComplex< TKSpace, TCellContainer >::boundary(), CAPTURE(), DGtal::CubicalComplex< TKSpace, TCellContainer >::close(), domain(), DGtal::CubicalComplex< TKSpace, TCellContainer >::insertCell(), K, REQUIRE(), and DGtal::CubicalComplex< TKSpace, TCellContainer >::size().
srand | ( | 0 | ) |
Referenced by incTestComparison(), main(), randomSeeds(), randomTest30All(), randomTest52All(), randomTest62All(), SCENARIO(), test_get(), and test_setVal().
KSpace K |
Definition at line 63 of file testCubicalComplex.cpp.
Referenced by accuracyTest(), ballGenerator(), estimatorOnShapeDigitization(), main(), Object3D(), DGtal::functions::operator>=(), SCENARIO(), TEST_CASE(), testBallQuad(), testCombinatorialSurface(), testCompareEstimator(), testComputeInterior(), testCube(), testCurvature2d(), testDigitalSetBoundary(), testDigitalSurface(), testDigitalSurfaceBoostGraphInterface(), testDigitization(), testEmbedder(), testEstimatorCache(), testExplicitDigitalSurface(), testFindABel(), testFitting(), testGaussianCurvature3d(), DGtal::testImplicitDigitalSurface(), testImplicitDigitalSurface(), testLightExplicitDigitalSurface(), DGtal::testLightImplicitDigitalSurface(), testLightImplicitDigitalSurface(), testLocalEstimatorFromFunctorAdapter(), testMeanCurvature3d(), testObjectGraph(), testPrincipalCurvatures3d(), testRaySurface(), testTrueLocalEstimatorOnShapeDigitization(), and testUmbrellaComputer().
|
static |
Definition at line 51 of file testCubicalComplex.cpp.
Referenced by GIVEN(), and SCENARIO().