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

Unified Diff: gpu/config/gpu_info_collector.cc

Issue 1998723002: Move code in ui/gl/* from gfx:: to gl:: (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gpu/command_buffer/tests/gl_unittests_android.cc ('k') | gpu/config/gpu_info_collector_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/config/gpu_info_collector.cc
diff --git a/gpu/config/gpu_info_collector.cc b/gpu/config/gpu_info_collector.cc
index e07379c8dda326cccda49f5f80e3ac31e6f25ef2..dcb907b48abb0ff4a4685fd2c0f382e26cad2a17 100644
--- a/gpu/config/gpu_info_collector.cc
+++ b/gpu/config/gpu_info_collector.cc
@@ -28,27 +28,27 @@
namespace {
-scoped_refptr<gfx::GLSurface> InitializeGLSurface() {
- scoped_refptr<gfx::GLSurface> surface(
+scoped_refptr<gl::GLSurface> InitializeGLSurface() {
+ scoped_refptr<gl::GLSurface> surface(
gl::init::CreateOffscreenGLSurface(gfx::Size()));
if (!surface.get()) {
- LOG(ERROR) << "gfx::GLContext::CreateOffscreenGLSurface failed";
+ LOG(ERROR) << "gl::GLContext::CreateOffscreenGLSurface failed";
return NULL;
}
return surface;
}
-scoped_refptr<gfx::GLContext> InitializeGLContext(gfx::GLSurface* surface) {
- scoped_refptr<gfx::GLContext> context(
- gl::init::CreateGLContext(nullptr, surface, gfx::PreferIntegratedGpu));
+scoped_refptr<gl::GLContext> InitializeGLContext(gl::GLSurface* surface) {
+ scoped_refptr<gl::GLContext> context(
+ gl::init::CreateGLContext(nullptr, surface, gl::PreferIntegratedGpu));
if (!context.get()) {
LOG(ERROR) << "gl::init::CreateGLContext failed";
return NULL;
}
if (!context->MakeCurrent(surface)) {
- LOG(ERROR) << "gfx::GLContext::MakeCurrent() failed";
+ LOG(ERROR) << "gl::GLContext::MakeCurrent() failed";
return NULL;
}
@@ -101,15 +101,15 @@ namespace gpu {
CollectInfoResult CollectGraphicsInfoGL(GPUInfo* gpu_info) {
TRACE_EVENT0("startup", "gpu_info_collector::CollectGraphicsInfoGL");
- DCHECK_NE(gfx::GetGLImplementation(), gfx::kGLImplementationNone);
+ DCHECK_NE(gl::GetGLImplementation(), gl::kGLImplementationNone);
- scoped_refptr<gfx::GLSurface> surface(InitializeGLSurface());
+ scoped_refptr<gl::GLSurface> surface(InitializeGLSurface());
if (!surface.get()) {
LOG(ERROR) << "Could not create surface for info collection.";
return kCollectInfoFatalFailure;
}
- scoped_refptr<gfx::GLContext> context(InitializeGLContext(surface.get()));
+ scoped_refptr<gl::GLContext> context(InitializeGLContext(surface.get()));
if (!context.get()) {
LOG(ERROR) << "Could not create context for info collection.";
return kCollectInfoFatalFailure;
@@ -133,12 +133,12 @@ CollectInfoResult CollectGraphicsInfoGL(GPUInfo* gpu_info) {
command_line->GetSwitchValueASCII(switches::kGpuTestingGLVersion);
}
- gpu_info->gl_extensions = gfx::GetGLExtensionsFromCurrentContext();
+ gpu_info->gl_extensions = gl::GetGLExtensionsFromCurrentContext();
std::string glsl_version_string = GetGLString(GL_SHADING_LANGUAGE_VERSION);
- gfx::GLVersionInfo gl_info(gpu_info->gl_version.c_str(),
- gpu_info->gl_renderer.c_str(),
- gpu_info->gl_extensions.c_str());
+ gl::GLVersionInfo gl_info(gpu_info->gl_version.c_str(),
+ gpu_info->gl_renderer.c_str(),
+ gpu_info->gl_extensions.c_str());
GLint max_samples = 0;
if (gl_info.IsAtLeastGL(3, 0) || gl_info.IsAtLeastGLES(3, 0) ||
gpu_info->gl_extensions.find("GL_ANGLE_framebuffer_multisample") !=
@@ -156,7 +156,7 @@ CollectInfoResult CollectGraphicsInfoGL(GPUInfo* gpu_info) {
gpu_info->max_msaa_samples = base::IntToString(max_samples);
UMA_HISTOGRAM_SPARSE_SLOWLY("GPU.MaxMSAASampleCount", max_samples);
- gfx::GLWindowSystemBindingInfo window_system_binding_info;
+ gl::GLWindowSystemBindingInfo window_system_binding_info;
if (GetGLWindowSystemBindingInfo(&window_system_binding_info)) {
gpu_info->gl_ws_vendor = window_system_binding_info.vendor;
gpu_info->gl_ws_version = window_system_binding_info.version;
« no previous file with comments | « gpu/command_buffer/tests/gl_unittests_android.cc ('k') | gpu/config/gpu_info_collector_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698