Batching materials

Is there a way to batch objects with the same material but different params? I have jigsaw 81 puzzle peace elements with the same material applied to each one, the difference is the vec2 offset parameter in material effect.

Without applying offset it has 1 draw call, but when I start changing it on each one, draw call is 81 or each peace 1 draw call :(.

Is there any solution for this?

Hi Mercury,
If you are using 3d objects for puzzle pieces you may edit UV map of 3d models rather than changing material offset. I’ve managed to merge all objects in the scene into single material/texture and it significantly reduced draw calls.

1 Like

Thanks for suggestion, it’s not 3d game unfortunately. I know how to reduce calls of 3d elements in game, my question is specifically for material/shader batching objects with same material but different params. Thanks for help anyway @FocusCreative. Maybe @jare can help me ?

May be you can access and modify uv values of vertex points in sprite renderer :thinking:
So material or shader will not be modified.