The pixel buffer class template specialization for the packed_index_pixel type. More...
#include <pixel_buffer.hpp>
Public Types | |
typedef packed_pixel_row < pixel_type > | pixel_row_type |
typedef packed_index_pixel< bits > | pixel_type |
typedef row_traits < packed_pixel_row < packed_index_pixel< bits > > > | row_traits |
typedef packed_pixel_row < packed_index_pixel< bits > > | row_type |
A row of pixel data. More... | |
Public Member Functions | |
pixel_buffer () | |
pixel_buffer (size_t width, size_t height) | |
size_t | get_height () const |
packed_index_pixel< bits > | get_pixel (size_t x, size_t y) const |
Returns a pixel at (x,y) position. More... | |
row_type & | get_row (size_t index) |
Returns a reference to the row of image data at specified index. More... | |
row_type const & | get_row (size_t index) const |
Returns a const reference to the row of image data at specified index. More... | |
size_t | get_width () const |
row_type & | operator[] (size_t index) |
The non-checking version of get_row() method. More... | |
row_type const & | operator[] (size_t index) const |
The non-checking version of get_row() method. More... | |
void | put_row (size_t index, row_type const &r) |
Replaces the row at specified index. More... | |
void | resize (size_t width, size_t height) |
Resizes the pixel buffer. More... | |
void | set_pixel (size_t x, size_t y, packed_index_pixel< bits >p) |
Replaces a pixel at (x,y) position. More... | |
Protected Types | |
typedef std::vector< row_type > | row_vec |
Protected Attributes | |
size_t | m_height |
row_vec | m_rows |
size_t | m_width |
The pixel buffer class template specialization for the packed_index_pixel type.
typedef packed_pixel_row< pixel_type > png::pixel_buffer< packed_index_pixel< bits > >::pixel_row_type |
typedef packed_index_pixel< bits > png::pixel_buffer< packed_index_pixel< bits > >::pixel_type |
|
inherited |
|
inherited |
A row of pixel data.
|
protectedinherited |
|
inline |
|
inline |
|
inlineinherited |
|
inlineinherited |
Returns a pixel at (x,y) position.
References png::basic_pixel_buffer< pixel, row, traits >::get_row().
|
inlineinherited |
Returns a reference to the row of image data at specified index.
Checks the index before returning a row: an instance of std::out_of_range is thrown if index
is greater than height
.
References png::basic_pixel_buffer< pixel, row, traits >::m_rows.
|
inlineinherited |
Returns a const reference to the row of image data at specified index.
The checking version.
References png::basic_pixel_buffer< pixel, row, traits >::m_rows.
|
inlineinherited |
|
inlineinherited |
The non-checking version of get_row() method.
References png::basic_pixel_buffer< pixel, row, traits >::m_rows.
|
inlineinherited |
The non-checking version of get_row() method.
References png::basic_pixel_buffer< pixel, row, traits >::m_rows.
|
inlineinherited |
Replaces the row at specified index.
References png::basic_pixel_buffer< pixel, row, traits >::m_rows, png::basic_pixel_buffer< pixel, row, traits >::m_width, and png::packed_pixel_row< pixel >::size().
|
inlineinherited |
Resizes the pixel buffer.
If new width or height is greater than the original, expanded pixels are filled with value of pixel().
References png::basic_pixel_buffer< pixel, row, traits >::m_height, png::basic_pixel_buffer< pixel, row, traits >::m_rows, and png::basic_pixel_buffer< pixel, row, traits >::m_width.
|
inlineinherited |
Replaces a pixel at (x,y) position.
References png::basic_pixel_buffer< pixel, row, traits >::get_row().
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |