-
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
Use frameState.afterRender to fire QuadtreePrimitive.tileLoadProgressEvent #3450
Labels
Comments
pjcozzi
added
cleanup
good first issue
An opportunity for first time contributors
labels
Jan 21, 2016
@pjcozzi Can I take this one? |
Sure. The code you'll want to modify is here: The example to use is here: Make sure to run all the tests and that they still pass. See https://github.com/AnalyticalGraphicsInc/cesium/blob/master/CONTRIBUTING.md#pull-request-guidelines |
I tried changing the code to this, function raiseTileLoadProgressEvent(primitive, frameState) {
var currentLoadQueueLength = primitive._tileLoadQueue.length;
if (currentLoadQueueLength !== primitive._lastTileLoadQueueLength) {
frameState.afterRender.push(function() {
primitive._tileLoadProgressEvent.raiseEvent(currentLoadQueueLength);
primitive._lastTileLoadQueueLength = currentLoadQueueLength;
});
}
} However, the test case
fails, what am I missing ? |
@pjcozzi a little help here please :) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In case, for example, someone adds new primitives in the callback.
For example, see https://github.com/AnalyticalGraphicsInc/cesium/blob/7d449906cf65cf06e75d5cde7bf2dd5921bc95dd/Source/Scene/ModelAnimationCollection.js#L387
The text was updated successfully, but these errors were encountered: