Hi,
On 26-03-15 17:17, Ricardo Ribalda Delgado wrote:
Y16 is a little-endian format. The original implementation assumed that
it was big-endian.
Signed-off-by: Ricardo Ribalda Delgado <ricardo.riba...@gmail.com>
Thanks merged upstream, both into master and stable-1.6 branches.
Regards,
Hans
---
lib/libv4lconvert/rgbyuv.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/lib/libv4lconvert/rgbyuv.c b/lib/libv4lconvert/rgbyuv.c
index 0f30192..75c42aa 100644
--- a/lib/libv4lconvert/rgbyuv.c
+++ b/lib/libv4lconvert/rgbyuv.c
@@ -591,6 +591,9 @@ void v4lconvert_y16_to_rgb24(const unsigned char *src,
unsigned char *dest,
int width, int height)
{
int j;
+
+ src++; /*Y16 is little endian*/
+
while (--height >= 0) {
for (j = 0; j < width; j++) {
*dest++ = *src;
@@ -606,6 +609,8 @@ void v4lconvert_y16_to_yuv420(const unsigned char *src,
unsigned char *dest,
{
int x, y;
+ src++; /*Y16 is little endian*/
+
/* Y */
for (y = 0; y < src_fmt->fmt.pix.height; y++)
for (x = 0; x < src_fmt->fmt.pix.width; x++){
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html