Mercurial > libavcodec.hg
comparison zmbvenc.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 | 255affa5bae7 |
children | f99e40a7155b |
comparison
equal
deleted
inserted
replaced
4826:9ca9a53a848b | 4827:b3ee9a1526b0 |
---|---|
104 return bv; | 104 return bv; |
105 } | 105 } |
106 | 106 |
107 static int encode_frame(AVCodecContext *avctx, uint8_t *buf, int buf_size, void *data) | 107 static int encode_frame(AVCodecContext *avctx, uint8_t *buf, int buf_size, void *data) |
108 { | 108 { |
109 ZmbvEncContext * const c = (ZmbvEncContext *)avctx->priv_data; | 109 ZmbvEncContext * const c = avctx->priv_data; |
110 AVFrame *pict = data; | 110 AVFrame *pict = data; |
111 AVFrame * const p = &c->pic; | 111 AVFrame * const p = &c->pic; |
112 uint8_t *src, *prev; | 112 uint8_t *src, *prev; |
113 uint32_t *palptr; | 113 uint32_t *palptr; |
114 int zret = Z_OK; | 114 int zret = Z_OK; |
237 /** | 237 /** |
238 * Init zmbv encoder | 238 * Init zmbv encoder |
239 */ | 239 */ |
240 static int encode_init(AVCodecContext *avctx) | 240 static int encode_init(AVCodecContext *avctx) |
241 { | 241 { |
242 ZmbvEncContext * const c = (ZmbvEncContext *)avctx->priv_data; | 242 ZmbvEncContext * const c = avctx->priv_data; |
243 int zret; // Zlib return code | 243 int zret; // Zlib return code |
244 int lvl = 9; | 244 int lvl = 9; |
245 | 245 |
246 c->avctx = avctx; | 246 c->avctx = avctx; |
247 | 247 |
303 /** | 303 /** |
304 * Uninit zmbv encoder | 304 * Uninit zmbv encoder |
305 */ | 305 */ |
306 static int encode_end(AVCodecContext *avctx) | 306 static int encode_end(AVCodecContext *avctx) |
307 { | 307 { |
308 ZmbvEncContext * const c = (ZmbvEncContext *)avctx->priv_data; | 308 ZmbvEncContext * const c = avctx->priv_data; |
309 | 309 |
310 av_freep(&c->comp_buf); | 310 av_freep(&c->comp_buf); |
311 av_freep(&c->work_buf); | 311 av_freep(&c->work_buf); |
312 | 312 |
313 deflateEnd(&(c->zstream)); | 313 deflateEnd(&(c->zstream)); |