d3dstate: Ensure COM is initialized before calling DirectXTex.

As it often relies on WIC for conversion.
d3dstate: Dump depth-stencil images.

Only the depth values are written so far.