Revision 67c1a59a libavcodec/fraps.c
libavcodec/fraps.c | ||
---|---|---|
274 | 274 |
for(i = 0; i < planes; i++){ |
275 | 275 |
is_chroma = !!i; |
276 | 276 |
av_fast_malloc(&s->tmpbuf, &s->tmpbuf_size, offs[i + 1] - offs[i] - 1024 + FF_INPUT_BUFFER_PADDING_SIZE); |
277 |
if (!s->tmpbuf) |
|
278 |
return AVERROR(ENOMEM); |
|
277 | 279 |
if(fraps2_decode_plane(s, f->data[i], f->linesize[i], avctx->width >> is_chroma, |
278 | 280 |
avctx->height >> is_chroma, buf + offs[i], offs[i + 1] - offs[i], is_chroma, 1) < 0) { |
279 | 281 |
av_log(avctx, AV_LOG_ERROR, "Error decoding plane %i\n", i); |
... | ... | |
316 | 318 |
offs[planes] = buf_size; |
317 | 319 |
for(i = 0; i < planes; i++){ |
318 | 320 |
av_fast_malloc(&s->tmpbuf, &s->tmpbuf_size, offs[i + 1] - offs[i] - 1024 + FF_INPUT_BUFFER_PADDING_SIZE); |
321 |
if (!s->tmpbuf) |
|
322 |
return AVERROR(ENOMEM); |
|
319 | 323 |
if(fraps2_decode_plane(s, f->data[0] + i + (f->linesize[0] * (avctx->height - 1)), -f->linesize[0], |
320 | 324 |
avctx->width, avctx->height, buf + offs[i], offs[i + 1] - offs[i], 0, 3) < 0) { |
321 | 325 |
av_log(avctx, AV_LOG_ERROR, "Error decoding plane %i\n", i); |
Also available in: Unified diff