[FFmpeg-devel] [Toy] Aura 1 and 2 decoder
Kostya
kostya.shishkov
Mon Mar 16 13:33:13 CET 2009
On Mon, Mar 16, 2009 at 07:24:58AM -0600, compn wrote:
> On Mon, 16 Mar 2009 09:32:59 +0200, Kostya wrote:
> >+ /* sanity check the buffer size: A buffer has 3x16-bytes tables
> >+ * followed by (height) lines each with 3 bytes to represent groups
> >+ * of 4 pixels. Thus, the total size of the buffer ought to be:
> >+ * (3 * 16) + height * (width * 3 / 4) */
> >+ if (buf_size != 48 + s->height * s->width) {
> >+ av_log(avctx, AV_LOG_ERROR, "ffmpeg: cyuv: got a buffer with %d bytes when %d were expected\n",
> >+ buf_size,
> >+ 48 + s->height * s->width);
> >+ return -1;
> >+ }
>
> is it a good idea to quit if something unexpected comes along?
current policy is to try hard at interpreting it but this is rather old code
> btw i created a cyuv file which throws this error:
> http://samples.mplayerhq.hu/V-codecs/CYUV.AVI
>
> [cyuv @ 00E10540]ffmpeg: cyuv: got a buffer with 153600 bytes when
> 57648 were expected
> Error while decoding frame!
>
> not sure if its a valid file. created with ms vfw 1.1
Will check. Looks like it's either delta YUV422 (like aura2) or UYVY.
> -compn
More information about the ffmpeg-devel
mailing list