summaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorJamie Gennis <jgennis@google.com>2011-06-26 18:27:47 -0700
committerJamie Gennis <jgennis@google.com>2011-06-27 15:45:39 -0700
commitbd5404d0312752e7c8946e8540129f0d2d97bcd7 (patch)
treeabdb05720d7149f0adee32a0f4ae9712cb57d78e /graphics
parent932e4e613987658383e23fa151c3f5b87d07f028 (diff)
downloadframeworks_base-bd5404d0312752e7c8946e8540129f0d2d97bcd7.zip
frameworks_base-bd5404d0312752e7c8946e8540129f0d2d97bcd7.tar.gz
frameworks_base-bd5404d0312752e7c8946e8540129f0d2d97bcd7.tar.bz2
SurfaceTexture: change onFrameAvailable behavior
This change alters the conditions under which the onFrameAvailable callback gets called by the C++ SurfaceTexture class. The new behavior is to call the callback whenever a frame gets queued that will be visible to the buffer consumer. This means that buffers queued in synchronous mode always trigger the callback, as those buffers will remain pending until they are consumed. Buffers queued in asynchronous mode will only trigger the callback if there was not previously an unconsumed buffer pending. The new behavior means that a consumer should perform a draw operation exactly once for every onFrameAvailable call that it recieves. This change also modifies SurfaceFlinger and the SurfaceTexture JNI to support of the new behavior. Change-Id: I8b2c6e00961d3d58b11c6af50b555b6e4c5f5b40
Diffstat (limited to 'graphics')
-rw-r--r--graphics/java/android/graphics/SurfaceTexture.java4
1 files changed, 0 insertions, 4 deletions
diff --git a/graphics/java/android/graphics/SurfaceTexture.java b/graphics/java/android/graphics/SurfaceTexture.java
index adb6eac..90a7ac2 100644
--- a/graphics/java/android/graphics/SurfaceTexture.java
+++ b/graphics/java/android/graphics/SurfaceTexture.java
@@ -144,10 +144,6 @@ public class SurfaceTexture {
*/
public void updateTexImage() {
nativeUpdateTexImage();
- if (nativeGetQueuedCount() > 0) {
- Message m = mEventHandler.obtainMessage();
- mEventHandler.sendMessage(m);
- }
}
/**