]> git.sesse.net Git - nageru/blobdiff - nageru/mjpeg_encoder.cpp
Various fixes for non-VA-API MJPEG encoding.
[nageru] / nageru / mjpeg_encoder.cpp
index 033f67afd9e439db3a5289248bed5b67e8f306ba..e39e802c843cbef0bcd6f130db17702d722c2ce3 100644 (file)
@@ -832,7 +832,7 @@ vector<uint8_t> MJPEGEncoder::encode_jpeg_libjpeg(const QueuedFrame &qf)
        for (unsigned y = 0; y < qf.video_format.height; y += 8) {
                const uint8_t *src = qf.frame->data_copy + field_start + y * qf.video_format.width * 2;
 
-               memcpy_interleaved(tmp_y, tmp_cbcr, src, qf.video_format.width * 8 * 2);
+               memcpy_interleaved(tmp_cbcr, tmp_y, src, qf.video_format.width * 8 * 2);
                memcpy_interleaved(tmp_cb, tmp_cr, tmp_cbcr, qf.video_format.width * 8);
                for (unsigned yy = 0; yy < 8; ++yy) {
                        yptr[yy] = tmp_y + yy * width;