Why isn't one of the constant buffers being loaded inside the shader?

Posted by Paul Ske on Game Development See other posts from Game Development or by Paul Ske
Published on 2013-10-23T17:13:36Z Indexed on 2013/10/23 22:07 UTC
Read the original article Hit count: 212

Filed under:

I however got the model to load under tessellation; only problem is that one of the constant buffers aren't actually updating the shader's tessellation factor inside the hullshader.

I created a messagebox at the rendering point so I know for sure the tessellation factor is assigned to the dynamic constant buffer.

Inside the shader code where it says .Edges[1] = tessellationAmount; the tessellationAmount is suppose to be sent from the dynamic buffer to the shader. Otherwise it's just a plain box.

In better explanation; there's a matrixBuffer, cameraBuffer, TessellationBuffer for constant.

There's a multiBuffer array that assigns the matrix, camera, tesselation. So, when I set the Hull Shader, PixelShader, VertexShader, DomainShader it gets assigned by the multibuffer.

E.G. devcon->HSSetConstantBuffers(0,3,multibuffer);

The only way around the whole ideal would be to go in the shader and change how much the edges tessellate and inside the edges as well with the same number.

My question is why wouldn't the tessellationBuffer not work in the shader?

© Game Development or respective owner

Related posts about directx11