[FFmpeg-cvslog] flashsvenc: merge two consecutive if-conditions
Diego Biurrun
git at videolan.org
Sat Jul 16 19:49:07 CEST 2011
ffmpeg | branch: master | Diego Biurrun <diego at biurrun.de> | Fri Jul 15 15:28:43 2011 +0200| [59ef6bded5d01e4debf08dc65cfd4a088652759b] | committer: Diego Biurrun
flashsvenc: merge two consecutive if-conditions
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=59ef6bded5d01e4debf08dc65cfd4a088652759b
---
libavcodec/flashsvenc.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/libavcodec/flashsvenc.c b/libavcodec/flashsvenc.c
index ec70b72..7082040 100644
--- a/libavcodec/flashsvenc.c
+++ b/libavcodec/flashsvenc.c
@@ -230,10 +230,9 @@ static int flashsv_encode_frame(AVCodecContext *avctx, uint8_t *buf,
pfptr = s->previous_frame;
/* Check the placement of keyframes */
- if (avctx->gop_size > 0) {
- if (avctx->frame_number >= s->last_key_frame + avctx->gop_size) {
- I_frame = 1;
- }
+ if (avctx->gop_size > 0 &&
+ avctx->frame_number >= s->last_key_frame + avctx->gop_size) {
+ I_frame = 1;
}
if (buf_size < s->image_width * s->image_height * 3) {
More information about the ffmpeg-cvslog
mailing list