Bithack / principia

Open source physics-based sandbox game.
https://principia-web.se
Other
260 stars 25 forks source link

Improve sticky note texture managment #126

Closed griffi-gh closed 6 months ago

griffi-gh commented 1 year ago

reopened the old pr (also I removed the option in settings)

Uses 256x256 textures (double the resolution) on all platforms, which resuts in a 2048x2048 master texure.

doesn't affect the save format (as long as the slot count stays the same).

as a side effect, vertical texture leak issues are significantly reduced.


Shoves (up to) 64 notes into a single 1024x1024/2048x2048 texture!

Everything is configurable! (Note width, height, font scale, texture width/height, slot count, non-square textures should be supported)

should be good enough (tm) to merge, but please test thoroughly.


rollerozxa commented 10 months ago

Wasn't this already merged?

griffi-gh commented 10 months ago

Wasn't this already merged?

No, this is completely different. (and based on previous work on increasing the slot count)
this is basically a complete rewrite, and allows stacking textures horizontally as well as vertically; up to 64 notes in a single 2048x2048 texture, at double the resolution (instead of 32 blurry notes in a tall 128x4096 texture, capped by the Android texture size limit)

I reccomended lowering the slot count back to 32 (and reducing the texture size to 2048x1024) for compatability