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 CONTENT_COMMON_GPU_GPU_PARAM_TRAITS_MACROS_H_ |
| 6 #define CONTENT_COMMON_GPU_GPU_PARAM_TRAITS_MACROS_H_ |
| 7 |
| 8 #include "content/common/content_export.h" |
| 9 #include "content/common/gpu/gpu_stream_constants.h" |
| 10 #include "gpu/command_buffer/common/constants.h" |
| 11 #include "gpu/command_buffer/common/gpu_memory_allocation.h" |
| 12 #include "gpu/config/gpu_info.h" |
| 13 #include "ipc/ipc_message_macros.h" |
| 14 #include "media/base/video_codecs.h" |
| 15 #include "ui/gfx/gpu_memory_buffer.h" |
| 16 #include "ui/gfx/ipc/gfx_param_traits.h" |
| 17 #include "ui/gfx/swap_result.h" |
| 18 #include "ui/gl/gpu_preference.h" |
| 19 #include "url/ipc/url_param_traits.h" |
| 20 |
| 21 #undef IPC_MESSAGE_EXPORT |
| 22 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT |
| 23 |
| 24 IPC_ENUM_TRAITS_MIN_MAX_VALUE(media::VideoCodecProfile, |
| 25 media::VIDEO_CODEC_PROFILE_MIN, |
| 26 media::VIDEO_CODEC_PROFILE_MAX) |
| 27 |
| 28 IPC_STRUCT_TRAITS_BEGIN(gpu::VideoDecodeAcceleratorSupportedProfile) |
| 29 IPC_STRUCT_TRAITS_MEMBER(profile) |
| 30 IPC_STRUCT_TRAITS_MEMBER(max_resolution) |
| 31 IPC_STRUCT_TRAITS_MEMBER(min_resolution) |
| 32 IPC_STRUCT_TRAITS_END() |
| 33 |
| 34 IPC_STRUCT_TRAITS_BEGIN(gpu::VideoDecodeAcceleratorCapabilities) |
| 35 IPC_STRUCT_TRAITS_MEMBER(supported_profiles) |
| 36 IPC_STRUCT_TRAITS_MEMBER(flags) |
| 37 IPC_STRUCT_TRAITS_END() |
| 38 |
| 39 IPC_STRUCT_TRAITS_BEGIN(gpu::VideoEncodeAcceleratorSupportedProfile) |
| 40 IPC_STRUCT_TRAITS_MEMBER(profile) |
| 41 IPC_STRUCT_TRAITS_MEMBER(max_resolution) |
| 42 IPC_STRUCT_TRAITS_MEMBER(max_framerate_numerator) |
| 43 IPC_STRUCT_TRAITS_MEMBER(max_framerate_denominator) |
| 44 IPC_STRUCT_TRAITS_END() |
| 45 |
| 46 IPC_ENUM_TRAITS_MAX_VALUE(gfx::GpuMemoryBufferType, |
| 47 gfx::GPU_MEMORY_BUFFER_TYPE_LAST) |
| 48 |
| 49 IPC_STRUCT_TRAITS_BEGIN(gfx::GpuMemoryBufferHandle) |
| 50 IPC_STRUCT_TRAITS_MEMBER(id) |
| 51 IPC_STRUCT_TRAITS_MEMBER(type) |
| 52 IPC_STRUCT_TRAITS_MEMBER(handle) |
| 53 IPC_STRUCT_TRAITS_MEMBER(offset) |
| 54 IPC_STRUCT_TRAITS_MEMBER(stride) |
| 55 #if defined(USE_OZONE) |
| 56 IPC_STRUCT_TRAITS_MEMBER(native_pixmap_handle) |
| 57 #elif defined(OS_MACOSX) |
| 58 IPC_STRUCT_TRAITS_MEMBER(mach_port) |
| 59 #endif |
| 60 IPC_STRUCT_TRAITS_END() |
| 61 |
| 62 IPC_STRUCT_TRAITS_BEGIN(gfx::GpuMemoryBufferId) |
| 63 IPC_STRUCT_TRAITS_MEMBER(id) |
| 64 IPC_STRUCT_TRAITS_END() |
| 65 |
| 66 IPC_ENUM_TRAITS_MAX_VALUE(gfx::GpuPreference, gfx::GpuPreferenceLast) |
| 67 IPC_ENUM_TRAITS_MAX_VALUE(content::GpuStreamPriority, |
| 68 content::GpuStreamPriority::LAST) |
| 69 IPC_ENUM_TRAITS_MAX_VALUE(gfx::SwapResult, gfx::SwapResult::SWAP_RESULT_LAST) |
| 70 IPC_ENUM_TRAITS_MAX_VALUE(gpu::MemoryAllocation::PriorityCutoff, |
| 71 gpu::MemoryAllocation::CUTOFF_LAST) |
| 72 IPC_ENUM_TRAITS_MAX_VALUE(gpu::error::ContextLostReason, |
| 73 gpu::error::kContextLostReasonLast) |
| 74 IPC_ENUM_TRAITS_MIN_MAX_VALUE(gpu::CollectInfoResult, |
| 75 gpu::kCollectInfoNone, |
| 76 gpu::kCollectInfoFatalFailure) |
| 77 IPC_ENUM_TRAITS_MIN_MAX_VALUE(gpu::VideoCodecProfile, |
| 78 gpu::VIDEO_CODEC_PROFILE_MIN, |
| 79 gpu::VIDEO_CODEC_PROFILE_MAX) |
| 80 |
| 81 IPC_STRUCT_TRAITS_BEGIN(gpu::DxDiagNode) |
| 82 IPC_STRUCT_TRAITS_MEMBER(values) |
| 83 IPC_STRUCT_TRAITS_MEMBER(children) |
| 84 IPC_STRUCT_TRAITS_END() |
| 85 |
| 86 IPC_STRUCT_TRAITS_BEGIN(gpu::GPUInfo::GPUDevice) |
| 87 IPC_STRUCT_TRAITS_MEMBER(vendor_id) |
| 88 IPC_STRUCT_TRAITS_MEMBER(device_id) |
| 89 IPC_STRUCT_TRAITS_MEMBER(active) |
| 90 IPC_STRUCT_TRAITS_MEMBER(vendor_string) |
| 91 IPC_STRUCT_TRAITS_MEMBER(device_string) |
| 92 IPC_STRUCT_TRAITS_END() |
| 93 |
| 94 IPC_STRUCT_TRAITS_BEGIN(gpu::GPUInfo) |
| 95 IPC_STRUCT_TRAITS_MEMBER(initialization_time) |
| 96 IPC_STRUCT_TRAITS_MEMBER(optimus) |
| 97 IPC_STRUCT_TRAITS_MEMBER(amd_switchable) |
| 98 IPC_STRUCT_TRAITS_MEMBER(lenovo_dcute) |
| 99 IPC_STRUCT_TRAITS_MEMBER(gpu) |
| 100 IPC_STRUCT_TRAITS_MEMBER(secondary_gpus) |
| 101 IPC_STRUCT_TRAITS_MEMBER(adapter_luid) |
| 102 IPC_STRUCT_TRAITS_MEMBER(driver_vendor) |
| 103 IPC_STRUCT_TRAITS_MEMBER(driver_version) |
| 104 IPC_STRUCT_TRAITS_MEMBER(driver_date) |
| 105 IPC_STRUCT_TRAITS_MEMBER(pixel_shader_version) |
| 106 IPC_STRUCT_TRAITS_MEMBER(vertex_shader_version) |
| 107 IPC_STRUCT_TRAITS_MEMBER(max_msaa_samples) |
| 108 IPC_STRUCT_TRAITS_MEMBER(machine_model_name) |
| 109 IPC_STRUCT_TRAITS_MEMBER(machine_model_version) |
| 110 IPC_STRUCT_TRAITS_MEMBER(gl_version) |
| 111 IPC_STRUCT_TRAITS_MEMBER(gl_vendor) |
| 112 IPC_STRUCT_TRAITS_MEMBER(gl_renderer) |
| 113 IPC_STRUCT_TRAITS_MEMBER(gl_extensions) |
| 114 IPC_STRUCT_TRAITS_MEMBER(gl_ws_vendor) |
| 115 IPC_STRUCT_TRAITS_MEMBER(gl_ws_version) |
| 116 IPC_STRUCT_TRAITS_MEMBER(gl_ws_extensions) |
| 117 IPC_STRUCT_TRAITS_MEMBER(gl_reset_notification_strategy) |
| 118 IPC_STRUCT_TRAITS_MEMBER(can_lose_context) |
| 119 IPC_STRUCT_TRAITS_MEMBER(software_rendering) |
| 120 IPC_STRUCT_TRAITS_MEMBER(direct_rendering) |
| 121 IPC_STRUCT_TRAITS_MEMBER(sandboxed) |
| 122 IPC_STRUCT_TRAITS_MEMBER(process_crash_count) |
| 123 IPC_STRUCT_TRAITS_MEMBER(in_process_gpu) |
| 124 IPC_STRUCT_TRAITS_MEMBER(basic_info_state) |
| 125 IPC_STRUCT_TRAITS_MEMBER(context_info_state) |
| 126 #if defined(OS_WIN) |
| 127 IPC_STRUCT_TRAITS_MEMBER(dx_diagnostics_info_state) |
| 128 IPC_STRUCT_TRAITS_MEMBER(dx_diagnostics) |
| 129 #endif |
| 130 IPC_STRUCT_TRAITS_MEMBER(video_decode_accelerator_capabilities) |
| 131 IPC_STRUCT_TRAITS_MEMBER(video_encode_accelerator_supported_profiles) |
| 132 IPC_STRUCT_TRAITS_MEMBER(jpeg_decode_accelerator_supported) |
| 133 IPC_STRUCT_TRAITS_END() |
| 134 |
| 135 IPC_STRUCT_TRAITS_BEGIN(gpu::MemoryAllocation) |
| 136 IPC_STRUCT_TRAITS_MEMBER(bytes_limit_when_visible) |
| 137 IPC_STRUCT_TRAITS_MEMBER(priority_cutoff_when_visible) |
| 138 IPC_STRUCT_TRAITS_END() |
| 139 |
| 140 #endif // CONTENT_COMMON_GPU_GPU_PARAM_TRAITS_MACROS_H_ |
OLD | NEW |