From 6780a2d6a5351977a793c08935bd3492c9942494 Mon Sep 17 00:00:00 2001 From: Dan Stoza Date: Thu, 13 Mar 2014 11:31:43 -0700 Subject: [PATCH] Remove deprecated BufferQueue constructor Bug: 13415624 Change-Id: I1c17833511b5961af5a9bbb9cc3d627ce558d424 --- cmds/flatland/GLHelper.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cmds/flatland/GLHelper.cpp b/cmds/flatland/GLHelper.cpp index 42694b3236..01fa9eec0d 100644 --- a/cmds/flatland/GLHelper.cpp +++ b/cmds/flatland/GLHelper.cpp @@ -201,14 +201,16 @@ bool GLHelper::getShaderProgram(const char* name, GLuint* outPgm) { bool GLHelper::createNamedSurfaceTexture(GLuint name, uint32_t w, uint32_t h, sp* glConsumer, EGLSurface* surface) { - sp bq = new BufferQueue(mGraphicBufferAlloc); - sp glc = new GLConsumer(bq, name, + sp producer; + sp consumer; + BufferQueue::createBufferQueue(&producer, &consumer, mGraphicBufferAlloc); + sp glc = new GLConsumer(consumer, name, GL_TEXTURE_EXTERNAL_OES, false); glc->setDefaultBufferSize(w, h); glc->setDefaultMaxBufferCount(3); glc->setConsumerUsageBits(GRALLOC_USAGE_HW_COMPOSER); - sp anw = new Surface(bq); + sp anw = new Surface(producer); EGLSurface s = eglCreateWindowSurface(mDisplay, mConfig, anw.get(), NULL); if (s == EGL_NO_SURFACE) { fprintf(stderr, "eglCreateWindowSurface error: %#x\n", eglGetError()); -- 2.11.0