Skip to content

Commit

Permalink
lavf: remove AVFormatParameters from AVFormatContext.read_header sign…
Browse files Browse the repository at this point in the history
…ature
  • Loading branch information
elenril committed Jan 27, 2012
1 parent 3b4aaa6 commit 6e9651d
Show file tree
Hide file tree
Showing 129 changed files with 147 additions and 202 deletions.
3 changes: 1 addition & 2 deletions libavdevice/alsa-audio-dec.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@

#include "alsa-audio.h"

static av_cold int audio_read_header(AVFormatContext *s1,
AVFormatParameters *ap)
static av_cold int audio_read_header(AVFormatContext *s1)
{
AlsaData *s = s1->priv_data;
AVStream *st;
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/bktr.c
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ static int grab_read_packet(AVFormatContext *s1, AVPacket *pkt)
return video_buf_size;
}

static int grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
static int grab_read_header(AVFormatContext *s1)
{
VideoData *s = s1->priv_data;
AVStream *st;
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/dv1394.c
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ static int dv1394_start(struct dv1394_data *dv)
return 0;
}

static int dv1394_read_header(AVFormatContext * context, AVFormatParameters * ap)
static int dv1394_read_header(AVFormatContext * context)
{
struct dv1394_data *dv = context->priv_data;

Expand Down
3 changes: 1 addition & 2 deletions libavdevice/fbdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,7 @@ typedef struct {
uint8_t *data; ///< framebuffer data
} FBDevContext;

av_cold static int fbdev_read_header(AVFormatContext *avctx,
AVFormatParameters *ap)
av_cold static int fbdev_read_header(AVFormatContext *avctx)
{
FBDevContext *fbdev = avctx->priv_data;
AVStream *st = NULL;
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/jack_audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ static void stop_jack(JackData *self)
ff_timefilter_destroy(self->timefilter);
}

static int audio_read_header(AVFormatContext *context, AVFormatParameters *params)
static int audio_read_header(AVFormatContext *context)
{
JackData *self = context->priv_data;
AVStream *stream;
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/libcdio.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ typedef struct CDIOContext {
int paranoia_mode;
} CDIOContext;

static av_cold int read_header(AVFormatContext *ctx, AVFormatParameters *ap)
static av_cold int read_header(AVFormatContext *ctx)
{
CDIOContext *s = ctx->priv_data;
AVStream *st;
Expand Down
10 changes: 5 additions & 5 deletions libavdevice/libdc1394.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ static const AVClass libdc1394_class = {
};


static inline int dc1394_read_common(AVFormatContext *c, AVFormatParameters *ap,
static inline int dc1394_read_common(AVFormatContext *c,
struct dc1394_frame_format **select_fmt, struct dc1394_frame_rate **select_fps)
{
dc1394_data* dc1394 = c->priv_data;
Expand Down Expand Up @@ -191,7 +191,7 @@ static inline int dc1394_read_common(AVFormatContext *c, AVFormatParameters *ap,
}

#if HAVE_LIBDC1394_1
static int dc1394_v1_read_header(AVFormatContext *c, AVFormatParameters * ap)
static int dc1394_v1_read_header(AVFormatContext *c)
{
dc1394_data* dc1394 = c->priv_data;
AVStream* vst;
Expand All @@ -200,7 +200,7 @@ static int dc1394_v1_read_header(AVFormatContext *c, AVFormatParameters * ap)
struct dc1394_frame_format *fmt = NULL;
struct dc1394_frame_rate *fps = NULL;

if (dc1394_read_common(c,ap,&fmt,&fps) != 0)
if (dc1394_read_common(c, &fmt, &fps) != 0)
return -1;

/* Now let us prep the hardware. */
Expand Down Expand Up @@ -285,15 +285,15 @@ static int dc1394_v1_close(AVFormatContext * context)
}

#elif HAVE_LIBDC1394_2
static int dc1394_v2_read_header(AVFormatContext *c, AVFormatParameters * ap)
static int dc1394_v2_read_header(AVFormatContext *c)
{
dc1394_data* dc1394 = c->priv_data;
dc1394camera_list_t *list;
int res, i;
struct dc1394_frame_format *fmt = NULL;
struct dc1394_frame_rate *fps = NULL;

if (dc1394_read_common(c,ap,&fmt,&fps) != 0)
if (dc1394_read_common(c, &fmt, &fps) != 0)
return -1;

/* Now let us prep the hardware. */
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/oss_audio.c
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ static int audio_write_trailer(AVFormatContext *s1)

/* grab support */

static int audio_read_header(AVFormatContext *s1, AVFormatParameters *ap)
static int audio_read_header(AVFormatContext *s1)
{
AudioData *s = s1->priv_data;
AVStream *st;
Expand Down
3 changes: 1 addition & 2 deletions libavdevice/pulse.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@ static pa_sample_format_t codec_id_to_pulse_format(int codec_id) {
}
}

static av_cold int pulse_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static av_cold int pulse_read_header(AVFormatContext *s)
{
PulseData *pd = s->priv_data;
AVStream *st;
Expand Down
3 changes: 1 addition & 2 deletions libavdevice/sndio_dec.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@

#include "sndio_common.h"

static av_cold int audio_read_header(AVFormatContext *s1,
AVFormatParameters *ap)
static av_cold int audio_read_header(AVFormatContext *s1)
{
SndioData *s = s1->priv_data;
AVStream *st;
Expand Down
6 changes: 3 additions & 3 deletions libavdevice/v4l2.c
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ static void mmap_close(struct video_data *s)
av_free(s->buf_len);
}

static int v4l2_set_parameters(AVFormatContext *s1, AVFormatParameters *ap)
static int v4l2_set_parameters(AVFormatContext *s1)
{
struct video_data *s = s1->priv_data;
struct v4l2_input input = { 0 };
Expand Down Expand Up @@ -678,7 +678,7 @@ static uint32_t device_try_init(AVFormatContext *s1,
return desired_format;
}

static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap)
static int v4l2_read_header(AVFormatContext *s1)
{
struct video_data *s = s1->priv_data;
AVStream *st;
Expand Down Expand Up @@ -766,7 +766,7 @@ static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap)

s->frame_format = desired_format;

if ((res = v4l2_set_parameters(s1, ap) < 0))
if ((res = v4l2_set_parameters(s1) < 0))
goto out;

st->codec->pix_fmt = fmt_v4l2ff(desired_format, codec_id);
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/vfwcap.c
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ static int vfw_read_close(AVFormatContext *s)
return 0;
}

static int vfw_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int vfw_read_header(AVFormatContext *s)
{
struct vfw_ctx *ctx = s->priv_data;
AVCodecContext *codec;
Expand Down
2 changes: 1 addition & 1 deletion libavdevice/x11grab.c
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ x11grab_region_win_init(struct x11_grab *s)
* </ul>
*/
static int
x11grab_read_header(AVFormatContext *s1, AVFormatParameters *ap)
x11grab_read_header(AVFormatContext *s1)
{
struct x11_grab *x11grab = s1->priv_data;
Display *dpy;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/4xm.c
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,7 @@ static int fourxm_probe(AVProbeData *p)
return AVPROBE_SCORE_MAX;
}

static int fourxm_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int fourxm_read_header(AVFormatContext *s)
{
AVIOContext *pb = s->pb;
unsigned int fourcc_tag;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/aacdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,7 @@ static int adts_aac_probe(AVProbeData *p)
else return 0;
}

static int adts_aac_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int adts_aac_read_header(AVFormatContext *s)
{
AVStream *st;

Expand Down
2 changes: 1 addition & 1 deletion libavformat/adxdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ static int adx_read_packet(AVFormatContext *s, AVPacket *pkt)
return 0;
}

static int adx_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int adx_read_header(AVFormatContext *s)
{
ADXDemuxerContext *c = s->priv_data;
AVCodecContext *avctx;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/aea.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,7 @@ static int aea_read_probe(AVProbeData *p)
return 0;
}

static int aea_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int aea_read_header(AVFormatContext *s)
{
AVStream *st = avformat_new_stream(s, NULL);
if (!st)
Expand Down
3 changes: 1 addition & 2 deletions libavformat/aiffdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,8 +174,7 @@ static int aiff_probe(AVProbeData *p)
}

/* aiff input */
static int aiff_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int aiff_read_header(AVFormatContext *s)
{
int size, filesize;
int64_t offset = 0;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/amr.c
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ static int amr_probe(AVProbeData *p)
}

/* amr input */
static int amr_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int amr_read_header(AVFormatContext *s)
{
AVIOContext *pb = s->pb;
AVStream *st;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/anm.c
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ static int find_record(const AnmDemuxContext *anm, int record)
return AVERROR_INVALIDDATA;
}

static int read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int read_header(AVFormatContext *s)
{
AnmDemuxContext *anm = s->priv_data;
AVIOContext *pb = s->pb;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/apc.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ static int apc_probe(AVProbeData *p)
return 0;
}

static int apc_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int apc_read_header(AVFormatContext *s)
{
AVIOContext *pb = s->pb;
AVStream *st;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/ape.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ static void ape_dumpinfo(AVFormatContext * s, APEContext * ape_ctx)
#endif
}

static int ape_read_header(AVFormatContext * s, AVFormatParameters * ap)
static int ape_read_header(AVFormatContext * s)
{
AVIOContext *pb = s->pb;
APEContext *ape = s->priv_data;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/applehttp.c
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ static int read_data(void *opaque, uint8_t *buf, int buf_size)
goto restart;
}

static int applehttp_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int applehttp_read_header(AVFormatContext *s)
{
AppleHTTPContext *c = s->priv_data;
int ret = 0, i, j, stream_offset = 0;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/asfdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@ static int asf_read_marker(AVFormatContext *s, int64_t size)
return 0;
}

static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int asf_read_header(AVFormatContext *s)
{
ASFContext *asf = s->priv_data;
ff_asf_guid g;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/assdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,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;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/au.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,7 @@ static int au_probe(AVProbeData *p)
}

/* au input */
static int au_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int au_read_header(AVFormatContext *s)
{
int size;
unsigned int tag;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/avformat.h
Original file line number Diff line number Diff line change
Expand Up @@ -491,8 +491,7 @@ typedef struct AVInputFormat {
* additional parameters. Only used in raw format right
* now. 'av_new_stream' should be called to create new streams.
*/
int (*read_header)(struct AVFormatContext *,
AVFormatParameters *ap);
int (*read_header)(struct AVFormatContext *);

/**
* Read one packet and put it in 'pkt'. pts and flags are also
Expand Down
2 changes: 1 addition & 1 deletion libavformat/avidec.c
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ static void avi_read_nikon(AVFormatContext *s, uint64_t end)
}
}

static int avi_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int avi_read_header(AVFormatContext *s)
{
AVIContext *avi = s->priv_data;
AVIOContext *pb = s->pb;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/avisynth.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ typedef struct {
int next_stream;
} AVISynthContext;

static int avisynth_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int avisynth_read_header(AVFormatContext *s)
{
AVISynthContext *avs = s->priv_data;
HRESULT res;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/avs.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ static int avs_probe(AVProbeData * p)
return 0;
}

static int avs_read_header(AVFormatContext * s, AVFormatParameters * ap)
static int avs_read_header(AVFormatContext * s)
{
AvsFormat *avs = s->priv_data;

Expand Down
3 changes: 1 addition & 2 deletions libavformat/bethsoftvid.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,7 @@ static int vid_probe(AVProbeData *p)
return AVPROBE_SCORE_MAX;
}

static int vid_read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int vid_read_header(AVFormatContext *s)
{
BVID_DemuxContext *vid = s->priv_data;
AVIOContext *pb = s->pb;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/bfi.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ static int bfi_probe(AVProbeData * p)
return 0;
}

static int bfi_read_header(AVFormatContext * s, AVFormatParameters * ap)
static int bfi_read_header(AVFormatContext * s)
{
BFIContext *bfi = s->priv_data;
AVIOContext *pb = s->pb;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/bink.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ static int probe(AVProbeData *p)
return 0;
}

static int read_header(AVFormatContext *s, AVFormatParameters *ap)
static int read_header(AVFormatContext *s)
{
BinkDemuxContext *bink = s->priv_data;
AVIOContext *pb = s->pb;
Expand Down
2 changes: 1 addition & 1 deletion libavformat/bmv.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ typedef struct BMVContext {
int64_t audio_pos;
} BMVContext;

static int bmv_read_header(AVFormatContext *s, AVFormatParameters *ap)
static int bmv_read_header(AVFormatContext *s)
{
AVStream *st, *ast;
BMVContext *c = s->priv_data;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/c93.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,7 @@ static int probe(AVProbeData *p)
return AVPROBE_SCORE_MAX;
}

static int read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int read_header(AVFormatContext *s)
{
AVStream *video;
AVIOContext *pb = s->pb;
Expand Down
3 changes: 1 addition & 2 deletions libavformat/cafdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,7 @@ static void read_info_chunk(AVFormatContext *s, int64_t size)
}
}

static int read_header(AVFormatContext *s,
AVFormatParameters *ap)
static int read_header(AVFormatContext *s)
{
AVIOContext *pb = s->pb;
CaffContext *caf = s->priv_data;
Expand Down
Loading

0 comments on commit 6e9651d

Please sign in to comment.