Batching of UI elements or sprites


#1

Are there ways of batching UI elements? Or is this automatic?

I found some references to element and sprite arrays in the BatchManager (batchGroup) source - but there is nothing else to be found.

Is this for future updates? Is batching automatic for UI elements?

Pieter


#2

Currently batching is disabled on elements and sprites as it was not working. We’re working on fixing/integrating it properly in the future.


#3

What does batching UI elements mean?


#4

@dave Thanks for the info!
Is there any change you could share what was not working? Is there a quick hack to at least make the elements work (under certain conditions). I need all the performance I can get - and I am willing to do workarounds.

Thanks again!
Pieter


#5

Batching didn’t support sorted/transparent elements so there was no guarantee that your rendering order would be preserved. I think that is working now, but we haven’t fully tested the feature.

You can set the batchGroupId on element components and it may work for your needs, but just be aware that there may be bugs or the behavior may change in the future.


#6

Ah - that might indeed be helpful.
I will check it out and report any findings here