OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CC_IPC_GPU_STRUCT_TRAITS_H_ |
| 6 #define CC_IPC_GPU_STRUCT_TRAITS_H_ |
| 7 |
| 8 #include "gpu/ipc/common/gpu_info.mojom.h" |
| 9 |
| 10 namespace gpu { |
| 11 struct GPUInfo; |
| 12 struct GPUDevice; |
| 13 } |
| 14 |
| 15 namespace mojo { |
| 16 |
| 17 template <> |
| 18 struct StructTraits<gpu::mojom::GpuDevice, gpu::GPUInfo::GPUDevice> { |
| 19 static bool Read(gpu::mojom::GpuDeviceDataView data, |
| 20 gpu::GPUInfo::GPUDevice* out); |
| 21 }; |
| 22 |
| 23 template <> |
| 24 struct EnumTraits<gpu::mojom::CollectInfoResult, gpu::CollectInfoResult> { |
| 25 static gpu::mojom::CollectInfoResult ToMojom( |
| 26 gpu::CollectInfoResult collect_info_result); |
| 27 |
| 28 static bool FromMojom(gpu::mojom::CollectInfoResult input, |
| 29 gpu::CollectInfoResult* out); |
| 30 }; |
| 31 |
| 32 template <> |
| 33 struct StructTraits<gpu::mojom::GpuInfo, gpu::GPUInfo> { |
| 34 static bool Read(gpu::mojom::GpuInfoDataView data, gpu::GPUInfo* out); |
| 35 }; |
| 36 |
| 37 } // namespace mojo |
| 38 #endif // CC_IPC_GPU_STRUCT_TRAITS_H_ |
OLD | NEW |