Aero68

On WM_SIZE i try to resize by buffer but nothing happens

m_pSwapChain->ResizeBuffers(1,Width,Height,DXGI_FORMAT_R8G8B8A8_UNORM,0);



Re: Direct3D 10 Need help with ResizeBuffers

Ralf Kornmann

Before you can call ResizeBuffer you have to make sure that you don¡¯t hold any reference to the current back buffer. This includes any object that was requested with GetBuffer and any view that was created for these resources. As I believe it is a render target view in your case you should detach it from the device before you destroy it.

As you will need to create new views after ResizeBuffer don¡¯t forget to attach it to the device and set the new view port size.