I have a couple of small requests, if you'd be so kind.
Can you please split the patch in two parts, one for the tests and one for the implementation?
Please use "d3dx9:" (and "d3dx9/tests:" if you proceed to split the patch) as the commit subject prefix.