]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/dvdata.c
Show profile in avcodec_string().
[ffmpeg] / libavcodec / dvdata.c
index 511087207aab97fd5c8fef99590e7c726c9914e0..05993d874f6e741efb1ec62c84a736d2ac679ff8 100644 (file)
@@ -20,7 +20,7 @@
  */
 
 /**
- * @file libavcodec/dvdata.c
+ * @file
  * Constants for DV codec.
  */
 
@@ -52,7 +52,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 30,
       .height = 480,
       .width = 720,
-      .sar = {{10, 11}, {40, 33}},
+      .sar = {{8, 9}, {32, 27}},
       .work_chunks = &work_chunks_dv25ntsc[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV411P,
@@ -72,7 +72,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 25,
       .height = 576,
       .width = 720,
-      .sar = {{59, 54}, {118, 81}},
+      .sar = {{16, 15}, {64, 45}},
       .work_chunks = &work_chunks_dv25pal[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV420P,
@@ -92,7 +92,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 25,
       .height = 576,
       .width = 720,
-      .sar = {{59, 54}, {118, 81}},
+      .sar = {{16, 15}, {64, 45}},
       .work_chunks = &work_chunks_dv25pal411[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV411P,
@@ -112,7 +112,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 30,
       .height = 480,
       .width = 720,
-      .sar = {{10, 11}, {40, 33}},
+      .sar = {{8, 9}, {32, 27}},
       .work_chunks = &work_chunks_dv50ntsc[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -132,7 +132,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 25,
       .height = 576,
       .width = 720,
-      .sar = {{59, 54}, {118, 81}},
+      .sar = {{16, 15}, {64, 45}},
       .work_chunks = &work_chunks_dv50pal[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -152,7 +152,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 30,
       .height = 1080,
       .width = 1280,
-      .sar = {{1, 1}, {1, 1}},
+      .sar = {{1, 1}, {3, 2}},
       .work_chunks = &work_chunks_dv100ntsci[0],
       .idct_factor = &dv_idct_factor_hd1080[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -172,7 +172,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 25,
       .height = 1080,
       .width = 1440,
-      .sar = {{1, 1}, {1, 1}},
+      .sar = {{1, 1}, {4, 3}},
       .work_chunks = &work_chunks_dv100pali[0],
       .idct_factor = &dv_idct_factor_hd1080[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -192,7 +192,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 60,
       .height = 720,
       .width = 960,
-      .sar = {{1, 1}, {1, 1}},
+      .sar = {{1, 1}, {4, 3}},
       .work_chunks = &work_chunks_dv100ntscp[0],
       .idct_factor = &dv_idct_factor_hd720[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -212,7 +212,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 50,
       .height = 720,
       .width = 960,
-      .sar = {{1, 1}, {1, 1}},
+      .sar = {{1, 1}, {4, 3}},
       .work_chunks = &work_chunks_dv100palp[0],
       .idct_factor = &dv_idct_factor_hd720[0],
       .pix_fmt = PIX_FMT_YUV422P,
@@ -232,7 +232,7 @@ static const DVprofile dv_profiles[] = {
       .ltc_divisor = 25,
       .height = 576,
       .width = 720,
-      .sar = {{59, 54}, {118, 81}},
+      .sar = {{16, 15}, {64, 45}},
       .work_chunks = &work_chunks_dv25pal[0],
       .idct_factor = &dv_idct_factor_sd[0],
       .pix_fmt = PIX_FMT_YUV420P,
@@ -255,7 +255,7 @@ const DVprofile* ff_dv_frame_profile(const DVprofile *sys,
    int stype = frame[80*5 + 48 + 3] & 0x1f;
 
    /* 576i50 25Mbps 4:1:1 is a special case */
-   if (dsf == 1 && stype == 0 && frame[5] & 0x07) {
+   if (dsf == 1 && stype == 0 && frame[4] & 0x07 /* the APT field */) {
        return &dv_profiles[2];
    }