FreyaHolmer / ShaderForge

A Shader Editor for Unity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GPU Instancing On DX11&DX12

opened this issue · comments

GPU Instancing On DX11&DX12 failed.

If you remove the following code in the shader, it will work.
UNITY_VERTEX_INPUT_INSTANCE_ID
UNITY_SETUP_INSTANCE_ID( v )
UNITY_TRANSFER_INSTANCE_ID( v, o )

hey! I'm pretty sure removing those would break instancing entirely - do you know how to make it work on DX11/12 rather than revert back to non-instanced properties?

hey! I'm pretty sure removing those would break instancing entirely - do you know how to make it work on DX11/12 rather than revert back to non-instanced properties?

I'm not sure, but when I deleted it worked.
In the stats panel of the Game window, Batches is normal, and Draw Calls in the Profiler window are also normal.
But when I opened the GPU instancing, it reduced the number of frames, is obviously wrong.

I am viewing the related documents.
https://docs.unity3d.com/Manual/GPUInstancing.html

@FreyaHolmer If you can, I hope you can tell me how to fix it, of course I don't want to disturb you.

This should have been fixed now in 31a58d6