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

Unified Diff: client/deps/glbench/src/glx_stuff.cc

Issue 1315007: Added tearing tests for plain texture updates and bind pixmap to texture. (Closed)
Patch Set: Created 10 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « client/deps/glbench/src/glx_stuff.h ('k') | client/deps/glbench/src/teartest.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/deps/glbench/src/glx_stuff.cc
diff --git a/client/deps/glbench/src/glx_stuff.cc b/client/deps/glbench/src/glx_stuff.cc
index b6186d82e232826422591d39410f700f6374e6a7..89a1e04d7f379bfecd2f026f0838a60314f222e7 100644
--- a/client/deps/glbench/src/glx_stuff.cc
+++ b/client/deps/glbench/src/glx_stuff.cc
@@ -9,8 +9,8 @@
#include "main.h"
#include "xlib_window.h"
-static GLXContext glx_context = NULL;
-static GLXFBConfig glx_fbconfig = NULL;
+GLXContext g_glx_context = NULL;
+GLXFBConfig g_glx_fbconfig = NULL;
#define F(fun, type) type fun = NULL;
LIST_PROC_FUNCTIONS(F)
@@ -22,7 +22,7 @@ bool Init() {
}
XVisualInfo* GetXVisual() {
- if (!glx_fbconfig) {
+ if (!g_glx_fbconfig) {
int screen = DefaultScreen(g_xlib_display);
int attrib[] = {
GLX_DOUBLEBUFFER, True,
@@ -38,21 +38,21 @@ XVisualInfo* GetXVisual() {
GLXFBConfig *fbconfigs = glXChooseFBConfig(g_xlib_display, screen,
attrib, &nelements);
CHECK(nelements >= 1);
- glx_fbconfig = fbconfigs[0];
+ g_glx_fbconfig = fbconfigs[0];
XFree(fbconfigs);
}
- return glXGetVisualFromFBConfig(g_xlib_display, glx_fbconfig);
+ return glXGetVisualFromFBConfig(g_xlib_display, g_glx_fbconfig);
}
bool InitContext() {
- glx_context = glXCreateNewContext(g_xlib_display, glx_fbconfig,
+ g_glx_context = glXCreateNewContext(g_xlib_display, g_glx_fbconfig,
GLX_RGBA_TYPE, 0, True);
- if (!glx_context)
+ if (!g_glx_context)
return false;
- if (!glXMakeCurrent(g_xlib_display, g_xlib_window, glx_context)) {
- glXDestroyContext(g_xlib_display, glx_context);
+ if (!glXMakeCurrent(g_xlib_display, g_xlib_window, g_glx_context)) {
+ glXDestroyContext(g_xlib_display, g_glx_context);
return false;
}
@@ -82,7 +82,7 @@ bool InitContext() {
void DestroyContext() {
glXMakeCurrent(g_xlib_display, 0, NULL);
- glXDestroyContext(g_xlib_display, glx_context);
+ glXDestroyContext(g_xlib_display, g_glx_context);
}
void SwapBuffers() {
« no previous file with comments | « client/deps/glbench/src/glx_stuff.h ('k') | client/deps/glbench/src/teartest.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698