[FFmpeg-devel] [PATCH][RFC] Lagarith Decoder.
Diego Biurrun
diego
Fri Aug 21 10:11:13 CEST 2009
On Thu, Aug 20, 2009 at 11:45:53PM -0600, Nathan Caldwell wrote:
>
> --- /dev/null
> +++ libavcodec/lagarith.c
> @@ -0,0 +1,512 @@
> +
> +typedef struct LagarithContext {
> + AVCodecContext *avctx;
> + AVFrame picture;
> + int zeros; /*!< Number of consecutave zero bytes encountered. */
> + int zeros_rem; /*!< Number of zero bytes remaining to output. */
The comments are not sentences as they lack a verb, so lowercase and
drop the period.
> +static uint8_t lag_calc_zero_run(int8_t x)
> +{
> +#if 0
> + x <<= 1;
> + if (x > 255)
> + return ~x;
> + return x;
> +#endif
> + return (x << 1) ^ (x >> 7);
Please decide the fate of the '#if 0' code block, but don't add more
cruft, we have plenty already.
> + l = *left;
> + lt = *left_top;
align
> + *left = l;
> + *left_top = lt;
ditto
> +/**
> +* decode a frame
Capitalize, add period.
> + .long_name = NULL_IF_CONFIG_SMALL("Lagarith"),
You call it "lossless" everywhere else..
Diego
More information about the ffmpeg-devel
mailing list