summaryrefslogtreecommitdiffstats
path: root/gpu/command_buffer/service/gpu_processor_linux.cc
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-14 21:45:58 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-14 21:45:58 +0000
commit2f2d704a4fbee7cf83f30be7f668c7c793a08b54 (patch)
tree5cf551615bde20fe3dd7481a52447b316d5f8b15 /gpu/command_buffer/service/gpu_processor_linux.cc
parent37c841918d0604e5589e2c35eb6a48f5c33feec4 (diff)
downloadchromium_src-2f2d704a4fbee7cf83f30be7f668c7c793a08b54.zip
chromium_src-2f2d704a4fbee7cf83f30be7f668c7c793a08b54.tar.gz
chromium_src-2f2d704a4fbee7cf83f30be7f668c7c793a08b54.tar.bz2
Clear GL contexts and frame buffers after creation and resizing.
Also added a new "default" context so command decoders have a GL context they can rely on the state of. TEST=trybots, verified that buffers were clear. BUG=none Review URL: http://codereview.chromium.org/1593018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44544 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/command_buffer/service/gpu_processor_linux.cc')
-rw-r--r--gpu/command_buffer/service/gpu_processor_linux.cc10
1 files changed, 2 insertions, 8 deletions
diff --git a/gpu/command_buffer/service/gpu_processor_linux.cc b/gpu/command_buffer/service/gpu_processor_linux.cc
index 4217b72..aae4d7b 100644
--- a/gpu/command_buffer/service/gpu_processor_linux.cc
+++ b/gpu/command_buffer/service/gpu_processor_linux.cc
@@ -2,12 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#if !defined(UNIT_TEST)
-#include <gdk/gdkx.h>
-#else
-#define GDK_DISPLAY() NULL
-#endif
-
#include "gpu/command_buffer/service/gl_context.h"
#include "gpu/command_buffer/service/gpu_processor.h"
@@ -36,7 +30,7 @@ bool GPUProcessor::Initialize(gfx::PluginWindowHandle window,
// Create either a view or pbuffer based GLContext.
if (window) {
- scoped_ptr<ViewGLContext> context(new ViewGLContext(GDK_DISPLAY(), window));
+ scoped_ptr<ViewGLContext> context(new ViewGLContext(window));
// TODO(apatrick): support multisampling.
if (!context->Initialize(false)) {
Destroy();
@@ -44,7 +38,7 @@ bool GPUProcessor::Initialize(gfx::PluginWindowHandle window,
}
context_.reset(context.release());
} else {
- scoped_ptr<PbufferGLContext> context(new PbufferGLContext(GDK_DISPLAY()));
+ scoped_ptr<PbufferGLContext> context(new PbufferGLContext());
if (!context->Initialize(parent_context)) {
Destroy();
return false;