24 #include <fvutils/rectification/rectinfo_lut_block.h>
26 #include <core/exceptions/software.h>
28 using namespace fawkes;
30 namespace firevision {
47 RectificationLutInfoBlock::RectificationLutInfoBlock(uint16_t width,
59 _lut_block_header->
width = width;
60 _lut_block_header->
height = height;
80 uint16_t *to_x, uint16_t *to_y)
82 if ( x > _lut_block_header->
width ) {
85 if ( y > _lut_block_header->
height ) {
89 *to_x = _lut_data[y * _lut_block_header->
width + x].
x;
90 *to_y = _lut_data[y * _lut_block_header->
width + x].
y;
102 uint16_t to_x, uint16_t to_y)
104 if ( x > _lut_block_header->
width ) {
107 if ( y > _lut_block_header->
height ) {
110 if ( to_x > _lut_block_header->
width ) {
113 if ( to_y > _lut_block_header->
height ) {
117 _lut_data[y * _lut_block_header->
width + x].
x = to_x;
118 _lut_data[y * _lut_block_header->
width + x].
y = to_y;
128 return _lut_block_header->
width;
138 return _lut_block_header->
height;