DGtal  1.1.0
CConstImage.h
1 
17 #pragma once
18 
28 #if defined(CConstImageRECURSES)
29 #error Recursive header files inclusion detected in CConstImage.h
30 #else // defined(CConstImageRECURSES)
31 
32 #define CConstImageRECURSES
33 
34 #if !defined CConstImage_h
35 
36 #define CConstImage_h
37 
38 #include <boost/concept_check.hpp>
39 #include <boost/concept/assert.hpp>
40 #include <boost/concept/requires.hpp>
41 
42 #include "DGtal/kernel/CPointFunctor.h"
43 #include "DGtal/kernel/domains/CDomain.h"
44 #include "DGtal/base/CConstBidirectionalRangeFromPoint.h"
45 #include "DGtal/base/CLabel.h"
46 #include "DGtal/images/CTrivialConstImage.h"
47 
48 namespace DGtal
49 {
50  namespace concepts
51  {
53  // struct CConstImage
93  template <typename I>
95  {
96 
97  public:
98 
99  //Inner types
100  typedef typename I::Domain Domain;
102 
103  typedef typename I::ConstRange ConstRange;
105 
107  {
108  ConceptUtils::sameType(i.domain(), d);
109  ConceptUtils::sameType(i.constRange(), r);
110  }
111 
112  private:
113  I i;
116 
117  };
118  }
119 } // namespace DGtal
120 
121 // //
123 
124 #endif // !defined CConstImage_h
125 
126 #undef CConstImageRECURSES
127 #endif // else defined(CConstImageRECURSES)
DGtal::concepts::CConstImage::BOOST_CONCEPT_USAGE
BOOST_CONCEPT_USAGE(CConstImage)
Definition: CConstImage.h:106
DGtal::concepts::CConstBidirectionalRangeFromPoint
Aim: refined concept of const bidirectional range with a begin() method from a point.
Definition: CConstBidirectionalRangeFromPoint.h:94
DGtal::concepts::CConstImage::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CConstBidirectionalRangeFromPoint< ConstRange >))
DGtal::concepts::CDomain
Aim: This concept represents a digital domain, i.e. a non mutable subset of points of the given digit...
Definition: CDomain.h:130
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Definition: ClosedIntegerHalfPlane.h:49
Domain
HyperRectDomain< Space > Domain
Definition: testSimpleRandomAccessRangeFromPoint.cpp:44
DGtal::concepts::CConstImage::ConstRange
I::ConstRange ConstRange
Definition: CConstImage.h:103
DGtal::concepts::CConstImage::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((concepts::CDomain< Domain >))
ConstRange
Image::ConstRange ConstRange
Definition: testSimpleRandomAccessRangeFromPoint.cpp:47
DGtal::concepts::ConceptUtils::sameType
void sameType(const T &, const T &)
Definition: ConceptUtils.h:117
DGtal::concepts::CConstImage::r
ConstRange r
Definition: CConstImage.h:115
DGtal::concepts::CConstImage::Domain
I::Domain Domain
Definition: CConstImage.h:100
DGtal::concepts::CTrivialConstImage
Aim: Defines the concept describing a read-only image, which is a refinement of CPointFunctor.
Definition: CTrivialConstImage.h:89
DGtal::concepts::CConstImage::i
I i
Definition: CConstImage.h:113
DGtal::concepts::CConstImage
Aim: Defines the concept describing a read-only image, which is a refinement of CPointFunctor.
Definition: CConstImage.h:95
DGtal::concepts::CConstImage::d
Domain d
Definition: CConstImage.h:114