[FFmpeg-devel] [PATCH] Bugfix: decoding 8- and 24-bit FLAC files
Michael Niedermayer
michaelni
Thu Jun 14 11:28:38 CEST 2007
Hi
On Thu, Jun 14, 2007 at 09:49:48AM +0200, Benoit Fouet wrote:
> Michael Niedermayer wrote:
> > Hi
> >
> > On Tue, Jun 12, 2007 at 11:54:40AM +0200, Benoit Fouet wrote:
> >
> >> M?ns Rullg?rd wrote:
> >>
> >>> Benoit Fouet wrote:
> >>>
> >>>
> >>>> Hi,
> >>>>
> >>>> Michael Donaghy wrote:
> >>>>
> >>>>
> >>>>> Index: libavcodec/flac.c
> >>>>> ===================================================================
> >>>>> --- libavcodec/flac.c (revision 9283)
> >>>>> +++ libavcodec/flac.c (working copy)
> >>>>> @@ -684,8 +673,8 @@
> >>>>> {\
> >>>>> int a= s->decoded[0][i];\
> >>>>> int b= s->decoded[1][i];\
> >>>>> - *(samples++) = (left ) >> (16 - s->bps);\
> >>>>> - *(samples++) = (right) >> (16 - s->bps);\
> >>>>> + *(samples++) = (left << (24 - s->bps)) >> 8;\
> >>>>> + *(samples++) = (right << (24 - s->bps)) >> 8;\
> >>>>>
> >>>>>
> >>>>>
> >>>> i think this code lacks paretheses
> >>>>
> >>>>
> >>> I think it has too many.
> >>>
> >>>
> >>>
> >> ok, what i'd write would be:
> >> *samples++ = ((left) << 24 - s->bps) >> 8;\
> >>
> >> is that ok ?
> >>
> >
> > iam fine with it though maybe we should keep the one around 24 - s->bps
> > but thats just a slight personal preferance ...
> >
>
> i'm not sure whether i had to send the patch or not...
> so here it is
just commit just trvial things directly
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I am the wisest man alive, for I know one thing, and that is that I know
nothing. -- Socrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070614/b3c47a7b/attachment.pgp>
More information about the ffmpeg-devel
mailing list