diff options
author | Gabriel Dume <gabriel.ddx84@gmail.com> | 2014-08-15 00:31:24 +0400 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2014-08-15 14:18:18 +0400 |
commit | f929ab0569ff31ed5a59b0b0adb7ce09df3fca39 (patch) | |
tree | 5b93402fb37cc43b899451a5d2b65bfc03d7887b /libavcodec/mpegvideo_enc.c | |
parent | efd26bedec9a345a5960dbfcbaec888418f2d4e6 (diff) |
cosmetics: Write NULL pointer equality checks more compactly
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Diffstat (limited to 'libavcodec/mpegvideo_enc.c')
-rw-r--r-- | libavcodec/mpegvideo_enc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c index fd84deb584..380eff67da 100644 --- a/libavcodec/mpegvideo_enc.c +++ b/libavcodec/mpegvideo_enc.c @@ -1221,9 +1221,9 @@ static int select_input_picture(MpegEncContext *s) s->reordered_input_picture[MAX_PICTURE_COUNT - 1] = NULL; /* set next picture type & ordering */ - if (s->reordered_input_picture[0] == NULL && s->input_picture[0]) { + if (!s->reordered_input_picture[0] && s->input_picture[0]) { if (/*s->picture_in_gop_number >= s->gop_size ||*/ - s->next_picture_ptr == NULL || s->intra_only) { + !s->next_picture_ptr || s->intra_only) { s->reordered_input_picture[0] = s->input_picture[0]; s->reordered_input_picture[0]->f->pict_type = AV_PICTURE_TYPE_I; s->reordered_input_picture[0]->f->coded_picture_number = @@ -1276,7 +1276,7 @@ static int select_input_picture(MpegEncContext *s) } } for (i = 0; i < s->max_b_frames + 1; i++) { - if (s->input_picture[i] == NULL || + if (!s->input_picture[i] || s->input_picture[i]->b_frame_score - 1 > s->mb_num / s->avctx->b_sensitivity) break; |