summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorJamie Gennis <jgennis@google.com>2012-08-24 17:25:13 -0700
committerJamie Gennis <jgennis@google.com>2012-08-29 15:35:34 -0700
commit31a353da225af5329735451c761b430d82dfda1b (patch)
tree8fa7940f99fd7e80f13bcc58840456f48fcd9178 /services
parentc1396dd14506d29e92fc047141d62b3d9246a72d (diff)
downloadframeworks_native-31a353da225af5329735451c761b430d82dfda1b.zip
frameworks_native-31a353da225af5329735451c761b430d82dfda1b.tar.gz
frameworks_native-31a353da225af5329735451c761b430d82dfda1b.tar.bz2
BufferQueue: clean up buffer counting
This change is a clean up of some of the handling of the maximum number of buffers that are allowed at once. It mostly renames a few member variables and methods, but it includes a couple small refactorings. Change-Id: I9959310f563d09583548d4291e1050a7bbc7d87d
Diffstat (limited to 'services')
-rw-r--r--services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp2
-rw-r--r--services/surfaceflinger/Layer.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp b/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp
index 6d33592..d601fca 100644
--- a/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp
+++ b/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp
@@ -93,7 +93,7 @@ FramebufferSurface::FramebufferSurface():
mBufferQueue->setDefaultBufferFormat(fbDev->format);
mBufferQueue->setDefaultBufferSize(fbDev->width, fbDev->height);
mBufferQueue->setSynchronousMode(true);
- mBufferQueue->setBufferCountServer(NUM_FRAME_BUFFERS);
+ mBufferQueue->setDefaultMaxBufferCount(NUM_FRAME_BUFFERS);
} else {
ALOGE("Couldn't get gralloc module");
}
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index 4c82f91..ea1bc54 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -104,9 +104,9 @@ void Layer::onFirstRef()
#ifdef TARGET_DISABLE_TRIPLE_BUFFERING
#warning "disabling triple buffering"
- mSurfaceTexture->setBufferCountServer(2);
+ mSurfaceTexture->setDefaultMaxBufferCount(2);
#else
- mSurfaceTexture->setBufferCountServer(3);
+ mSurfaceTexture->setDefaultMaxBufferCount(3);
#endif
}