aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVittorio Giovara2016-09-24 20:25:44 -0400
committerVittorio Giovara2016-10-02 15:42:03 -0400
commitbad4aad4037f59ba0ad656164be9ab8f7a0fa2d4 (patch)
tree6f9fd32d364d5ae57549d089c57814b832b9b1ec
parent310c55f1799deab395319471a75c528d0fa7b30d (diff)
avidec: Do not special case palette on big-endian
This simplifies the code a bit, does not change output data in any way.
-rw-r--r--libavformat/avidec.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index ddc7c2b6f4..b2457d5824 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -652,12 +652,8 @@ static int avi_read_header(AVFormatContext *s)
pal_size = FFMIN(pal_size, st->codecpar->extradata_size);
pal_src = st->codecpar->extradata +
st->codecpar->extradata_size - pal_size;
-#if HAVE_BIGENDIAN
for (i = 0; i < pal_size / 4; i++)
- ast->pal[i] = av_bswap32(((uint32_t *)pal_src)[i]);
-#else
- memcpy(ast->pal, pal_src, pal_size);
-#endif
+ ast->pal[i] = AV_RL32(pal_src + 4 * i);
ast->has_pal = 1;
}