Am 10.06.2010 um 16:06 schrieb Matteo Bruni:
<0001-d3dx9-Allow-sampler-declaration-without-sampler-type.txt>
The patch looks ok, but I am wondering if the validator complains about typeless samplers. And if not, I guess the interesting question is how those declarations are treated at shader runtime...
2010/6/10 Stefan Dösinger stefandoesinger@gmx.at:
Am 10.06.2010 um 16:06 schrieb Matteo Bruni:
<0001-d3dx9-Allow-sampler-declaration-without-sampler-type.txt>
The patch looks ok, but I am wondering if the validator complains about typeless samplers. And if not, I guess the interesting question is how those declarations are treated at shader runtime...
That's a good objection. The shader validator errors out on these typeless declarations. So maybe it's not safe for us to allow them, as we lack the shader validator? They are also useless probably at this point...
Am 10.06.2010 um 18:28 schrieb Matteo Bruni:
That's a good objection. The shader validator errors out on these typeless declarations. So maybe it's not safe for us to allow them, as we lack the shader validator? They are also useless probably at this point...
It wasn't intended as an objection. It was mostly curiosity, because we have no test in d3d9 that checks for similar behavior, and trying to actually use such a shader for rendering would be somewhat odd.
The patch is fine, and we should have the same behavior as Windows. If a game fails because the validator doesn't complain then the bug is the missing validator, not the assembler that behaves correctly.
Stefan Dösinger wrote:
Am 10.06.2010 um 18:28 schrieb Matteo Bruni:
That's a good objection. The shader validator errors out on these typeless declarations. So maybe it's not safe for us to allow them, as we lack the shader validator? They are also useless probably at this point...
It wasn't intended as an objection. It was mostly curiosity, because we have no test in d3d9 that checks for similar behavior, and trying to actually use such a shader for rendering would be somewhat odd.
It might be a good idea to create the test first before attempting to commit this patch. AJ probably would want this.
James McKenzie
Am 11.06.2010 um 04:59 schrieb James McKenzie:
Stefan Dösinger wrote:
It wasn't intended as an objection. It was mostly curiosity, because we have no test in d3d9 that checks for similar behavior, and trying to actually use such a shader for rendering would be somewhat odd.
It might be a good idea to create the test first before attempting to commit this patch. AJ probably would want this.
We don't know the validator's interface. It is undocumented. We're currently testing what it accepts and rejects by running native vsa.exe or psa.exe and see if it accepts the shader with validation on or off. (the validator is implemented in d3d9.dll, not d3dx9.dll)
So implementing such a test is not trivial.