lavf,lavd: replace av_new_stream->avformat_new_stream part I.
Trivial replacements with sed are done in this commit: sed 's/av_new_stream(\([^)]*\), 0)/avformat_new_stream(\1, NULL)/'
This commit is contained in:
@@ -60,7 +60,7 @@ static av_cold int audio_read_header(AVFormatContext *s1,
|
||||
enum CodecID codec_id;
|
||||
snd_pcm_sw_params_t *sw_params;
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st) {
|
||||
av_log(s1, AV_LOG_ERROR, "Cannot add stream\n");
|
||||
|
||||
|
||||
@@ -271,7 +271,7 @@ static int grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
|
||||
goto out;
|
||||
}
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st) {
|
||||
ret = AVERROR(ENOMEM);
|
||||
goto out;
|
||||
|
||||
@@ -108,7 +108,7 @@ av_cold static int fbdev_read_header(AVFormatContext *avctx,
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (!(st = av_new_stream(avctx, 0)))
|
||||
if (!(st = avformat_new_stream(avctx, NULL)))
|
||||
return AVERROR(ENOMEM);
|
||||
av_set_pts_info(st, 64, 1, 1000000); /* 64 bits pts in microseconds */
|
||||
|
||||
|
||||
@@ -229,7 +229,7 @@ static int audio_read_header(AVFormatContext *context, AVFormatParameters *param
|
||||
if ((test = start_jack(context)))
|
||||
return test;
|
||||
|
||||
stream = av_new_stream(context, 0);
|
||||
stream = avformat_new_stream(context, NULL);
|
||||
if (!stream) {
|
||||
stop_jack(self);
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
@@ -53,7 +53,7 @@ static av_cold int read_header(AVFormatContext *ctx, AVFormatParameters *ap)
|
||||
int ret, i;
|
||||
char *err = NULL;
|
||||
|
||||
if (!(st = av_new_stream(ctx, 0)))
|
||||
if (!(st = avformat_new_stream(ctx, NULL)))
|
||||
return AVERROR(ENOMEM);
|
||||
s->drive = cdio_cddap_identify(ctx->filename, CDDA_MESSAGE_LOGIT, &err);
|
||||
if (!s->drive) {
|
||||
|
||||
@@ -160,7 +160,7 @@ static inline int dc1394_read_common(AVFormatContext *c, AVFormatParameters *ap,
|
||||
}
|
||||
|
||||
/* create a video stream */
|
||||
vst = av_new_stream(c, 0);
|
||||
vst = avformat_new_stream(c, NULL);
|
||||
if (!vst) {
|
||||
ret = AVERROR(ENOMEM);
|
||||
goto out;
|
||||
|
||||
@@ -209,7 +209,7 @@ static int audio_read_header(AVFormatContext *s1, AVFormatParameters *ap)
|
||||
AVStream *st;
|
||||
int ret;
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st) {
|
||||
return AVERROR(ENOMEM);
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ static av_cold int audio_read_header(AVFormatContext *s1,
|
||||
AVStream *st;
|
||||
int ret;
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@ static int grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
|
||||
s->video_win.width = ap->width;
|
||||
s->video_win.height = ap->height;
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st)
|
||||
return AVERROR(ENOMEM);
|
||||
av_set_pts_info(st, 64, 1, 1000000); /* 64 bits pts in us */
|
||||
|
||||
@@ -580,7 +580,7 @@ static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap)
|
||||
enum CodecID codec_id;
|
||||
enum PixelFormat pix_fmt = PIX_FMT_NONE;
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st) {
|
||||
res = AVERROR(ENOMEM);
|
||||
goto out;
|
||||
|
||||
@@ -295,7 +295,7 @@ static int vfw_read_header(AVFormatContext *s, AVFormatParameters *ap)
|
||||
|
||||
SetWindowLongPtr(ctx->hwnd, GWLP_USERDATA, (LONG_PTR) s);
|
||||
|
||||
st = av_new_stream(s, 0);
|
||||
st = avformat_new_stream(s, NULL);
|
||||
if(!st) {
|
||||
vfw_read_close(s);
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
@@ -193,7 +193,7 @@ x11grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
|
||||
goto out;
|
||||
}
|
||||
|
||||
st = av_new_stream(s1, 0);
|
||||
st = avformat_new_stream(s1, NULL);
|
||||
if (!st) {
|
||||
ret = AVERROR(ENOMEM);
|
||||
goto out;
|
||||
|
||||
Reference in New Issue
Block a user