Open
Conversation
Contributor
|
I'm not into these batchers but shouldn't the same conditions be done in the |
Contributor
Author
|
@markknol I looked at doing the same thing in WebGL batcher and it doesn't seem to work quite the same way, and doesn't suffer from the same performance hit as Stage3D. I think it has to do with the requirement of clearing out textures when changing rendering contexts in Stage3D, which doesn't apply for WebGL. All I did was check to see if we are using the same texture root (therefore the same texture in the GPU), and make sure we don't call flush when it's not needed. My understanding of what is going on there is a little fuzzy, so it's possible it's just me. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I believe this should fix #314. I've created a stress using 2000 animated MovieSprites. With these changes I'm getting a solid 60FPS. Without the changes, I top out at about 20FPS. Hopefully this doesn't introduce any weird bugs, but so far it's been solid for me on my projects.
The stress test demo I'm using can be downloaded here:
http://clients.seven2.com/out/batcher-stress-test.zip