Changes WorldSceneRenderer to use a Set<BlockPos> instead of a strange map, and uses Set#contains instead of a stream for TrackedDummyWorld's renderFilter predicate. This drastically reduces allocations in multiblock previews.
This change breaks rendering in the terminal's auto build UI such that it does not display blocks after it auto places. I did not notice any change in the AR preview. Both of these are in a deprecated/soon to be removed state, so this should be fine for now.
What
Changes
WorldSceneRenderer
to use aSet<BlockPos>
instead of a strange map, and usesSet#contains
instead of a stream forTrackedDummyWorld
'srenderFilter
predicate. This drastically reduces allocations in multiblock previews.Outcome
Improves multiblock preview rendering performance.
Additional Information
This change breaks rendering in the terminal's auto build UI such that it does not display blocks after it auto places. I did not notice any change in the AR preview. Both of these are in a deprecated/soon to be removed state, so this should be fine for now.