-
-
Notifications
You must be signed in to change notification settings - Fork 659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create render-to-texture renderpool to render terrain in paralell #1671
Conversation
Bundle size report: Size Change: +828 B
ℹ️ View DetailsNo major changes |
I've fixes most of the tests. |
Hello Harel, thank you for fixing the unit-tests. I will do the last missing tests. Additionally i can create tests with different stylesheets and check if the merging of layers works correct in render_to_texture.ts. It would be great if someone else can:
|
I think the render test that will be added as part of #1666 will be enough for this as well. |
Yes, tried on my iphone, and works much more performant without a crash. |
Overall this looks good. |
@HarelM thanks for review! Are there more tests needed for testing performance? I am sure this branch increases performance, but i have no idea how to create a performance-test. Help with this would be great! |
I've made the changes myself to reduce cycle time.
I found out about both issues when I ran the tests and looked at the code coverage which is a great things when you create new classes that should be fully tested. :-) This is not holding this PR from my point of view and can be fixed in a later PR. |
@HarelM thanks for your changes, and interesting result from the coverage tool! Very helpful! This line is from the old, not working logic. Missed to think about this line, and delete it. |
This can wait another day, I prefer to merge it with the relevant fix and not create a new PR for this. |
|
This branch creates a Render-To-Texture render-pool, instead of caching textures in RTT Tiles.
Old logic:
The Terrain class had one framebuffer, and a list of tiles which contained a list of textures. This had two problems:
New logic:
There exist a Framebuffer/Texture pool that would be reused during rendering, and the tiles only contains indexes to this pool-objects.
Also this PR makes my other PR #1301 obsolete.
maplibre-gl-js
changelog:<changelog></changelog>
.Need help with:
POOL_SIZE
in render_to_texture.ts.