#Debugging "The Parameter Is Incorrect"
23 messages · Page 1 of 1 (latest)
I had the exact same issue recently, trying to remember how I debugged it
But basically, no, you can't really get information about what's incorrect afaik
I think I just looked at the documentation for the arguments and looked very carefully at what I was doing
Can you paste your function call
It's a mishmash of some tutorial code and weird hacks I came up with because I don't really know what I'm doing with this part of DX12 but this code occasionally works
https://hatebin.com/egfyqmlils
my first thought about what's wrong is the part where it sets up the descriptor ranges
I wanna say that the invalid arg parameter literally means that the argument is the wrong type or something, but I'm not sure how that works given that the type system should enforce things
Look at the values of the arguments and make sure there aren't any null pointer or anything
I don't know DX12 so I can't really judge the rest of your code
invalid arg is what you get when the parameter is just straight up uninterpretable I think, if it were getting further than that you'd get a more intelligible validation error
hmm, doesn't seem like I'm passing malformed data for the rootParameter info
rootSignatureFlags is set to D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT & I didn't pass any static samplers (nullptr data & 0 size)
Am I meant to set Num32bitValues manually after init?
No idea sorry, you'll need to wait for someone who knows DX12
Does the error blob tell something useful @sour sandal ?
DX_CHECK(D3DX12SerializeVersionedRootSignature(&rootSignatureDescription, featureData.HighestVersion, &rootSignatureBlob, &errorBlob /*This thing here */));
I don't think so, if your parameter type is not 32 bit constant then you can just ignore it
Looks like descriptor range at index 4 and 6 are the same, is this intentional?
I'm getting this in the error blob
Shader register range of type SAMPLER (root parameter [2], visibility ALL, descriptor table slot [0]) overlaps with another shader register range (root parameter[0], visibility ALL, descriptor table slot [0]).
so looks like my indices are wrong
Yeah those shouldn't be the same, I'll check my array
Yup, a lot of your descriptor tables have the same descriptor range. Might want to check that out
Does it not copy the D3D12_DESCRIPTOR_RANGE1 object when initializing? If so, then that would explain the duplicate entries, I'm passing a pointer to a stack object
Yeah this seemed to be the issue, thanks!