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

Side by Side Diff: gpu/config/gpu_info_collector_win.cc

Issue 817653003: Update from https://crrev.com/309717 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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/config/gpu_info_collector_linux.cc ('k') | gpu/config/gpu_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "gpu/config/gpu_info_collector.h" 5 #include "gpu/config/gpu_info_collector.h"
6 6
7 // This has to be included before windows.h. 7 // This has to be included before windows.h.
8 #include "third_party/re2/re2/re2.h" 8 #include "third_party/re2/re2/re2.h"
9 9
10 #include <windows.h> 10 #include <windows.h>
(...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after
459 } 459 }
460 SetupDiDestroyDeviceInfoList(device_info); 460 SetupDiDestroyDeviceInfoList(device_info);
461 return found ? kCollectInfoSuccess : kCollectInfoNonFatalFailure; 461 return found ? kCollectInfoSuccess : kCollectInfoNonFatalFailure;
462 } 462 }
463 463
464 CollectInfoResult CollectContextGraphicsInfo(GPUInfo* gpu_info) { 464 CollectInfoResult CollectContextGraphicsInfo(GPUInfo* gpu_info) {
465 TRACE_EVENT0("gpu", "CollectGraphicsInfo"); 465 TRACE_EVENT0("gpu", "CollectGraphicsInfo");
466 466
467 DCHECK(gpu_info); 467 DCHECK(gpu_info);
468 468
469 if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kUseGL)) { 469 if (base::CommandLine::ForCurrentProcess()->HasSwitch(switches::kUseGL)) {
470 std::string requested_implementation_name = 470 std::string requested_implementation_name =
471 CommandLine::ForCurrentProcess()->GetSwitchValueASCII(switches::kUseGL); 471 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
472 switches::kUseGL);
472 if (requested_implementation_name == "swiftshader") { 473 if (requested_implementation_name == "swiftshader") {
473 gpu_info->software_rendering = true; 474 gpu_info->software_rendering = true;
474 gpu_info->context_info_state = kCollectInfoNonFatalFailure; 475 gpu_info->context_info_state = kCollectInfoNonFatalFailure;
475 return kCollectInfoNonFatalFailure; 476 return kCollectInfoNonFatalFailure;
476 } 477 }
477 } 478 }
478 479
479 CollectInfoResult result = CollectGraphicsInfoGL(gpu_info); 480 CollectInfoResult result = CollectGraphicsInfoGL(gpu_info);
480 if (result != kCollectInfoSuccess) { 481 if (result != kCollectInfoSuccess) {
481 gpu_info->context_info_state = result; 482 gpu_info->context_info_state = result;
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
703 shader_model, 704 shader_model,
704 NUM_SHADER_MODELS); 705 NUM_SHADER_MODELS);
705 } 706 }
706 707
707 MergeGPUInfoGL(basic_gpu_info, context_gpu_info); 708 MergeGPUInfoGL(basic_gpu_info, context_gpu_info);
708 709
709 basic_gpu_info->dx_diagnostics = context_gpu_info.dx_diagnostics; 710 basic_gpu_info->dx_diagnostics = context_gpu_info.dx_diagnostics;
710 } 711 }
711 712
712 } // namespace gpu 713 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/config/gpu_info_collector_linux.cc ('k') | gpu/config/gpu_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698