Optimize Blob shadow by projector

Because I baked the lighting, I used a projector to display blob shadows for the character. However, when using the projector, I noticed an abnormal increase in batch count, and I’m unsure why there are so many draw call commands, as shown in the two images below. I want to ask if there’s a way to optimize this, and if there are alternative methods to fake shadows besides using a projector. Thank you.

@namdao1227 Are you using URP? I’d suggest using the official sample: Graphics/Packages/com.unity.render-pipelines.universal/Samples~/URPPackageSamples/Decals/BlobShadow at master · Unity-Technologies/Graphics · GitHub

The decal shadows are instanced so they are all rendered in one draw call, even when they have different settings like the scale factor.

This is with screen space decals enabled. I’m not sure if DBuffer works the same.

I appreciate it. I tried it, and it works quite well on URP. However, my project is using the built-in pipeline, so I’m not sure if there’s any other way to optimize or fake shadows.

The projector requires re-rendering all geometry affected by it. This is because the projected image is rendered using an additional pass. For this reason it’s recommended to use it very sparingly or not at all.

For the BiRP - If you are using deferred rendering then you absolutely should replace it with some kind of decal system. If you are using forward then you might want to look into some other kind of system like using quads and raycasting for blob shadows. The results won’t look as nice and could actually be more expensive so, I’d consider doing a simple test case to see if the performance is worth it before fully committing to that. If you’re getting the framerate you want with the projectors already then it’ll be a lot of extra work for nothing.