1 Reply Latest reply on Sep 10, 2015 2:45 AM by pinform

    constant buffers registers

    onepride

      Hi all!

       

      In our dx11.0 game we have reserved constant buffer slots (registers b9-b13), they used for global buffers that updates not frequently.

       

      cbuffer cPerFrame : register(b10)

      cbuffer cPerView : register(b11)

      cbuffer cAmbientCube: register(b12)

      cbuffer cbMaterialParams: register(b13)

       

      Additionally, shaders can use own constant buffers that binds to slots from start of registers range (b0-b8). All cbuffers are correctly aligned by 16 bytes.

      Then I bind constant buffer 'cbMaterialParams' to slot 13 the game hangs at first IDXGISwapChain::Present() call. It's actual only for AMD drivers 15.xx and R7-R9 videocards series, tested in Win 7/8/8.1/10. If I replace 13th slot by 9th all works fine!

      Moreover, if I bind any constant buffer to slot 13 and even not use it in shaders  - the game still hangs at first Present() call.

       

      MSDN says we have 16 slot for constant buffers when two last of them are used internally, so we have 0-13 range for use in shaders. What's wrong with it? There is no problems with NVidia card at all, there is no one error in DX debug mode. AMD drivers 14.xx works well too.