Stefan Dösinger wrote:
/*****
- Get / Set Render States
- TODO: Verify against dx9 definitions
As Henri said, this needs a test case. So far we have not found any Set* function that returns an error. For SetTexture, SetSamplerState, ..., if the sampler index is out of bounds, the native implementation happily corrupts memory and returns D3D_OK rather than checking anything.
Also even if tests confirm it is correct, I don't think this patch is a good idea unless we have a game that breaks because it expects an error from this function back. The setter functions are highly performance critical. Those value checks add a lot of code(if-then-else constructs in the compiled code) which slows things down. In benchmarks every single if statement in the setter function hurts.
Yes i am aware of the time problems stefan. However with this fix and the one associated with 14072 (I duped it against another which escapes me at the moment) the problem with EverQuest2.exe goes away. EQ2 seems to be loading the fog array until it get the error back. Without this patch and the one mentioned above I get the no pixel shader found error. This is using the latest Git Tree (1.1.2+)
Chris