]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/assdec.c
rmdec: when using INT4 deinterleaving, error out if sub_packet_h <= 1.
[ffmpeg] / libavformat / assdec.c
index b270200af2cba769f982029ca5ab688b96a78b6b..bb1f525616c571a399c8327715c50e5f01337fda 100644 (file)
@@ -19,6 +19,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
+#include "libavutil/mathematics.h"
 #include "avformat.h"
 #include "internal.h"
 
@@ -72,7 +73,7 @@ static int event_cmp(uint8_t **a, uint8_t **b)
     return get_pts(*a) - get_pts(*b);
 }
 
-static int read_header(AVFormatContext *s, AVFormatParameters *ap)
+static int read_header(AVFormatContext *s)
 {
     int i, len, header_remaining;
     ASSContext *ass = s->priv_data;
@@ -82,10 +83,10 @@ static int read_header(AVFormatContext *s, AVFormatParameters *ap)
     uint8_t *p, **dst[2]={0};
     int pos[2]={0};
 
-    st = av_new_stream(s, 0);
+    st = avformat_new_stream(s, NULL);
     if (!st)
         return -1;
-    av_set_pts_info(st, 64, 1, 100);
+    avpriv_set_pts_info(st, 64, 1, 100);
     st->codec->codec_type = AVMEDIA_TYPE_SUBTITLE;
     st->codec->codec_id= CODEC_ID_SSA;