Mercurial > libavcodec.hg
diff libschroedingerenc.c @ 10055:fdb318d12314 libavcodec
Simplify 'if' condition statements.
Drop useless '!= 0' from 'exp != 0', replace 'exp == 0' by '!exp'.
author | diego |
---|---|
date | Sat, 15 Aug 2009 11:02:50 +0000 |
parents | 1045a26cb90d |
children | 646065f63290 |
line wrap: on
line diff
--- a/libschroedingerenc.c Sat Aug 15 09:12:58 2009 +0000 +++ b/libschroedingerenc.c Sat Aug 15 11:02:50 2009 +0000 @@ -145,7 +145,7 @@ avccontext->coded_frame = &p_schro_params->picture; - if (avccontext->gop_size == 0){ + if (!avccontext->gop_size) { schro_encoder_setting_set_double (p_schro_params->encoder, "gop_structure", SCHRO_ENCODER_GOP_INTRA_ONLY); @@ -164,7 +164,7 @@ /* FIXME - Need to handle SCHRO_ENCODER_RATE_CONTROL_LOW_DELAY. */ if (avccontext->flags & CODEC_FLAG_QSCALE) { - if (avccontext->global_quality == 0) { + if (!avccontext->global_quality) { /* lossless coding */ schro_encoder_setting_set_double (p_schro_params->encoder, "rate_control", @@ -366,7 +366,7 @@ p_frame_output = ff_dirac_schro_queue_pop (&p_schro_params->enc_frame_queue); - if (p_frame_output == NULL) + if (!p_frame_output) return 0; memcpy(frame, p_frame_output->p_encbuf, p_frame_output->size);