forked from GPUOpen-Tools/gpu_performance_api
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdx11_utils.h
34 lines (28 loc) · 1.54 KB
/
dx11_utils.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
//==============================================================================
// Copyright (c) 2015-2020 Advanced Micro Devices, Inc. All rights reserved.
/// \author AMD Developer Tools Team
/// \file
/// \brief DX11 utility function declaration
//==============================================================================
#ifndef _DX11_UTILS_H_
#define _DX11_UTILS_H_
#include "dx11_include.h"
namespace DX11Utils
{
/// Checks whether the interface pointer is DirectX 11 device or not. If it is, it returns the ID3D11Device device pointer.
/// Function increments the reference of the ID3D11Device pointer
/// \param[in] pInterfacePointer DirectX 11 interface pointer
/// \param[out] ppD3D11Device DirectX 11 device pointer
/// \return true if interface pointer is device otherwise false
bool GetD3D11Device(IUnknown* pInterfacePointer, ID3D11Device** ppD3D11Device);
/// Checks whether or not the device supports the minimum DirectX 11 feature level
/// \param[in] pD3D11Device device pointer
/// \return true if device is supports minimal level of DirectX 11 otherwise false
bool IsFeatureLevelSupported(ID3D11Device* pD3D11Device);
/// Get the time stamp frequencey of DirectX 11 device
/// \param[in] pD3D11Device device pointer
/// \param[out] timestampFrequency The timestamp frequencey
/// \return true if timestamp frequencey access succeeded, otherwise false
bool GetTimestampFrequency(ID3D11Device* pD3D11Device, UINT64& timestampFrequency);
} // namespace DX11Utils
#endif // _DX11_UTILS_H_