[FFmpeg-devel] [PATCH] RoQ audio encoder
Michael Niedermayer
michaelni
Sun May 6 20:42:41 CEST 2007
Hi
On Sun, May 06, 2007 at 12:35:04PM +0200, Vitor wrote:
> See previous message.
[...]
> +static void roq_dpcm_table_init()
> +{
> + unsigned short i;
why not int?
[...]
> +}
> +
> +
> +static unsigned char dpcm_predict(short *previous, short current)
the number of spaces between functions seems somewhet random, i think
it would be better if it where consistant
[...]
> +
> + bytestream_put_byte(&out, ((stereo) ? 0x21 : 0x20));
superflous ()
> + samples = avctx->frame_size;
> + for (i=0; i<samples; i++)
> + for (ch=0; ch<avctx->channels; ch++)
> + *out++ = dpcm_predict(&context->lastSample[ch], *in++);
the indention depth is inconsistent, its 4 spaces everywhere in the file
but just 2 here
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Its not that you shouldnt use gotos but rather that you should write
readable code and code with gotos often but not always is less readable
-------------- 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/20070506/a153372d/attachment.pgp>
More information about the ffmpeg-devel
mailing list