[MPlayer-cvslog] r34893 - in trunk: codec-cfg.c etc/codecs.conf fmt-conversion.c libmpcodecs/img_format.c libmpcodecs/img_format.h libmpcodecs/mp_image.c libmpcodecs/vf_scale.c m_option.c

cehoyos subversion at mplayerhq.hu
Tue May 8 12:56:22 CEST 2012


Author: cehoyos
Date: Tue May  8 12:56:22 2012
New Revision: 34893

Log:
Improve Avid Meridien (AVUI) decoding with FFmpeg.

Modified:
   trunk/codec-cfg.c
   trunk/etc/codecs.conf
   trunk/fmt-conversion.c
   trunk/libmpcodecs/img_format.c
   trunk/libmpcodecs/img_format.h
   trunk/libmpcodecs/mp_image.c
   trunk/libmpcodecs/vf_scale.c
   trunk/m_option.c

Modified: trunk/codec-cfg.c
==============================================================================
--- trunk/codec-cfg.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/codec-cfg.c	Tue May  8 12:56:22 2012	(r34893)
@@ -190,6 +190,7 @@ static const struct {
     {"444P",        IMGFMT_444P},
     {"444A",        IMGFMT_444A},
     {"422P",        IMGFMT_422P},
+    {"422A",        IMGFMT_422A},
     {"411P",        IMGFMT_411P},
     {"440P",        IMGFMT_440P},
     {"Y800",        IMGFMT_Y800},

Modified: trunk/etc/codecs.conf
==============================================================================
--- trunk/etc/codecs.conf	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/etc/codecs.conf	Tue May  8 12:56:22 2012	(r34893)
@@ -3144,6 +3144,14 @@ videocodec ffdnxhd
   dll "dnxhd"
   out 422P
 
+videocodec ffavui
+  info "FFmpeg Avid Meridien"
+  status working
+  fourcc AVUI
+  driver ffmpeg
+  dll avui
+  out 422A
+
 ; quicktime codecs:
 
 videocodec qtm100

Modified: trunk/fmt-conversion.c
==============================================================================
--- trunk/fmt-conversion.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/fmt-conversion.c	Tue May  8 12:56:22 2012	(r34893)
@@ -65,6 +65,7 @@ static const struct {
     {IMGFMT_RGBA,    PIX_FMT_RGB0},
     {IMGFMT_RGB64LE, PIX_FMT_RGBA64LE},
     {IMGFMT_RGB64BE, PIX_FMT_RGBA64BE},
+    {IMGFMT_422A,    PIX_FMT_YUVA422P},
     {IMGFMT_444A,    PIX_FMT_YUVA444P},
 #endif
 #if LIBAVUTIL_VERSION_INT >= AV_VERSION_INT(51, 20, 1)

Modified: trunk/libmpcodecs/img_format.c
==============================================================================
--- trunk/libmpcodecs/img_format.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/libmpcodecs/img_format.c	Tue May  8 12:56:22 2012	(r34893)
@@ -83,6 +83,7 @@ const char *vo_format_name(int format)
     case IMGFMT_444P: return "Planar 444P";
     case IMGFMT_444A: return "Planar 444P with alpha";
     case IMGFMT_422P: return "Planar 422P";
+    case IMGFMT_422A: return "Planar 422P with alpha";
     case IMGFMT_411P: return "Planar 411P";
     case IMGFMT_NV12: return "Planar NV12";
     case IMGFMT_NV21: return "Planar NV21";
@@ -179,6 +180,10 @@ int mp_get_chroma_shift(int format, int 
         xs = 0;
         ys = 0;
         break;
+    case IMGFMT_422A:
+        xs = 1;
+        ys = 0;
+        break;
     case IMGFMT_420A:
     case IMGFMT_I420:
     case IMGFMT_IYUV:
@@ -204,7 +209,7 @@ int mp_get_chroma_shift(int format, int 
     if (y_shift) *y_shift = ys;
     if (component_bits) *component_bits = bits;
     bpp = 8 + ((16 >> xs) >> ys);
-    if (format == IMGFMT_420A || format == IMGFMT_444A)
+    if (format == IMGFMT_420A || format == IMGFMT_422A || format == IMGFMT_444A)
         bpp += 8;
     bpp *= (bits + 7) >> 3;
     return err ? 0 : bpp;

Modified: trunk/libmpcodecs/img_format.h
==============================================================================
--- trunk/libmpcodecs/img_format.h	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/libmpcodecs/img_format.h	Tue May  8 12:56:22 2012	(r34893)
@@ -126,6 +126,8 @@
 
 // 4:2:0 planar with alpha
 #define IMGFMT_420A 0x41303234
+// 4:2:2 planar with alpha
+#define IMGFMT_422A 0x41323234
 // 4:4:4 planar with alpha
 #define IMGFMT_444A 0x41343434
 

Modified: trunk/libmpcodecs/mp_image.c
==============================================================================
--- trunk/libmpcodecs/mp_image.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/libmpcodecs/mp_image.c	Tue May  8 12:56:22 2012	(r34893)
@@ -141,6 +141,7 @@ void mp_image_setfmt(mp_image_t* mpi,uns
     case IMGFMT_YV12:
         return;
     case IMGFMT_420A:
+    case IMGFMT_422A:
     case IMGFMT_444A:
     case IMGFMT_IF09:
         mpi->num_planes=4;

Modified: trunk/libmpcodecs/vf_scale.c
==============================================================================
--- trunk/libmpcodecs/vf_scale.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/libmpcodecs/vf_scale.c	Tue May  8 12:56:22 2012	(r34893)
@@ -88,6 +88,7 @@ static const unsigned int outfmt_list[]=
     IMGFMT_420P9_LE,
     IMGFMT_420P9_BE,
     IMGFMT_420A,
+    IMGFMT_422A,
     IMGFMT_444A,
     IMGFMT_IYUV,
     IMGFMT_YVU9,

Modified: trunk/m_option.c
==============================================================================
--- trunk/m_option.c	Tue May  8 12:53:40 2012	(r34892)
+++ trunk/m_option.c	Tue May  8 12:56:22 2012	(r34893)
@@ -1099,6 +1099,7 @@ static struct {
   {"420p10",   IMGFMT_420P10},
   {"420p9",    IMGFMT_420P9},
   {"444a", IMGFMT_444A},
+  {"422a", IMGFMT_422A},
   {"420a", IMGFMT_420A},
   {"444p", IMGFMT_444P},
   {"422p", IMGFMT_422P},


More information about the MPlayer-cvslog mailing list