[FFmpeg-devel] [PATCH 3/8] sbc: add raw demuxer for SBC
Aurelien Jacobs
aurel at gnuage.org
Mon Dec 18 03:02:23 EET 2017
On Mon, Dec 18, 2017 at 12:19:06AM +0100, Carl Eugen Hoyos wrote:
> 2017-12-17 22:47 GMT+01:00 Aurelien Jacobs <aurel at gnuage.org>:
>
> > +#if CONFIG_SBC_DEMUXER
> > +AVInputFormat ff_sbc_demuxer = {
> > + .name = "sbc",
> > + .long_name = NULL_IF_CONFIG_SMALL("raw SBC (low-complexity subband codec)"),
> > + .extensions = "sbc",
> > + .raw_codec_id = AV_CODEC_ID_SBC,
> > + .read_header = ff_raw_audio_read_header,
> > + .read_packet = ff_raw_read_partial_packet,
> > + .flags = AVFMT_GENERIC_INDEX,
> > +};
> > +#endif
> > +
> > +#if CONFIG_MSBC_DEMUXER
> > +AVInputFormat ff_msbc_demuxer = {
> > + .name = "msbc",
> > + .long_name = NULL_IF_CONFIG_SMALL("raw mSBC (wideband speech mono SBC)"),
> > + .extensions = "msbc",
> > + .raw_codec_id = AV_CODEC_ID_MSBC,
> > + .read_header = ff_raw_audio_read_header,
> > + .read_packet = ff_raw_read_partial_packet,
> > + .flags = AVFMT_GENERIC_INDEX,
> > +};
>
> If auto-detection is impossible, this could be moved into
> libavformat/rawdec.c.
I'm not really fond of this, but OK.
> > +#endif
> > diff --git a/libavformat/utils.c b/libavformat/utils.c
> > index 84e49208b8..860fbc30c9 100644
> > --- a/libavformat/utils.c
> > +++ b/libavformat/utils.c
> > @@ -336,6 +336,7 @@ static int set_codec_from_probe_data(AVFormatContext *s, AVStream *st,
> > { "mjpeg_2000",AV_CODEC_ID_JPEG2000, AVMEDIA_TYPE_VIDEO },
> > { "mp3", AV_CODEC_ID_MP3, AVMEDIA_TYPE_AUDIO },
> > { "mpegvideo", AV_CODEC_ID_MPEG2VIDEO, AVMEDIA_TYPE_VIDEO },
>
> > + { "sbc", AV_CODEC_ID_SBC, AVMEDIA_TYPE_AUDIO },
>
> I believe this line should not be added.
Indeed, this is not needed anymore.
Here is an updated patch.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-sbc-add-raw-demuxer-for-SBC.patch
Type: text/x-diff
Size: 3699 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20171218/0c21e306/attachment.patch>
More information about the ffmpeg-devel
mailing list