Trigger framelisteners even on frames dropped by the FPS reduction by default.

Modification affects EglRenderer on Android. Moves frame dropping to the
renderer thread. Frame listeners are triggered even when FPS reduction is
active unless applyFpsReduction is set to true.

BUG=webrtc:7149

Review-Url: https://codereview.webrtc.org/2688843002
Cr-Commit-Position: refs/heads/master@{#17206}
This commit is contained in:
sakal
2017-03-13 05:11:48 -07:00
committed by Commit bot
parent 7be1dcb98e
commit d15165222f
4 changed files with 117 additions and 73 deletions

View File

@ -307,4 +307,15 @@ public class EglRendererTest {
// Check the frame listener hasn't triggered.
assertFalse(testFrameListener.waitForBitmap(RENDER_WAIT_MS));
}
@Test
@SmallTest
public void testFrameListenersWhilePaused() throws Exception {
// Test that frame listeners receive frames while renderer is paused.
eglRenderer.pauseVideo();
eglRenderer.addFrameListener(testFrameListener, 1f /* scaleFactor */);
feedFrame(0);
assertTrue(testFrameListener.waitForBitmap(RENDER_WAIT_MS));
checkBitmapContent(testFrameListener.resetAndGetBitmap(), 0);
}
}