I want to set a texture as render target and then save it to the disk. but the rendering is ok, which means I can draw the tea port on the screen, but the file I saved is not ok, I can't open it with texture format D3DFMT_A8R8G8B8, or the file corropted when I use D3DFMT_R5G6B5.
the following is my code, I started use DX for 1 week, I am really weak in this technique, thank you so much~
Hi Please consider checking HRESULT (hr), you could put this returned value into the DXErr.exe (in the SDK) and watch what the error means. You would run your application in Debug Mode inside Visual Studio. The console could print a warning for this situation. Maybe you would save BITMAP this way: