[Ffmpeg-devel] Possible bug in bmp decoder

Alex Beregszaszi alex
Mon Jan 29 14:12:30 CET 2007


Hi,

> ...
>      switch(depth){
>      case 24:
>          for(i = 0; i < avctx->height; i++){
>              memcpy(ptr, buf, n);
>              buf += n;
>              ptr += linesize;
>          }
>          break;
> ...
> 
> Should it not be memcpy(ptr, buf, linesize) ?

n probably means input linesize, while linesize is the output linesize.
I guess 24bit BMP doesnt stores the padding 1 byte.

--
Alex






More information about the ffmpeg-devel mailing list