| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef GPU_IPC_SERVICE_GPU_INIT_H_ | 5 #ifndef GPU_IPC_SERVICE_GPU_INIT_H_ |
| 6 #define GPU_IPC_SERVICE_GPU_INIT_H_ | 6 #define GPU_IPC_SERVICE_GPU_INIT_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "gpu/config/gpu_feature_info.h" |
| 10 #include "gpu/config/gpu_info.h" | 11 #include "gpu/config/gpu_info.h" |
| 11 #include "gpu/gpu_export.h" | 12 #include "gpu/gpu_export.h" |
| 12 #include "gpu/ipc/service/gpu_watchdog_thread.h" | 13 #include "gpu/ipc/service/gpu_watchdog_thread.h" |
| 13 | 14 |
| 14 namespace base { | 15 namespace base { |
| 15 class CommandLine; | 16 class CommandLine; |
| 16 } | 17 } |
| 17 | 18 |
| 18 namespace gpu { | 19 namespace gpu { |
| 19 | 20 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 31 GpuInit(); | 32 GpuInit(); |
| 32 ~GpuInit(); | 33 ~GpuInit(); |
| 33 | 34 |
| 34 void set_sandbox_helper(GpuSandboxHelper* helper) { | 35 void set_sandbox_helper(GpuSandboxHelper* helper) { |
| 35 sandbox_helper_ = helper; | 36 sandbox_helper_ = helper; |
| 36 } | 37 } |
| 37 | 38 |
| 38 bool InitializeAndStartSandbox(const base::CommandLine& command_line); | 39 bool InitializeAndStartSandbox(const base::CommandLine& command_line); |
| 39 | 40 |
| 40 const GPUInfo& gpu_info() const { return gpu_info_; } | 41 const GPUInfo& gpu_info() const { return gpu_info_; } |
| 42 const GpuFeatureInfo& gpu_feature_info() const { return gpu_feature_info_; } |
| 41 std::unique_ptr<GpuWatchdogThread> TakeWatchdogThread() { | 43 std::unique_ptr<GpuWatchdogThread> TakeWatchdogThread() { |
| 42 return std::move(watchdog_thread_); | 44 return std::move(watchdog_thread_); |
| 43 } | 45 } |
| 44 | 46 |
| 45 private: | 47 private: |
| 46 GpuSandboxHelper* sandbox_helper_ = nullptr; | 48 GpuSandboxHelper* sandbox_helper_ = nullptr; |
| 47 std::unique_ptr<GpuWatchdogThread> watchdog_thread_; | 49 std::unique_ptr<GpuWatchdogThread> watchdog_thread_; |
| 48 GPUInfo gpu_info_; | 50 GPUInfo gpu_info_; |
| 51 GpuFeatureInfo gpu_feature_info_; |
| 49 | 52 |
| 50 DISALLOW_COPY_AND_ASSIGN(GpuInit); | 53 DISALLOW_COPY_AND_ASSIGN(GpuInit); |
| 51 }; | 54 }; |
| 52 | 55 |
| 53 } // namespace gpu | 56 } // namespace gpu |
| 54 | 57 |
| 55 #endif // GPU_IPC_SERVICE_GPU_INIT_H_ | 58 #endif // GPU_IPC_SERVICE_GPU_INIT_H_ |
| OLD | NEW |