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

Unified Diff: gpu/gles2_conform_support/native/egl_native_x11.cc

Issue 2196923002: Make ash::DisplayMode more like ui::DisplayMode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more tests fixed Created 4 years, 4 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
Index: gpu/gles2_conform_support/native/egl_native_x11.cc
diff --git a/gpu/gles2_conform_support/native/egl_native_x11.cc b/gpu/gles2_conform_support/native/egl_native_x11.cc
index 7e4c4236259072ba15a4a539884e6cab1df3677e..2c1d8090699a2579a5709754b2aaf68f6fb11b87 100644
--- a/gpu/gles2_conform_support/native/egl_native_x11.cc
+++ b/gpu/gles2_conform_support/native/egl_native_x11.cc
@@ -25,30 +25,23 @@ EGLImageKHR GTFCreateEGLImage(int width, int height,
};
if (format != GL_RGBA && format != GL_RGB)
- return static_cast<EGLImageKHR>(NULL);
+ return static_cast<EGLImageKHR>(nullptr);
oshima 2016/08/02 19:44:57 unrelated changes?
rjkroege 2016/08/04 00:12:05 yes. pulled out into different CL.
if (type != GL_UNSIGNED_BYTE)
- return static_cast<EGLImageKHR>(NULL);
+ return static_cast<EGLImageKHR>(nullptr);
GLuint texture;
glGenTextures(1, &texture);
glBindTexture(GL_TEXTURE_2D, texture);
- glTexImage2D(GL_TEXTURE_2D,
- 0,
- format,
- width,
- height,
- 0,
- format,
- type,
- NULL);
+ glTexImage2D(GL_TEXTURE_2D, 0, format, width, height, 0, format, type,
+ nullptr);
// Disable mip-maps because we do not require it.
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
if(glGetError() != GL_NO_ERROR)
- return static_cast<EGLImageKHR>(NULL);
+ return static_cast<EGLImageKHR>(nullptr);
EGLImageKHR egl_image =
egl_create_image_khr_(eglGetCurrentDisplay(),
@@ -60,7 +53,7 @@ EGLImageKHR GTFCreateEGLImage(int width, int height,
if (eglGetError() == EGL_SUCCESS)
return egl_image;
else
- return static_cast<EGLImageKHR>(NULL);
+ return static_cast<EGLImageKHR>(nullptr);
}
void GTFDestroyEGLImage(EGLImageKHR image) {

Powered by Google App Engine
This is Rietveld 408576698