VideoTools
|
A descriptor for one colour component in a Gv::CaptureBufferFormat structure. More...
#include <gvcapturebuffer.h>
Public Types | |
enum | PlanarOffset { XY = 0x800, XY2 = 0x400, XY4 = 0x200, XY8 = 0x100 } |
enum | Type { c_byte, c_word_le, c_word_be } |
Public Member Functions | |
CaptureBufferComponent () | |
Default constructor for a simple step-three component. | |
CaptureBufferComponent (size_t offset_, unsigned short x_shift_, unsigned short y_shift_, size_t step_, unsigned short depth_=8, unsigned short shift_=0, Type type_=c_byte, short linesize_shift_=0) | |
Constructor. More... | |
unsigned int | value (const unsigned char *p) const |
Returns the value at p. | |
unsigned char | value8 (const unsigned char *p) const |
Returns the 0..255 value at p. | |
size_t | offset (int x, int y, const CaptureBufferScale &scale) const |
Returns the buffer offset for the given pixel. | |
size_t | offset (int y, const CaptureBufferScale &scale) const |
Returns the buffer offset for a start-of-row pixel. | |
bool | is_simple (size_t offset) const |
Returns true if the component x_shift and y_shift are zero, the depth is eight, the shift is zero, the step is three, and the offset matches the parameter. More... | |
unsigned short | xshift () const |
Returns the x_shift. | |
unsigned short | yshift () const |
Returns the y_shift. | |
size_t | step () const |
Returns the step. | |
unsigned short | depth () const |
Returns the depth. | |
A descriptor for one colour component in a Gv::CaptureBufferFormat structure.
Definition at line 152 of file gvcapturebuffer.h.
Gv::CaptureBufferComponent::CaptureBufferComponent | ( | size_t | offset_, |
unsigned short | x_shift_, | ||
unsigned short | y_shift_, | ||
size_t | step_, | ||
unsigned short | depth_ = 8 , |
||
unsigned short | shift_ = 0 , |
||
Type | type_ = c_byte , |
||
short | linesize_shift_ = 0 |
||
) |
Constructor.
The offset parameter is small fixed offset (eg. 0, 1 or 2) optionally combined with flags of XY/XY4/XY8 representing fractions of dy*linesize.
Definition at line 190 of file gvcapturebuffer.cpp.
|
inline |
Returns true if the component x_shift and y_shift are zero, the depth is eight, the shift is zero, the step is three, and the offset matches the parameter.
Definition at line 423 of file gvcapturebuffer.h.