[FFmpeg-devel] [PATCH] play aiff without common tag
Mon Jun 25 19:22:38 CEST 2007
On Mon, Jun 25, 2007 at 06:34:20PM +0200, Michel Bardiaux wrote:
> Baptiste Coudurier wrote:
> > Hi Reimar,
> > Reimar D?ffinger wrote:
> >> Hello,
> >> attached patch fixes
> >> http://samples.mplayerhq.hu/AIFF/invalid_nocommon.aiff.
> >> While according to the specification says this file invalid I think it
> >> is preferable to support it anyway, esp. because leaving values
> >> uninitialized and even causing a division by zero is really bad anyway
> >> (and it even leaves e.g. MPlayer thinking this is a video file...).
> > Division by zero must be fixed of course.
> >> @@ -312,6 +305,11 @@
> >> st = av_new_stream(s, 0);
> >> if (!st)
> >> return AVERROR_NOMEM;
> >> + st->codec->codec_type = CODEC_TYPE_AUDIO;
> >> + st->codec->codec_id = CODEC_ID_PCM_S16BE;
> >> + st->codec->bits_per_sample = 16;
> >> + st->codec->sample_rate = 11025;
> >> + st->codec->channels = 2;
> > Humm, what do we do if a file containing PCM_S24BE, 4 channels at 48khz
> > miss COMM chunk ?
> > I would be more in favor of returning -1 and saying the file is broken
> > here, there is not much we can do to workaround.
> And even if it was possible to reliably guess properties of a broken
> file, that should never be done silently. An av_log(AV_LOG_ERROR) seems
> the minimum necessary. ffmpeg is inscrutable enough as it is!
ive no objections to a warning about the file being broken ...
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Breaking DRM is a little like attempting to break through a door even
though the window is wide open and the only thing in the house is a bunch
of things you dont want and which you would get tomorrow for free anyway
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the ffmpeg-devel