c++ - How to extract bitmap out of Direct3D 11 Texture2D object? -


i using desktop duplication api (c++) , have created output duplication object , further queried interface id3d11texture2d object.

i have tried using "d3dx11savetexturetofile" , "directx::savewictexturetofile" gives error. need extract bitmap or pixel buffer out of texture can save image. have tried using subresource , id3d11devicecontext::map function extract pixel buffer seems empty. context->draw() seems work.

is there anyway can extract pixel buffer/bitmap/image out of texture2d object?

thanks!

update : solved using capturetexture function in directxtex. can create hbitmap resultant scratchimage


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -