Mercurial > libavcodec.hg
comparison cscd.c @ 4290:e7dfc2743e26 libavcodec
Fix 16 bit cscd samples, 16 bit raw means RGB555 on Windows, and the original
cscd codec is for windows.
author | reimar |
---|---|
date | Sat, 09 Dec 2006 13:30:28 +0000 |
parents | b2a291ea653f |
children | ce643a22f049 |
comparison
equal
deleted
inserted
replaced
4289:b2a291ea653f | 4290:e7dfc2743e26 |
---|---|
218 if (avcodec_check_dimensions(avctx, avctx->height, avctx->width) < 0) { | 218 if (avcodec_check_dimensions(avctx, avctx->height, avctx->width) < 0) { |
219 return 1; | 219 return 1; |
220 } | 220 } |
221 avctx->has_b_frames = 0; | 221 avctx->has_b_frames = 0; |
222 switch (avctx->bits_per_sample) { | 222 switch (avctx->bits_per_sample) { |
223 case 16: avctx->pix_fmt = PIX_FMT_RGB565; break; | 223 case 16: avctx->pix_fmt = PIX_FMT_RGB555; break; |
224 case 24: avctx->pix_fmt = PIX_FMT_BGR24; break; | 224 case 24: avctx->pix_fmt = PIX_FMT_BGR24; break; |
225 case 32: avctx->pix_fmt = PIX_FMT_RGBA32; break; | 225 case 32: avctx->pix_fmt = PIX_FMT_RGBA32; break; |
226 default: | 226 default: |
227 av_log(avctx, AV_LOG_ERROR, | 227 av_log(avctx, AV_LOG_ERROR, |
228 "CamStudio codec error: invalid depth %i bpp\n", | 228 "CamStudio codec error: invalid depth %i bpp\n", |