1
$\begingroup$

I am new to the DX12 world and I am currently trying to tweak the nbody_gravity DX12 sample, but appending or calling another Compute Shader which is to add 2 buffers to produce an output in a different buffer.

Right now, I have made a call to my ComputeBufferAddition shader and was wondering if I need a separate Compute PSO to do this, or can I reuse the one already present to call the NbodyGravity.hlsl

$\endgroup$

1 Answer 1

2
$\begingroup$

If I understand you correctly, you've added a new compute shader. In DX12, you'll need at least one separate PSO for each shader, since the shader code is part of the PSO.

$\endgroup$
1
  • $\begingroup$ Yes, I have added a new computeshader.hlsl $\endgroup$
    – Madhu
    Commented Mar 29, 2017 at 17:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.