31 #if defined(CubicalComplexFunctions_RECURSES) 32 #error Recursive header files inclusion detected in CubicalComplexFunctions.h 33 #else // defined(CubicalComplexFunctions_RECURSES) 35 #define CubicalComplexFunctions_RECURSES 37 #if !defined CubicalComplexFunctions_h 39 #define CubicalComplexFunctions_h 44 #include "DGtal/base/Common.h" 45 #include "DGtal/topology/CubicalComplex.h" 46 #include <DGtal/topology/helpers/NeighborhoodConfigurationsHelper.h> 61 template <
typename TKSpace,
typename TCellContainer>
62 inline CubicalComplex< TKSpace, TCellContainer >
78 template <
typename TKSpace,
typename TCellContainer>
97 template <
typename TKSpace,
typename TCellContainer>
118 template <
typename TKSpace,
typename TCellContainer>
139 template <
typename TKSpace,
typename TCellContainer>
160 template <
typename TKSpace,
typename TCellContainer>
180 template <
typename TKSpace,
typename TCellContainer>
201 template <
typename TKSpace,
typename TCellContainer>
222 template <
typename TKSpace,
typename TCellContainer>
245 template <
typename TKSpace,
typename TCellContainer>
266 template <
typename TKSpace,
typename TCellContainer>
293 template <
typename TKSpace,
typename TCellContainer>
317 template <
typename TKSpace,
typename TCellContainer>
319 operator<=( const CubicalComplex< TKSpace, TCellContainer >& S1,
323 ASSERT( &(S1.space()) == &(S2.space()) );
325 if ( !
isSubset( S1.myCells[ i ], S2.myCells[ i ] ) )
340 template <
typename TKSpace,
typename TCellContainer>
392 template <
typename TKSpace,
typename TCellContainer,
393 typename CellConstIterator,
394 typename CellMapIteratorPriority >
396 CellConstIterator S_itB, CellConstIterator S_itE,
397 const CellMapIteratorPriority& priority,
398 bool hintIsSClosed =
false,
bool hintIsKClosed =
false,
399 bool verbose =
false );
431 template <
typename TKSpace,
typename TCellContainer,
432 typename BdryCellOutputIterator,
433 typename InnerCellOutputIterator>
438 BdryCellOutputIterator itBdry,
439 InnerCellOutputIterator itInner );
457 template <
typename TObject,
typename TKSpace,
typename TCellContainer>
458 std::unique_ptr<TObject>
482 template<
typename TComplex>
485 const TComplex & input_complex,
487 const std::unordered_map<
496 #include "DGtal/topology/CubicalComplexFunctions.ih" 501 #endif // !defined CubicalComplexFunctions_h 503 #undef CubicalComplexFunctions_RECURSES 504 #endif // else defined(CubicalComplexFunctions_RECURSES) bool operator==(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
CubicalComplex< TKSpace, TCellContainer > & operator &=(CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
CubicalComplex< TKSpace, TCellContainer > operator*(const CubicalComplex< TKSpace, TCellContainer > &)
uint64_t collapse(CubicalComplex< TKSpace, TCellContainer > &K, CellConstIterator S_itB, CellConstIterator S_itE, const CellMapIteratorPriority &priority, bool hintIsSClosed=false, bool hintIsKClosed=false, bool verbose=false)
DGtal::uint32_t Dimension
CubicalComplex< TKSpace, TCellContainer > & operator-=(CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
CubicalComplex< TKSpace, TCellContainer > operator~(const CubicalComplex< TKSpace, TCellContainer > &)
uint32_t NeighborhoodConfiguration
bool operator!=(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
bool operator>=(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
NeighborhoodConfiguration getSpelNeighborhoodConfigurationOccupancy(const TComplex &input_complex, const typename TComplex::Point ¢er, const std::unordered_map< typename TComplex::Point, NeighborhoodConfiguration > &mapPointToMask)
CubicalComplex< TKSpace, TCellContainer > operator^(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
std::unique_ptr< TObject > objectFromSpels(const CubicalComplex< TKSpace, TCellContainer > &C)
CubicalComplex< TKSpace, TCellContainer > & operator^=(CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
const KSpace & space() const
CubicalComplex< TKSpace, TCellContainer > operator|(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
Aim: This class represents an arbitrary cubical complex living in some Khalimsky space. Cubical complexes are sets of cells of different dimensions related together with incidence relations. Two cells in a cubical complex are incident if and only if they are incident in the surrounding Khalimsky space. In other words, cubical complexes are defined here as subsets of Khalimsky spaces.
bool isEqual(const Container &S1, const Container &S2)
DGtal is the top-level namespace which contains all DGtal functions and types.
CubicalComplex< TKSpace, TCellContainer > operator &(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
CubicalComplex< KSpace, Map > CC
std::vector< CellMap > myCells
boost::uint64_t uint64_t
unsigned 64-bit integer.
bool isSubset(const Container &S1, const Container &S2)
CubicalComplex< TKSpace, TCellContainer > operator-(const CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
void filterCellsWithinBounds(const CubicalComplex< TKSpace, TCellContainer > &K, const typename TKSpace::Point &kLow, const typename TKSpace::Point &kUp, BdryCellOutputIterator itBdry, InnerCellOutputIterator itInner)
CubicalComplex< TKSpace, TCellContainer > & operator|=(CubicalComplex< TKSpace, TCellContainer > &, const CubicalComplex< TKSpace, TCellContainer > &)
static const Dimension dimension
The dimension of the embedding space.