Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
How to detect if d3dcompiler_47 is the Win10+ ver (that accepts typed UAV loads) or not
// Check if we support D3D12 functionality by trying to compile a standalone root signature blob
{
static char const rootsig_code[] = "#define main \"RootFlags(0)\"";
ID3D10Blob *blob=0;
HRESULT hr = D3DCompileFunc(rootsig_code, strlen(rootsig_code), "source", NULL, NULL, "main", "rootsig_1_0", 0, 0, &blob, 0);
if (SUCCEEDED(hr))
can_compile_d3d12 = true;
if (blob)
blob->Release();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment