Commit 39df2eb6 authored by Niklas Haas's avatar Niklas Haas

renderer: aggressively re-use FBOs

As an addendum to f3a07a, this quenches all concerns by making sure we
re-use same-sized FBOs wherever possible. The new code should be
strictly better than even the old code, in terms of minimizing FBO

It is not yet, however, optimal in the sense of minimizing FBO residency
for FBOs that could be aliased. Doing that would require refcounting
FBOs or something. (Which I guess isn't too difficult to accomplish, so
maybe I should give it a try?)

That being said, aliasing FBOs might break cross-frame optimizations,
which would only end up necessitating us introducing other tricks like
rotating between different pl_renderer instances, thus defeating the
gains. Would have to be tested anyway to see if aliasing FBOs actually
gains more performance than it loses. (And the main benefit would be
gaining VRAM, anyway)

Reduces some code ugliness as a side benefit.
parent 00127130
Pipeline #17714 passed with stages
in 6 minutes and 40 seconds