31#if defined(ImageCache_RECURSES)
32#error Recursive header files inclusion detected in ImageCache.h
35#define ImageCache_RECURSES
37#if !defined ImageCache_h
44#include "DGtal/base/Common.h"
45#include "DGtal/base/ConceptUtils.h"
46#include "DGtal/images/CImage.h"
47#include "DGtal/images/CImageFactory.h"
48#include "DGtal/images/CImageCacheReadPolicy.h"
49#include "DGtal/images/CImageCacheWritePolicy.h"
50#include "DGtal/base/Alias.h"
76template <
typename TImageContainer,
typename TImageFactory,
typename TReadPolicy,
typename TWritePolicy>
278template <
typename TImageContainer,
typename TImageFactory,
typename TReadPolicy,
typename TWritePolicy>
287#include "DGtal/images/ImageCachePolicies.h"
288#include "DGtal/images/ImageCache.ih"
295#undef ImageCache_RECURSES
Aim: This class encapsulates its parameter class so that to indicate to the user that the object/poin...
Aim: implements an images cache with 'read and write' policies.
void clearCacheAndResetCacheMisses()
bool read(const Point &aPoint, Value &aValue) const
unsigned int cacheMissWrite
ImageCache(const ImageCache &other)
ImageCache(Alias< ImageFactory > anImageFactory, Alias< ReadPolicy > aReadPolicy, Alias< WritePolicy > aWritePolicy)
ImageCache< TImageContainer, TImageFactory, TReadPolicy, TWritePolicy > Self
unsigned int getCacheMissRead()
ImageContainer::Point Point
ImageCache & operator=(const ImageCache &other)
void update(const Domain &aDomain)
bool write(const Point &aPoint, const Value &aValue)
WritePolicy * myWritePolicy
ImageFactory * myImageFactoryPtr
Alias on the image factory.
ImageContainer * getPage(const Domain &aDomain) const
ReadPolicy * myReadPolicy
Specialized caches.
TImageFactory ImageFactory
BOOST_CONCEPT_ASSERT((concepts::CImageCacheReadPolicy< TReadPolicy >))
ImageContainer::Domain Domain
unsigned int cacheMissRead
cache miss values
BOOST_CONCEPT_ASSERT((concepts::CImageCacheWritePolicy< TWritePolicy >))
BOOST_CONCEPT_ASSERT((concepts::CImage< TImageContainer >))
Checking concepts.
unsigned int getCacheMissWrite()
ImageContainer::Value Value
BOOST_CONCEPT_ASSERT((concepts::CImageFactory< TImageFactory >))
TImageContainer ImageContainer
Types copied from the container.
void selfDisplay(std::ostream &out) const
DGtal is the top-level namespace which contains all DGtal functions and types.
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
Aim: Defines the concept describing a cache read policy.
Aim: Defines the concept describing a cache write policy.
Aim: Defines the concept describing an image factory.
Aim: Defines the concept describing a read/write image, having an output iterator.