#ifndef GPU_CONFIG_GPU_INFO_COLLECTOR_H_
#define GPU_CONFIG_GPU_INFO_COLLECTOR_H_
#include <stdint.h>
#include "build/build_config.h"
#include "gpu/config/gpu_info.h"
#include "gpu/config/gpu_preferences.h"
#include "gpu/gpu_export.h"
#include "ui/gfx/gpu_extra_info.h"
#if BUILDFLAG(IS_WIN)
#include <d3dcommon.h>
#endif
namespace gl {
class GLDisplay;
}
namespace angle {
struct SystemInfo;
}
namespace base {
class CommandLine;
}
namespace gpu {
GPU_EXPORT bool CollectBasicGraphicsInfo(GPUInfo* gpu_info);
GPU_EXPORT bool CollectBasicGraphicsInfo(const base::CommandLine* command_line,
GPUInfo* gpu_info);
GPU_EXPORT bool CollectContextGraphicsInfo(GPUInfo* gpu_info);
#if BUILDFLAG(IS_WIN)
GPU_EXPORT void GetGpuSupportedDirectXVersion(
uint32_t& d3d12_feature_level,
uint32_t& highest_shader_model_version,
uint32_t& directml_feature_level);
GPU_EXPORT void RecordGpuSupportedDx12VersionHistograms(
uint32_t d3d12_feature_level,
uint32_t highest_shader_model_version);
GPU_EXPORT uint32_t
GetGpuSupportedVulkanVersion(const gpu::GPUInfo::GPUDevice& gpu_device);
GPU_EXPORT bool CollectD3D11FeatureInfo(D3D_FEATURE_LEVEL* d3d11_feature_level,
bool* has_discrete_gpu);
GPU_EXPORT void CollectHardwareOverlayInfo(OverlayInfo* overlay_info);
bool IdentifyActiveGPUWithLuid(GPUInfo* gpu_info);
#endif
GPU_EXPORT bool CollectGraphicsInfoGL(GPUInfo* gpu_info,
gl::GLDisplay* display);
GPU_EXPORT void IdentifyActiveGPU(GPUInfo* gpu_info);
void FillGPUInfoFromSystemInfo(GPUInfo* gpu_info,
angle::SystemInfo* system_info);
GPU_EXPORT void CollectGraphicsInfoForTesting(GPUInfo* gpu_info);
GPU_EXPORT bool CollectGpuExtraInfo(gfx::GpuExtraInfo* gpu_extra_info,
const GpuPreferences& prefs);
GPU_EXPORT void CollectDawnInfo(const gpu::GpuPreferences& gpu_preferences,
bool collect_metrics,
std::vector<std::string>* dawn_info_list);
}
#endif