summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
Diffstat (limited to 'client')
-rw-r--r--client/display_channel.cpp1
-rw-r--r--client/mjpeg_decoder.cpp14
2 files changed, 9 insertions, 6 deletions
diff --git a/client/display_channel.cpp b/client/display_channel.cpp
index 6427ae4d..9219568a 100644
--- a/client/display_channel.cpp
+++ b/client/display_channel.cpp
@@ -264,6 +264,7 @@ VideoStream::VideoStream(RedClient& client, Canvas& canvas, DisplayChannel& chan
, _clip (NULL)
, _frames_head (0)
, _frames_tail (0)
+ , _kill_mark (0)
, _uncompressed_data (NULL)
, _update_mark (0)
, _update_time (0)
diff --git a/client/mjpeg_decoder.cpp b/client/mjpeg_decoder.cpp
index df0dbad0..cf3e44d3 100644
--- a/client/mjpeg_decoder.cpp
+++ b/client/mjpeg_decoder.cpp
@@ -113,13 +113,15 @@ void MJpegDecoder::convert_scanline(void)
row = (uint32_t *)(_frame + _y * _stride);
s = _scanline;
+
+ /* TODO after major bump.
+ We need to check for the old major and for backwards compat
+ a) swap r and b
+ b) to-yuv with right values and then from-yuv with old wrong values
+ */
+
for (x = 0; x < _width; x++) {
- /* This switches the order of red and blue.
- This is not accidental, but for backwards
- compatibility, since a bug in the old
- ffmpeg-using mjpeg code got these switched
- due to endianness issues. */
- c = s[0] | s[1] << 8 | s[2] << 16;
+ c = s[0] << 16 | s[1] << 8 | s[2];
s += 3;
*row++ = c;
}