Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions include/DeviceChild.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ namespace D3D11On12
destroy = InitializeDeferredHandle<TFunc>::Destroy;
}

template <typename... TArgs>
struct InitializeDeferredHandle<void (APIENTRY*)(D3D10DDI_HDEVICE, const UINT*, D3D10DDI_HSHADER, D3D10DDI_HRTSHADER, TArgs...)>
template <typename TSignature, typename... TArgs>
struct InitializeDeferredHandle<void (APIENTRY*)(D3D10DDI_HDEVICE, const UINT*, D3D10DDI_HSHADER, D3D10DDI_HRTSHADER, TSignature, TArgs...)>
{
static void Initialize(D3D10DDI_HDEVICE, const UINT*, D3D10DDI_HSHADER handle, D3D10DDI_HRTSHADER rtHandle, TArgs...)
static void Initialize(D3D10DDI_HDEVICE, const UINT*, D3D10DDI_HSHADER handle, D3D10DDI_HRTSHADER rtHandle, TSignature, TArgs...)
{
reinterpret_cast<DeviceChildDeferred<D3D10DDI_HSHADER>*>(handle.pDrvPrivate)->m_ImmediateHandle = D3D10DDI_HSHADER{ rtHandle.handle };
}
Expand Down
2 changes: 1 addition & 1 deletion include/VideoTranslate.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ namespace D3D11On12

static inline D3D12_VIDEO_DECODE_ARGUMENT_TYPE VideoDecodeArgumentType(D3D11_DDI_VIDEO_DECODER_BUFFER_TYPE Type11)
{
static constexpr D3D12_VIDEO_DECODE_ARGUMENT_TYPE map[] =
static const D3D12_VIDEO_DECODE_ARGUMENT_TYPE map[] =
{
(D3D12_VIDEO_DECODE_ARGUMENT_TYPE)-1,
D3D12_VIDEO_DECODE_ARGUMENT_TYPE_PICTURE_PARAMETERS,
Expand Down
70 changes: 35 additions & 35 deletions src/device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ namespace D3D11On12
if (APISupport1 & D3D12_FORMAT_SUPPORT1_VIDEO_PROCESSOR_INPUT) *pData |= D3D11_1DDI_FORMAT_SUPPORT_VIDEO_PROCESSOR_INPUT;
if (APISupport1 & D3D12_FORMAT_SUPPORT1_IA_VERTEX_BUFFER) *pData |= D3D11_1DDI_FORMAT_SUPPORT_VERTEX_BUFFER;
if (APISupport1 & D3D12_FORMAT_SUPPORT1_BUFFER) *pData |= D3D11_1DDI_FORMAT_SUPPORT_BUFFER;
constexpr D3D12_FORMAT_SUPPORT1 D3D12_FORMAT_SUPPORT1_CAPTURE = (D3D12_FORMAT_SUPPORT1)0x80000000;
const D3D12_FORMAT_SUPPORT1 D3D12_FORMAT_SUPPORT1_CAPTURE = (D3D12_FORMAT_SUPPORT1)0x80000000;
if (APISupport1 & D3D12_FORMAT_SUPPORT1_CAPTURE) *pData |= D3D11_1DDI_FORMAT_SUPPORT_CAPTURE;
if (APISupport1 & D3D12_FORMAT_SUPPORT1_SHADER_GATHER) *pData |= D3D11_1DDI_FORMAT_SUPPORT_SHADER_GATHER;

Expand Down Expand Up @@ -355,40 +355,40 @@ namespace D3D11On12
template <typename TDevice>
void DeviceBase::FillContextDDIs()
{
m_pDDITable->pfnVsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShader = TDevice::SetShader<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShaderWithIfaces = TDevice::SetShaderWithIfaces<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShaderResources = TDevice::SetShaderResources<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetConstantBuffers = TDevice::SetConstantBuffers<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetSamplers = TDevice::SetSamplers<D3D12TranslationLayer::e_CS>;
m_pDDITable->pfnVsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShader = TDevice::template SetShader<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShaderWithIfaces = TDevice::template SetShaderWithIfaces<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetShaderResources = TDevice::template SetShaderResources<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetConstantBuffers = TDevice::template SetConstantBuffers<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnVsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_VS>;
m_pDDITable->pfnPsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_PS>;
m_pDDITable->pfnGsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_GS>;
m_pDDITable->pfnHsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_HS>;
m_pDDITable->pfnDsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_DS>;
m_pDDITable->pfnCsSetSamplers = TDevice::template SetSamplers<D3D12TranslationLayer::e_CS>;

m_pDDITable->pfnDraw = TDevice::Draw;
m_pDDITable->pfnDrawAuto = TDevice::DrawAuto;
Expand Down
Loading