Recent links
Good practice for patching/hooking DirectX
- if Present() returns D3DERR_DEVICELOST, then free every resource you are holding
- hook TestCooperativeLevel and Reset to be in sync with what the game is thinking (and again, if you get D3DERR_DEVICELOST, free everything and wait)
- what’s important is freeing everything allocated into the D3DPOOL_DEFAULT memory class. But if you are holding resources, you’ll prevent the app from closing DirectX (which it might want to do in order to do a stronger version of reset).
IDirect3DDevice9::Present method
Create DirectX9Texture from RGBA (const char*) buffer
Direct3D 9 to Direct3D 10 Considerations (Direct3D 10)
Directly Mapping Texels to Pixels (Direct3D 9)
2D in Direct3D using Textured Quads
Drawing a Texture to the Screen
IDirect3DDevice9::UpdateTexture method