summaryrefslogtreecommitdiff
path: root/transcode/transcode-ffmpeg3.patch
blob: efc928fec17ce1106caffab3e143405e36debf99 (plain)
    1 --- transcode-1.1.7/export/aud_aux.c.orig	2016-02-16 23:38:40.162690789 +0000
    2 +++ transcode-1.1.7/export/aud_aux.c	2016-02-16 23:40:50.335488439 +0000
    3 @@ -326,10 +326,10 @@
    4  
    5      switch (o_codec) {
    6        case   0x50:
    7 -        codeid = CODEC_ID_MP2;
    8 +        codeid = AV_CODEC_ID_MP2;
    9          break;
   10        case 0x2000:
   11 -        codeid = CODEC_ID_AC3;
   12 +        codeid = AV_CODEC_ID_AC3;
   13          break;
   14        default:
   15          tc_warn("cannot init ffmpeg with %x", o_codec);
   16 @@ -363,7 +363,7 @@
   17      TC_UNLOCK_LIBAVCODEC;
   18      if (ret < 0) {
   19          tc_warn("tc_audio_init_ffmpeg: could not open %s codec !",
   20 -                (codeid == CODEC_ID_MP2) ?"mpa" :"ac3");
   21 +                (codeid == AV_CODEC_ID_MP2) ?"mpa" :"ac3");
   22          return(TC_EXPORT_ERROR);
   23      }
   24  
   25 --- transcode-1.1.7/import/import_ffmpeg.c.orig	2016-02-16 23:52:36.192589648 +0000
   26 +++ transcode-1.1.7/import/import_ffmpeg.c	2016-02-16 23:54:38.728757498 +0000
   27 @@ -59,51 +59,51 @@
   28  
   29  // fourCC to ID mapping taken from MPlayer's codecs.conf
   30  static struct ffmpeg_codec ffmpeg_codecs[] = {
   31 -  {CODEC_ID_MSMPEG4V1, TC_CODEC_ERROR, "mp41",
   32 +  {AV_CODEC_ID_MSMPEG4V1, TC_CODEC_ERROR, "mp41",
   33      {"MP41", "DIV1", ""}},
   34 -  {CODEC_ID_MSMPEG4V2, TC_CODEC_MP42, "mp42",
   35 +  {AV_CODEC_ID_MSMPEG4V2, TC_CODEC_MP42, "mp42",
   36      {"MP42", "DIV2", ""}},
   37 -  {CODEC_ID_MSMPEG4V3, TC_CODEC_DIVX3, "msmpeg4",
   38 +  {AV_CODEC_ID_MSMPEG4V3, TC_CODEC_DIVX3, "msmpeg4",
   39      {"DIV3", "DIV5", "AP41", "MPG3", "MP43", ""}},
   40 -  {CODEC_ID_MPEG4, TC_CODEC_DIVX4, "mpeg4",
   41 +  {AV_CODEC_ID_MPEG4, TC_CODEC_DIVX4, "mpeg4",
   42      {"DIVX", "XVID", "MP4S", "M4S2", "MP4V", "UMP4", "DX50", ""}},
   43 -  {CODEC_ID_MJPEG, TC_CODEC_MJPEG, "mjpeg",
   44 +  {AV_CODEC_ID_MJPEG, TC_CODEC_MJPEG, "mjpeg",
   45      {"MJPG", "AVRN", "AVDJ", "JPEG", "MJPA", "JFIF", ""}},
   46 -  {CODEC_ID_MPEG1VIDEO, TC_CODEC_MPG1, "mpeg1video",
   47 +  {AV_CODEC_ID_MPEG1VIDEO, TC_CODEC_MPG1, "mpeg1video",
   48      {"MPG1", ""}},
   49 -  {CODEC_ID_DVVIDEO, TC_CODEC_DV, "dvvideo",
   50 +  {AV_CODEC_ID_DVVIDEO, TC_CODEC_DV, "dvvideo",
   51      {"DVSD", ""}},
   52 -  {CODEC_ID_WMV1, TC_CODEC_WMV1, "wmv1",
   53 +  {AV_CODEC_ID_WMV1, TC_CODEC_WMV1, "wmv1",
   54      {"WMV1", ""}},
   55 -  {CODEC_ID_WMV2, TC_CODEC_WMV2, "wmv2",
   56 +  {AV_CODEC_ID_WMV2, TC_CODEC_WMV2, "wmv2",
   57      {"WMV2", ""}},
   58 -  {CODEC_ID_HUFFYUV, TC_CODEC_HUFFYUV, "hfyu",
   59 +  {AV_CODEC_ID_HUFFYUV, TC_CODEC_HUFFYUV, "hfyu",
   60      {"HFYU", ""}},
   61 -  {CODEC_ID_H263I, TC_CODEC_H263I, "h263i",
   62 +  {AV_CODEC_ID_H263I, TC_CODEC_H263I, "h263i",
   63      {"I263", ""}},
   64 -  {CODEC_ID_H263P, TC_CODEC_H263P, "h263p",
   65 +  {AV_CODEC_ID_H263P, TC_CODEC_H263P, "h263p",
   66      {"H263", "U263", "VIV1", ""}},
   67 -  {CODEC_ID_H264, TC_CODEC_H264, "h264",
   68 +  {AV_CODEC_ID_H264, TC_CODEC_H264, "h264",
   69      {"H264", "h264", "X264", "x264", "avc1", ""}},
   70 -  {CODEC_ID_RV10, TC_CODEC_RV10, "rv10",
   71 +  {AV_CODEC_ID_RV10, TC_CODEC_RV10, "rv10",
   72      {"RV10", "RV13", ""}},
   73 -  {CODEC_ID_SVQ1, TC_CODEC_SVQ1, "svq1",
   74 +  {AV_CODEC_ID_SVQ1, TC_CODEC_SVQ1, "svq1",
   75      {"SVQ1", ""}},
   76 -  {CODEC_ID_SVQ3, TC_CODEC_SVQ3, "svq3",
   77 +  {AV_CODEC_ID_SVQ3, TC_CODEC_SVQ3, "svq3",
   78      {"SVQ3", ""}},
   79 -  {CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG2, "mpeg2video",
   80 +  {AV_CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG2, "mpeg2video",
   81      {"MPG2", ""}},
   82 -  {CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG, "mpeg2video",
   83 +  {AV_CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG, "mpeg2video",
   84      {"MPG2", ""}},
   85 -  {CODEC_ID_ASV1, TC_CODEC_ASV1, "asv1",
   86 +  {AV_CODEC_ID_ASV1, TC_CODEC_ASV1, "asv1",
   87      {"ASV1", ""}},
   88 -  {CODEC_ID_ASV2, TC_CODEC_ASV2, "asv2",
   89 +  {AV_CODEC_ID_ASV2, TC_CODEC_ASV2, "asv2",
   90      {"ASV2", ""}},
   91 -  {CODEC_ID_FFV1, TC_CODEC_FFV1, "ffv1",
   92 +  {AV_CODEC_ID_FFV1, TC_CODEC_FFV1, "ffv1",
   93      {"FFV1", ""}},
   94 -  {CODEC_ID_RAWVIDEO, TC_CODEC_YUV420P, "raw",
   95 +  {AV_CODEC_ID_RAWVIDEO, TC_CODEC_YUV420P, "raw",
   96      {"I420", "IYUV", ""}},
   97 -  {CODEC_ID_RAWVIDEO, TC_CODEC_YUV422P, "raw",
   98 +  {AV_CODEC_ID_RAWVIDEO, TC_CODEC_YUV422P, "raw",
   99      {"Y42B", ""}},
  100    {0, TC_CODEC_UNKNOWN, NULL, {""}}};
  101  
  102 @@ -324,13 +324,13 @@
  103      // XXX: some codecs need extra data
  104      switch (codec->id)
  105      {
  106 -      case CODEC_ID_MJPEG: extra_data_size  = 28; break;
  107 -      case CODEC_ID_LJPEG: extra_data_size  = 28; break;
  108 -      case CODEC_ID_HUFFYUV: extra_data_size = 1000; break;
  109 -      case CODEC_ID_ASV1: extra_data_size = 8; break;
  110 -      case CODEC_ID_ASV2: extra_data_size = 8; break;
  111 -      case CODEC_ID_WMV1: extra_data_size = 4; break;
  112 -      case CODEC_ID_WMV2: extra_data_size = 4; break;
  113 +      case AV_CODEC_ID_MJPEG: extra_data_size  = 28; break;
  114 +      case AV_CODEC_ID_LJPEG: extra_data_size  = 28; break;
  115 +      case AV_CODEC_ID_HUFFYUV: extra_data_size = 1000; break;
  116 +      case AV_CODEC_ID_ASV1: extra_data_size = 8; break;
  117 +      case AV_CODEC_ID_ASV2: extra_data_size = 8; break;
  118 +      case AV_CODEC_ID_WMV1: extra_data_size = 4; break;
  119 +      case AV_CODEC_ID_WMV2: extra_data_size = 4; break;
  120        default: extra_data_size = 0; break;
  121      }
  122  
  123 @@ -360,7 +360,7 @@
  124          frame_size = x_dim*y_dim + 2*UV_PLANE_SIZE(IMG_YUV_DEFAULT,x_dim,y_dim);
  125  
  126  	// we adapt the color space
  127 -        if(codec->id == CODEC_ID_MJPEG) {
  128 +        if(codec->id == AV_CODEC_ID_MJPEG) {
  129  	  enable_levels_filter();
  130          }
  131          break;
  132 @@ -434,7 +434,7 @@
  133        }
  134  
  135        // we adapt the color space
  136 -      if(codec->id == CODEC_ID_MJPEG) {
  137 +      if(codec->id == AV_CODEC_ID_MJPEG) {
  138          enable_levels_filter();
  139        }
  140  
  141 @@ -504,13 +504,13 @@
  142        int bkey = 0;
  143  
  144        // check for keyframes
  145 -      if (codec->id == CODEC_ID_MSMPEG4V3) {
  146 +      if (codec->id == AV_CODEC_ID_MSMPEG4V3) {
  147  	if (divx3_is_key(buffer)) bkey = 1;
  148        }
  149 -      else if (codec->id == CODEC_ID_MPEG4) {
  150 +      else if (codec->id == AV_CODEC_ID_MPEG4) {
  151  	if (mpeg4_is_key(buffer, bytes_read)) bkey = 1;
  152        }
  153 -      else if (codec->id == CODEC_ID_MJPEG) {
  154 +      else if (codec->id == AV_CODEC_ID_MJPEG) {
  155  	bkey = 1;
  156        }
  157  
  158 --- transcode-1.1.7/import/decode_lavc.c.orig	2016-02-16 23:56:35.488282034 +0000
  159 +++ transcode-1.1.7/import/decode_lavc.c	2016-02-16 23:56:55.201535074 +0000
  160 @@ -58,37 +58,37 @@
  161  
  162  // fourCC to ID mapping taken from MPlayer's codecs.conf
  163  static struct ffmpeg_codec ffmpeg_codecs[] = {
  164 -  {CODEC_ID_MSMPEG4V1, TC_CODEC_ERROR, "mp41",
  165 +  {AV_CODEC_ID_MSMPEG4V1, TC_CODEC_ERROR, "mp41",
  166      {"MP41", "DIV1", ""}},
  167 -  {CODEC_ID_MSMPEG4V2, TC_CODEC_MP42, "mp42",
  168 +  {AV_CODEC_ID_MSMPEG4V2, TC_CODEC_MP42, "mp42",
  169      {"MP42", "DIV2", ""}},
  170 -  {CODEC_ID_MSMPEG4V3, TC_CODEC_DIVX3, "msmpeg4",
  171 +  {AV_CODEC_ID_MSMPEG4V3, TC_CODEC_DIVX3, "msmpeg4",
  172      {"DIV3", "DIV5", "AP41", "MPG3", "MP43", ""}},
  173 -  {CODEC_ID_MPEG4, TC_CODEC_DIVX4, "mpeg4",
  174 +  {AV_CODEC_ID_MPEG4, TC_CODEC_DIVX4, "mpeg4",
  175      {"DIVX", "XVID", "MP4S", "M4S2", "MP4V", "UMP4", "DX50", ""}},
  176 -  {CODEC_ID_MJPEG, TC_CODEC_MJPEG, "mjpeg",
  177 +  {AV_CODEC_ID_MJPEG, TC_CODEC_MJPEG, "mjpeg",
  178      {"MJPG", "AVRN", "AVDJ", "JPEG", "MJPA", "JFIF", ""}},
  179 -  {CODEC_ID_MPEG1VIDEO, TC_CODEC_MPEG1VIDEO, "mpeg1video",
  180 +  {AV_CODEC_ID_MPEG1VIDEO, TC_CODEC_MPEG1VIDEO, "mpeg1video",
  181      {"MPG1", ""}},
  182 -  {CODEC_ID_DVVIDEO, TC_CODEC_DV, "dvvideo",
  183 +  {AV_CODEC_ID_DVVIDEO, TC_CODEC_DV, "dvvideo",
  184      {"DVSD", ""}},
  185 -  {CODEC_ID_WMV1, TC_CODEC_WMV1, "wmv1",
  186 +  {AV_CODEC_ID_WMV1, TC_CODEC_WMV1, "wmv1",
  187      {"WMV1", ""}},
  188 -  {CODEC_ID_WMV2, TC_CODEC_WMV2, "wmv2",
  189 +  {AV_CODEC_ID_WMV2, TC_CODEC_WMV2, "wmv2",
  190      {"WMV2", ""}},
  191 -  {CODEC_ID_HUFFYUV, TC_CODEC_HUFFYUV, "hfyu",
  192 +  {AV_CODEC_ID_HUFFYUV, TC_CODEC_HUFFYUV, "hfyu",
  193      {"HFYU", ""}},
  194 -  {CODEC_ID_H263I, TC_CODEC_H263I, "h263i",
  195 +  {AV_CODEC_ID_H263I, TC_CODEC_H263I, "h263i",
  196      {"I263", ""}},
  197 -  {CODEC_ID_H263P, TC_CODEC_H263P, "h263p",
  198 +  {AV_CODEC_ID_H263P, TC_CODEC_H263P, "h263p",
  199      {"H263", "U263", "VIV1", ""}},
  200 -  {CODEC_ID_RV10, TC_CODEC_RV10, "rv10",
  201 +  {AV_CODEC_ID_RV10, TC_CODEC_RV10, "rv10",
  202      {"RV10", "RV13", ""}},
  203 -  {CODEC_ID_SVQ1, TC_CODEC_SVQ1, "svq1",
  204 +  {AV_CODEC_ID_SVQ1, TC_CODEC_SVQ1, "svq1",
  205      {"SVQ1", ""}},
  206 -  {CODEC_ID_SVQ3, TC_CODEC_SVQ3, "svq3",
  207 +  {AV_CODEC_ID_SVQ3, TC_CODEC_SVQ3, "svq3",
  208      {"SVQ3", ""}},
  209 -  {CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG2, "mpeg2video",
  210 +  {AV_CODEC_ID_MPEG2VIDEO, TC_CODEC_MPEG2, "mpeg2video",
  211      {"MPG2", ""}},
  212    {0, TC_CODEC_UNKNOWN, NULL, {""}}};
  213  

Generated by cgit