[FFmpeg-devel] [PATCH] j2kdec: remove pointless swapping
Paul B Mahol
onemda at gmail.com
Tue Mar 27 03:15:20 CEST 2012
Signed-off-by: Paul B Mahol <onemda at gmail.com>
---
libavcodec/j2kdec.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/libavcodec/j2kdec.c b/libavcodec/j2kdec.c
index 8d0b643..6a4b2b6 100644
--- a/libavcodec/j2kdec.c
+++ b/libavcodec/j2kdec.c
@@ -269,7 +269,7 @@ static int get_siz(J2kDecoderContext *s)
}
break;
case 4:
- s->avctx->pix_fmt = PIX_FMT_BGRA;
+ s->avctx->pix_fmt = PIX_FMT_RGBA;
break;
}
@@ -848,9 +848,6 @@ static int decode_tile(J2kDecoderContext *s, J2kTile *tile)
if (tile->codsty[0].mct)
mct_decode(s, tile);
- if (s->avctx->pix_fmt == PIX_FMT_BGRA) // RGBA -> BGRA
- FFSWAP(int *, src[0], src[2]);
-
if (s->precision <= 8) {
for (compno = 0; compno < s->ncomponents; compno++){
y = tile->comp[compno].coord[1][0] - s->image_offset_y;
--
1.7.7
More information about the ffmpeg-devel
mailing list