comparison tscc.c @ 7823:4525dcd81357 libavcodec

Bump Major version, this commit is almost just renaming bits_per_sample to bits_per_coded_sample but that cannot be done seperately. Patch by Luca Abeni Also reset the minor version and fix the forgotton change to libfaad. Note: The API/ABI should not be considered stable yet, there still may be a change done here or there if some developer has some cleanup ideas and patches!
author michael
date Mon, 08 Sep 2008 14:24:59 +0000
parents e943e1409077
children f874e1d5cf07
comparison
equal deleted inserted replaced
7822:67cfe4983e6d 7823:4525dcd81357
272 memset(&(c->zstream), 0, sizeof(z_stream)); 272 memset(&(c->zstream), 0, sizeof(z_stream));
273 #else 273 #else
274 av_log(avctx, AV_LOG_ERROR, "Zlib support not compiled.\n"); 274 av_log(avctx, AV_LOG_ERROR, "Zlib support not compiled.\n");
275 return 1; 275 return 1;
276 #endif 276 #endif
277 switch(avctx->bits_per_sample){ 277 switch(avctx->bits_per_coded_sample){
278 case 8: avctx->pix_fmt = PIX_FMT_PAL8; break; 278 case 8: avctx->pix_fmt = PIX_FMT_PAL8; break;
279 case 16: avctx->pix_fmt = PIX_FMT_RGB555; break; 279 case 16: avctx->pix_fmt = PIX_FMT_RGB555; break;
280 case 24: 280 case 24:
281 avctx->pix_fmt = PIX_FMT_BGR24; 281 avctx->pix_fmt = PIX_FMT_BGR24;
282 break; 282 break;
283 case 32: avctx->pix_fmt = PIX_FMT_RGB32; break; 283 case 32: avctx->pix_fmt = PIX_FMT_RGB32; break;
284 default: av_log(avctx, AV_LOG_ERROR, "Camtasia error: unknown depth %i bpp\n", avctx->bits_per_sample); 284 default: av_log(avctx, AV_LOG_ERROR, "Camtasia error: unknown depth %i bpp\n", avctx->bits_per_coded_sample);
285 return -1; 285 return -1;
286 } 286 }
287 c->bpp = avctx->bits_per_sample; 287 c->bpp = avctx->bits_per_coded_sample;
288 c->decomp_size = (avctx->width * c->bpp + (avctx->width + 254) / 255 + 2) * avctx->height + 2;//RLE in the 'best' case 288 c->decomp_size = (avctx->width * c->bpp + (avctx->width + 254) / 255 + 2) * avctx->height + 2;//RLE in the 'best' case
289 289
290 /* Allocate decompression buffer */ 290 /* Allocate decompression buffer */
291 if (c->decomp_size) { 291 if (c->decomp_size) {
292 if ((c->decomp_buf = av_malloc(c->decomp_size)) == NULL) { 292 if ((c->decomp_buf = av_malloc(c->decomp_size)) == NULL) {