Mercurial > libavcodec.hg
comparison zmbv.c @ 4827:b3ee9a1526b0 libavcodec
Get rid of unnecessary pointer casts.
patch by Nicholas Tung, ntung ntung com
author | diego |
---|---|
date | Sun, 08 Apr 2007 20:24:16 +0000 |
parents | 59f4fb490fa7 |
children | f99e40a7155b |
comparison
equal
deleted
inserted
replaced
4826:9ca9a53a848b | 4827:b3ee9a1526b0 |
---|---|
397 return 0; | 397 return 0; |
398 } | 398 } |
399 | 399 |
400 static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, uint8_t *buf, int buf_size) | 400 static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, uint8_t *buf, int buf_size) |
401 { | 401 { |
402 ZmbvContext * const c = (ZmbvContext *)avctx->priv_data; | 402 ZmbvContext * const c = avctx->priv_data; |
403 uint8_t *outptr; | 403 uint8_t *outptr; |
404 #ifdef CONFIG_ZLIB | 404 #ifdef CONFIG_ZLIB |
405 int zret = Z_OK; // Zlib return code | 405 int zret = Z_OK; // Zlib return code |
406 #endif | 406 #endif |
407 int len = buf_size; | 407 int len = buf_size; |
606 * Init zmbv decoder | 606 * Init zmbv decoder |
607 * | 607 * |
608 */ | 608 */ |
609 static int decode_init(AVCodecContext *avctx) | 609 static int decode_init(AVCodecContext *avctx) |
610 { | 610 { |
611 ZmbvContext * const c = (ZmbvContext *)avctx->priv_data; | 611 ZmbvContext * const c = avctx->priv_data; |
612 int zret; // Zlib return code | 612 int zret; // Zlib return code |
613 | 613 |
614 c->avctx = avctx; | 614 c->avctx = avctx; |
615 | 615 |
616 c->pic.data[0] = NULL; | 616 c->pic.data[0] = NULL; |
661 * Uninit zmbv decoder | 661 * Uninit zmbv decoder |
662 * | 662 * |
663 */ | 663 */ |
664 static int decode_end(AVCodecContext *avctx) | 664 static int decode_end(AVCodecContext *avctx) |
665 { | 665 { |
666 ZmbvContext * const c = (ZmbvContext *)avctx->priv_data; | 666 ZmbvContext * const c = avctx->priv_data; |
667 | 667 |
668 av_freep(&c->decomp_buf); | 668 av_freep(&c->decomp_buf); |
669 | 669 |
670 if (c->pic.data[0]) | 670 if (c->pic.data[0]) |
671 avctx->release_buffer(avctx, &c->pic); | 671 avctx->release_buffer(avctx, &c->pic); |