Browse Source

Remove useless casts.

Patch by avcoder ffmpeg at gmail d0t com

Originally committed as revision 14153 to svn://svn.ffmpeg.org/ffmpeg/trunk
tags/v0.5
avcoder Benoit Fouet 17 years ago
parent
commit
24909d3983
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      libavcodec/pngenc.c

+ 3
- 3
libavcodec/pngenc.c View File

@@ -232,7 +232,7 @@ static int png_write_row(PNGEncContext *s, const uint8_t *data, int size)
static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, void *data){ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, void *data){
PNGEncContext *s = avctx->priv_data; PNGEncContext *s = avctx->priv_data;
AVFrame *pict = data; AVFrame *pict = data;
AVFrame * const p= (AVFrame*)&s->picture;
AVFrame * const p= &s->picture;
int bit_depth, color_type, y, len, row_size, ret, is_progressive; int bit_depth, color_type, y, len, row_size, ret, is_progressive;
int bits_per_pixel, pass_row_size; int bits_per_pixel, pass_row_size;
int compression_level; int compression_level;
@@ -425,8 +425,8 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size,
static av_cold int png_enc_init(AVCodecContext *avctx){ static av_cold int png_enc_init(AVCodecContext *avctx){
PNGEncContext *s = avctx->priv_data; PNGEncContext *s = avctx->priv_data;


avcodec_get_frame_defaults((AVFrame*)&s->picture);
avctx->coded_frame= (AVFrame*)&s->picture;
avcodec_get_frame_defaults(&s->picture);
avctx->coded_frame= &s->picture;
dsputil_init(&s->dsp, avctx); dsputil_init(&s->dsp, avctx);


s->filter_type = av_clip(avctx->prediction_method, PNG_FILTER_VALUE_NONE, PNG_FILTER_VALUE_MIXED); s->filter_type = av_clip(avctx->prediction_method, PNG_FILTER_VALUE_NONE, PNG_FILTER_VALUE_MIXED);


Loading…
Cancel
Save