-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Improve asynchronous Primitive creation #1487
Comments
Due to #1487. We can revisit it in the future when performance is better. Since we create all the geometry up front anyway, this is a load time concern and should not become a usability issue.
👍 It would also be worth exploring how to use multiple workers. |
looking forward to it |
Is there a plan to load billboards asynchronously? In our application we implemented a simple algorithm for loading batches of billboards at once (for example 3000) and then waiting for a certain timeout to expire before loading the next batch (for example 1500 ms). |
@Micha1991, I'm not exactly sure what you are asking. Billboard images are already loaded asynchronously and there's no other part of the process that would cause a block. Please continue this discussion on our forum if you still have questions. |
Update:
While the initial work on this issue is now in master and performance is much better, there are still several things we can do to further improve things. Here are some ideas that we can explore.
unpackInstancesForCombine
rather than the overhead of creating lots of typed arrays.createGeometry
is currently unpacked and can still adds a lot of overhead for certain types of Geometry; this can be fixed by having our Geometry know how to pack themselves or have them store there data in a typed array from the start for each transfer. Pack Geometries before passing to a web worker #2342combineGeometry
is still one big synchronous step and is just performed in a worker (rather than split up across several workers likecreateGeometry
). I'm not sure if it's possible to refactor it in a way that allows for concurrencyOriginal Issue:
Currently, creating primitives asynchronously is much slower than doing it in the main thread. Some simple tests shows that a 1.58 MB GeoJSON file takes about 13 seconds to load asynchronously and only 4 seconds when synchronous. (in Chrome). These numbers are more event dramatic in Firefox, 6 compared to 35.
This is most likely due to a very chatty interface for offloading the pipeline and could be fixed with coarser interfaces.
Here's a profile of what the main thread is doing between "drop 10 megs of GeoJSON on globe" and "stuff shows up" when using asynchronous creation.
The text was updated successfully, but these errors were encountered: