summaryrefslogtreecommitdiff
path: root/vp8/encoder/onyx_if.c
diff options
context:
space:
mode:
authorJohn Koleszar <jkoleszar@google.com>2011-08-27 00:05:05 -0400
committerJohn Koleszar <jkoleszar@google.com>2011-08-27 00:05:05 -0400
commitce59a150a6e10a76489b6ca5bb3b7d58195d9326 (patch)
tree89f7addc0dcb3596e5d311e1c42cbc1c85c882a2 /vp8/encoder/onyx_if.c
parenta358375c6dfc4a5a27a79a1c9b1480ad7a78415d (diff)
parent1f20202e2c6c137dd2e3464e2b14bba0fdc289ce (diff)
downloadlibvpx-ce59a150a6e10a76489b6ca5bb3b7d58195d9326.tar
libvpx-ce59a150a6e10a76489b6ca5bb3b7d58195d9326.tar.gz
libvpx-ce59a150a6e10a76489b6ca5bb3b7d58195d9326.tar.bz2
libvpx-ce59a150a6e10a76489b6ca5bb3b7d58195d9326.zip
Merge remote branch 'internal/upstream' into HEAD
Diffstat (limited to 'vp8/encoder/onyx_if.c')
-rw-r--r--vp8/encoder/onyx_if.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/vp8/encoder/onyx_if.c b/vp8/encoder/onyx_if.c
index b5e6f8704..e2fd622f3 100644
--- a/vp8/encoder/onyx_if.c
+++ b/vp8/encoder/onyx_if.c
@@ -3385,16 +3385,17 @@ static void encode_frame_to_data_rate
cpi->mb.e_mbd.update_mb_segmentation_map = 1;
#endif
-#if CONFIG_REALTIME_ONLY
- if(cpi->oxcf.auto_key && cm->frame_type != KEY_FRAME)
+ if (cpi->compressor_speed == 2)
{
- if(cpi->force_next_frame_intra)
+ if(cpi->oxcf.auto_key && cm->frame_type != KEY_FRAME)
{
- cm->frame_type = KEY_FRAME; /* delayed intra frame */
+ if(cpi->force_next_frame_intra)
+ {
+ cm->frame_type = KEY_FRAME; /* delayed intra frame */
+ }
}
+ cpi->force_next_frame_intra = 0;
}
- cpi->force_next_frame_intra = 0;
-#endif
// For an alt ref frame in 2 pass we skip the call to the second pass function that sets the target bandwidth
#if !(CONFIG_REALTIME_ONLY)
@@ -3934,15 +3935,15 @@ static void encode_frame_to_data_rate
// (assuming that we didn't)!
if (cpi->pass != 2 && cpi->oxcf.auto_key && cm->frame_type != KEY_FRAME)
{
+ int key_frame_decision = decide_key_frame(cpi);
-#if CONFIG_REALTIME_ONLY
+ if (cpi->compressor_speed == 2)
{
/* we don't do re-encoding in realtime mode
* if key frame is decided than we force it on next frame */
- cpi->force_next_frame_intra = decide_key_frame(cpi);
+ cpi->force_next_frame_intra = key_frame_decision;
}
-#else
- if (decide_key_frame(cpi))
+ else if (key_frame_decision)
{
// Reset all our sizing numbers and recode
cm->frame_type = KEY_FRAME;
@@ -3979,7 +3980,6 @@ static void encode_frame_to_data_rate
continue;
}
-#endif
}
vp8_clear_system_state();