[FFmpeg-devel] [PATCH] Some cleanups for libavcodec/alac.c
Vitor Sessak
vitor1001
Tue Jul 10 15:34:06 CEST 2007
Hi
Michael Niedermayer wrote:
> Hi
>
> On Tue, Jul 10, 2007 at 05:54:01AM +0200, Vitor Sessak wrote:
> [...]
>> > i think its safer to check the validity of setinfo_max_samples_per_frame
>>> before storing it into the struct
>>> also *ptr++ looks fine to me
>> I also like *ptr++, but I think to mix with bytestream_get_be?? it is
>> slightly less clear than bytestream_put_byte. But I'm not radical about
>> that. New patch attached.
>
> i prefer *ptr++ as it also forces the reader to realize that bytestream_*
> does nothing else then read/write and increase ...
Ok, patch attached. As I said, I'm not radical about it.
>>>> - /* 2^result = something to do with output waiting.
>>>> - * perhaps matters if we read > 1 frame in a pass?
>>>> - */
>>>> - get_bits(&alac->gb, 4);
>>>>
>>>> - get_bits(&alac->gb, 12); /* unknown, skip 12 bits */
>>>> - hassize = get_bits(&alac->gb, 1); /* the output sample size is
>>> stored soon */
>>>> - wasted_bytes = get_bits(&alac->gb, 2); /* unknown ? */
>>>> + /* 2^result = something to do with output waiting.
>>>> + * perhaps matters if we read > 1 frame in a pass?
>>>> + */
>>>> + get_bits(&alac->gb, 4);
>>>> + get_bits(&alac->gb, 12); /* unknown, skip 12 bits */
>>>> + /* the output sample size is stored soon */
>>>> + hassize = get_bits(&alac->gb, 1);
>>>>
>>>> + wasted_bytes = get_bits(&alac->gb, 2); /* unknown ? */
>>> cosmetic
>> Sorry, I thought that "don't mix cosmetical with functional" didn't
>> apply when it would break indentation. Fixed in new patch.
>
> ok
Applied.
-Vitor
-------------- next part --------------
A non-text attachment was scrubbed...
Name: alac1_3.diff
Type: text/x-patch
Size: 1543 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070710/0482aabb/attachment.bin>
More information about the ffmpeg-devel
mailing list