diff options
author | Andy McFadden <fadden@android.com> | 2013-08-16 14:55:39 -0700 |
---|---|---|
committer | Andy McFadden <fadden@android.com> | 2013-08-16 15:15:16 -0700 |
commit | 3c25621ad7d13f64d3ab95a27fa970fbc9998f73 (patch) | |
tree | 2115e7f38faf3ac66c885f9be003d2fc1082220a /services/surfaceflinger/DisplayHardware | |
parent | a33b62cc4700c68a3481d415a55e1a7b688981e1 (diff) | |
download | frameworks_native-3c25621ad7d13f64d3ab95a27fa970fbc9998f73.zip frameworks_native-3c25621ad7d13f64d3ab95a27fa970fbc9998f73.tar.gz frameworks_native-3c25621ad7d13f64d3ab95a27fa970fbc9998f73.tar.bz2 |
Re-enable frame dropping for non-auto timestamps
This change adds an entire field to note whether the timestamp was
auto-generated by Surface or supplied by the application.
The value is used when deciding whether or not to drop frames based
on buffer presentation timestamps. If a desired presentation time
was set explicitly, BufferQueue will use that value to decide if a
frame should be dropped. If the timestamp was generated by Surface
at the time the buffer was queued, the timestamp is ignored.
Bug 10151804
Change-Id: Ibd571a7578351063b813cbdad2ddbeed70655ba5
Diffstat (limited to 'services/surfaceflinger/DisplayHardware')
-rw-r--r-- | services/surfaceflinger/DisplayHardware/VirtualDisplaySurface.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/services/surfaceflinger/DisplayHardware/VirtualDisplaySurface.cpp b/services/surfaceflinger/DisplayHardware/VirtualDisplaySurface.cpp index 30b0084..89c87c7 100644 --- a/services/surfaceflinger/DisplayHardware/VirtualDisplaySurface.cpp +++ b/services/surfaceflinger/DisplayHardware/VirtualDisplaySurface.cpp @@ -185,7 +185,7 @@ void VirtualDisplaySurface::onFrameCommitted() { sp<Fence> outFence = mHwc.getLastRetireFence(mDisplayId); VDS_LOGV("onFrameCommitted: queue sink sslot=%d", sslot); status_t result = mSource[SOURCE_SINK]->queueBuffer(sslot, - QueueBufferInput(systemTime(), + QueueBufferInput(systemTime(), false, Rect(mSinkBufferWidth, mSinkBufferHeight), NATIVE_WINDOW_SCALING_MODE_FREEZE, 0, false, outFence), &qbo); @@ -309,12 +309,13 @@ status_t VirtualDisplaySurface::queueBuffer(int pslot, // Extract the GLES release fence for HWC to acquire int64_t timestamp; + bool isAutoTimestamp; Rect crop; int scalingMode; uint32_t transform; bool async; - input.deflate(×tamp, &crop, &scalingMode, &transform, - &async, &mFbFence); + input.deflate(×tamp, &isAutoTimestamp, &crop, &scalingMode, + &transform, &async, &mFbFence); mFbProducerSlot = pslot; } |