diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/rgb_xyz.cc | 6 | ||||
| -rw-r--r-- | src/rgb_xyz.h | 3 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/rgb_xyz.cc b/src/rgb_xyz.cc index 1110accb..b4307756 100644 --- a/src/rgb_xyz.cc +++ b/src/rgb_xyz.cc @@ -67,7 +67,8 @@ void dcp::xyz_to_rgba ( boost::shared_ptr<const OpenJPEGImage> xyz_image, ColourConversion const & conversion, - uint8_t* argb + uint8_t* argb, + int stride ) { int const max_colour = pow (2, 16) - 1; @@ -134,8 +135,7 @@ dcp::xyz_to_rgba ( *argb_line++ = 0xff; } - /* 4 bytes per pixel */ - argb += width * 4; + argb += stride; } } diff --git a/src/rgb_xyz.h b/src/rgb_xyz.h index 51846083..907869af 100644 --- a/src/rgb_xyz.h +++ b/src/rgb_xyz.h @@ -46,7 +46,8 @@ class ColourConversion; extern void xyz_to_rgba ( boost::shared_ptr<const OpenJPEGImage>, ColourConversion const & conversion, - uint8_t* rgba + uint8_t* rgba, + int stride ); extern void xyz_to_rgb ( |
