Closed ywnico closed 1 year ago
Thanks! Is there a way to re-order the items instead of resizing? I'm not entirely sure which version of OpenGL we are using, but I think we are using 1.0. OpenGL 1.0 does not support textures of arbitrary size, so I think making the texture slightly larger like your change actually makes it 4 times larger internally.
Oh, I didn't realize that. Indeed, there's enough blank space to rearrange the textures and keep it within 2048x2048 (I did also need to move the volume icons and header background).
Thanks for updating! Would it somehow be possible to re-load the texture when changing the setting instead of always keeping both textures in memory? I don't know too much about OpenGL, but it feels like that should be somehow possible
That does make sense.... I will look into how to do that.
This update should solve the problem of loading textures when changing colors instead of preloading them.
Awesome, thanks!
I hope this is an acceptable solution which is not too complicated. I don't have much experience with Java and Android development, but since I mostly followed ByteHamster's existing code (e.g., copying settings buttons) I hope it is ok. I can make any suggested changes, of course.
I did fear I might possibly be breaking ByteHamster's style of keeping everything very clean and separated in
SettingsState.java
lines 31 & 45-46, where I saved theglRenderer
variable so thatglRenderer.setColorscheme
could be called fromonTouchEvent
. But I did not think of an alternative.