degate  0.1.2
Public Member Functions
degate::Image< PixelPolicy, StoragePolicy_PersistentFile > Class Template Reference

Partial template specialization for the storage policy StoragePolicy_PersistentFile. More...

#include <Image.h>

Inheritance diagram for degate::Image< PixelPolicy, StoragePolicy_PersistentFile >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Image (unsigned int _width, unsigned int _height, std::string const &filename)
virtual ~Image ()
template<typename PixelTypeDst >
PixelTypeDst get_pixel_as (unsigned int x, unsigned int y)
 Get pixel with conversion.
template<typename PixelTypeSrc >
void set_pixel_as (unsigned int x, unsigned int y, PixelTypeSrc p)
 Set pixel with conversion.

Detailed Description

template<class PixelPolicy>
class degate::Image< PixelPolicy, StoragePolicy_PersistentFile >

Partial template specialization for the storage policy StoragePolicy_PersistentFile.

Definition at line 160 of file Image.h.


Constructor & Destructor Documentation

template<class PixelPolicy >
degate::Image< PixelPolicy, StoragePolicy_PersistentFile >::Image ( unsigned int  _width,
unsigned int  _height,
std::string const &  filename 
) [inline]
Todo:
The third parameter must be optional.

Create a temp image instead.

Definition at line 169 of file Image.h.

                                     :
      ImageBase(_width, _height),
      StoragePolicy_PersistentFile<PixelPolicy>(_width,
                                                _height,
                                                filename) {}
template<class PixelPolicy >
virtual degate::Image< PixelPolicy, StoragePolicy_PersistentFile >::~Image ( ) [inline, virtual]

Definition at line 177 of file Image.h.

{}

Member Function Documentation

template<class PixelPolicy >
template<typename PixelTypeDst >
PixelTypeDst degate::Image< PixelPolicy, StoragePolicy_PersistentFile >::get_pixel_as ( unsigned int  x,
unsigned int  y 
) [inline]

Get pixel with conversion.

Definition at line 184 of file Image.h.

                                                                     {
      return convert_pixel<PixelTypeDst, typename PixelPolicy::pixel_type>(this->get_pixel(x, y));
    }
template<class PixelPolicy >
template<typename PixelTypeSrc >
void degate::Image< PixelPolicy, StoragePolicy_PersistentFile >::set_pixel_as ( unsigned int  x,
unsigned int  y,
PixelTypeSrc  p 
) [inline]

Set pixel with conversion.

Definition at line 192 of file Image.h.

                                                                             {
      this->set_pixel(x, y,
                      convert_pixel<typename PixelPolicy::pixel_type, PixelTypeSrc>(p));
    }

The documentation for this class was generated from the following file: