54 minutes ago, pcmaster said:Thank you for the article. It's very interesting, however in the engine (and rather types of games) I'm implementing DX12 into, we don't happen to be instancing that very much and that approach doesn't lower the CPU cost - the higher level still has to prepare the data for each draw, which isn't negligible. But the approach sounds very good for many applications.
There is only one good way to cut on state and lower the cpu. Put all your textures in a huge table, put your materials in a huge structured buffer and let the shader fetch what it needs based on a material id ( important, it has to be uniform ). That way you can in theory draw your scene with as little as one multidraw per PSO ( put all your geometry in a single buffer too, or use ExecuteIndirect to swap VB but not on PS4... ).