diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2009-03-21 23:08:20 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2009-03-21 23:08:20 +0000 |
commit | f82674e584d0550f3000658c6a579c4b9db139fe (patch) | |
tree | 2cff84728c6bc5d8cde05ba6a63b11b598ded01d /libavcodec | |
parent | 31a79497b7a9fb84e92593ecb5703063ec3ca35a (diff) | |
download | ffmpeg-f82674e584d0550f3000658c6a579c4b9db139fe.tar.gz |
Change the RGB5X5/BGR5X5 pixel format defines so that we have little
endian and big endian variants instead of native-endian ones.
This patch breaks API/ABI backward-compatibility.
Originally committed as revision 18133 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/imgconvert.c | 48 | ||||
-rw-r--r-- | libavcodec/pixdesc.c | 3 |
2 files changed, 40 insertions, 11 deletions
diff --git a/libavcodec/imgconvert.c b/libavcodec/imgconvert.c index 8619b40336..0abefbadc7 100644 --- a/libavcodec/imgconvert.c +++ b/libavcodec/imgconvert.c @@ -216,16 +216,32 @@ static const PixFmtInfo pix_fmt_info[PIX_FMT_NB] = { .depth = 16, .x_chroma_shift = 0, .y_chroma_shift = 0, }, - [PIX_FMT_RGB565] = { - .name = "rgb565", + [PIX_FMT_RGB565BE] = { + .name = "rgb565be", .nb_channels = 3, .color_type = FF_COLOR_RGB, .pixel_type = FF_PIXEL_PACKED, .depth = 5, .x_chroma_shift = 0, .y_chroma_shift = 0, }, - [PIX_FMT_RGB555] = { - .name = "rgb555", + [PIX_FMT_RGB565LE] = { + .name = "rgb565le", + .nb_channels = 3, + .color_type = FF_COLOR_RGB, + .pixel_type = FF_PIXEL_PACKED, + .depth = 5, + .x_chroma_shift = 0, .y_chroma_shift = 0, + }, + [PIX_FMT_RGB555BE] = { + .name = "rgb555be", + .nb_channels = 3, + .color_type = FF_COLOR_RGB, + .pixel_type = FF_PIXEL_PACKED, + .depth = 5, + .x_chroma_shift = 0, .y_chroma_shift = 0, + }, + [PIX_FMT_RGB555LE] = { + .name = "rgb555le", .nb_channels = 3, .color_type = FF_COLOR_RGB, .pixel_type = FF_PIXEL_PACKED, @@ -327,16 +343,32 @@ static const PixFmtInfo pix_fmt_info[PIX_FMT_NB] = { .depth = 8, .x_chroma_shift = 0, .y_chroma_shift = 0, }, - [PIX_FMT_BGR565] = { - .name = "bgr565", + [PIX_FMT_BGR565BE] = { + .name = "bgr565be", + .nb_channels = 3, + .color_type = FF_COLOR_RGB, + .pixel_type = FF_PIXEL_PACKED, + .depth = 5, + .x_chroma_shift = 0, .y_chroma_shift = 0, + }, + [PIX_FMT_BGR565LE] = { + .name = "bgr565le", + .nb_channels = 3, + .color_type = FF_COLOR_RGB, + .pixel_type = FF_PIXEL_PACKED, + .depth = 5, + .x_chroma_shift = 0, .y_chroma_shift = 0, + }, + [PIX_FMT_BGR555BE] = { + .name = "bgr555be", .nb_channels = 3, .color_type = FF_COLOR_RGB, .pixel_type = FF_PIXEL_PACKED, .depth = 5, .x_chroma_shift = 0, .y_chroma_shift = 0, }, - [PIX_FMT_BGR555] = { - .name = "bgr555", + [PIX_FMT_BGR555LE] = { + .name = "bgr555le", .nb_channels = 3, .color_type = FF_COLOR_RGB, .pixel_type = FF_PIXEL_PACKED, diff --git a/libavcodec/pixdesc.c b/libavcodec/pixdesc.c index b4157fc5e7..5851ab0869 100644 --- a/libavcodec/pixdesc.c +++ b/libavcodec/pixdesc.c @@ -154,8 +154,6 @@ static const AVPixFmtDescriptor pix_fmt_desc[PIX_FMT_NB] = { }, .flags = PIX_FMT_BE, }, -//FIXME change pix fmt defines so that we have a LE & BE instead of a native-endian -#if 0 [PIX_FMT_RGB565LE] = { .name = "rgb565le", .nb_channels = 3, @@ -179,7 +177,6 @@ static const AVPixFmtDescriptor pix_fmt_desc[PIX_FMT_NB] = { }, .flags = PIX_FMT_BE, }, -#endif [PIX_FMT_MONOBLACK] = { .name = "monoblack", .nb_channels = 1, |