Fix frustum culling w/ sprite transform scaling#2753
Fix frustum culling w/ sprite transform scaling#2753fuzzbuck wants to merge 5 commits intobevyengine:mainfrom
Conversation
|
Just want to point out that my test case and the one from the author of that issue seem to be showcasing two separate issues. In my test case, sprite scaling is unaccounted for. In that issue, it seems that camera scale is unaccounted for. |
That issue happens because sprites outside of camera bounds are not drawn, regardless of window size Perhaps each camera should have its own frustum_enabled setting? |
|
It does not seem like #1760 happens because of camera Transform scaling ? When scaling the camera below 1.0, the sprite just disappears completely (even with frustum feature disabled), so I don't think this is related to frustum uTWqJWAkPr.mp4 |
|
Ok, in summary:
There are plethora of other issues but I think that can be resolved in other PRs (or v0.6) |
|
#2861 looks like it will obsolete this; is that correct? |
I suppose that practically anything against the 'old' renderer is obsoleted by the new renderer. That said, I didn't actually implement culling for 2D, just visibility propagation. @cart and I were on the fence about whether culling would bring benefits over just culling on the GPU and opted to leave it for later as batched sprite rendering already has great performance on pipelined-rendering anyway and it may not be a clear win. That said, if someone wanted to add sprite rect vs view rect intersection testing for 2D on top of #2861 and check whether it improves performance, I'm sure no one would complain. :) |
|
Closing as no longer relevant <3 |
Objective
Solution