The following is an introduction to SPR Batcher accelerated rendering on Unity's official website
https://blog.unity.com/technology/srp-batcher-speed-up-your-rendering
https://docs.unity3d.com/Manual/SRPBatcher.html
When URP shader is written, SRP Batcher will appear not compatible, and the rendering performance will drop at this time
报错:
Material property is found in another cbuffer than "UnityPerMaterial"
It will be reminded
as shown below:
This is not what we want, we want to proceed
The reason for this is that the shader variables we defined are not accelerated as shown in the figure:
If you modify:
only need to speed up the variables, as follows
Then check the SPR Batcher of the shader file again and it will be normal
————————————————
Original link: https://blog.csdn.net/RoadsideWeeds/article/details/123072157