Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(540)

Side by Side Diff: gpu/khronos_glcts_support/native/egl_native_windowless.cc

Issue 1714883002: command_buffer_gles2: Implement EGL default Display as a global object (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@command_buffer_gles2-multiple-contexts
Patch Set: rebase Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gpu/gpu.gyp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Using egl_native from gles2_conform_support 5 // Using egl_native from gles2_conform_support
6 // TODO: We may want to phase out the old gles2_conform support in preference 6 // TODO: We may want to phase out the old gles2_conform support in preference
7 // of this implementation. So eventually we'll need to move the egl_native 7 // of this implementation. So eventually we'll need to move the egl_native
8 // stuff here or to a shareable location/path. 8 // stuff here or to a shareable location/path.
9 #include "gpu/gles2_conform_support/egl/display.h" 9 #include "gpu/gles2_conform_support/egl/test_support.h"
10 10
11 #include "third_party/khronos_glcts/framework/egl/tcuEglPlatform.hpp" 11 #include "third_party/khronos_glcts/framework/egl/tcuEglPlatform.hpp"
12 12
13 namespace egl { 13 namespace egl {
14 namespace native { 14 namespace native {
15 namespace windowless { 15 namespace windowless {
16 16
17 class Surface : public tcu::egl::WindowSurface { 17 class Surface : public tcu::egl::WindowSurface {
18 public: 18 public:
19 Surface(tcu::egl::Display& display, 19 Surface(tcu::egl::Display& display,
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 67
68 ~Platform() override {} 68 ~Platform() override {}
69 69
70 tcu::NativeWindow* createWindow(tcu::NativeDisplay& dpy, 70 tcu::NativeWindow* createWindow(tcu::NativeDisplay& dpy,
71 EGLConfig config, 71 EGLConfig config,
72 const EGLint* attribList, 72 const EGLint* attribList,
73 int width, 73 int width,
74 int height, 74 int height,
75 qpVisibility visibility) override { 75 qpVisibility visibility) override {
76 tcu::egl::Display& eglDisplay = dpy.getEglDisplay(); 76 tcu::egl::Display& eglDisplay = dpy.getEglDisplay();
77 egl::Display* display = 77 EGLDisplay display = eglDisplay.getEGLDisplay();
78 static_cast<egl::Display*>(eglDisplay.getEGLDisplay()); 78 CommandBufferGLESSetNextCreateWindowSurfaceCreatesPBuffer(display, width,
79 display->SetCreateOffscreen(width, height); 79 height);
80 return new Window(eglDisplay, config, attribList, width, height); 80 return new Window(eglDisplay, config, attribList, width, height);
81 } 81 }
82 }; 82 };
83 83
84 } // namespace windowless 84 } // namespace windowless
85 } // namespace native 85 } // namespace native
86 } // namespace egl 86 } // namespace egl
87 87
88 tcu::Platform* createPlatform(void) { 88 tcu::Platform* createPlatform(void) {
89 return new egl::native::windowless::Platform(); 89 return new egl::native::windowless::Platform();
90 } 90 }
OLDNEW
« no previous file with comments | « gpu/gpu.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698