WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
73410
Standardized API to animate spritesheets
https://bugs.webkit.org/show_bug.cgi?id=73410
Summary
Standardized API to animate spritesheets
Paul Bakaus
Reported
2011-11-30 01:32:05 PST
The currently fastest way to animate spritesheets (pngs with individual frames on a large sheet) on browsers that hardware accelerate 3D css transformed content is to put the actual spritesheet into a <div> with overflow hidden (set to the target frame size) and "shift" the spritesheet programmatically in JS via translate3d(). This is non-trivial, and my guess is that not only would a standardized API add clarity, but also might be further optimized.
Attachments
Add attachment
proposed patch, testcase, etc.
Dean Jackson
Comment 1
2011-11-30 12:23:06 PST
For reference:
http://www.starling-framework.org/
and
http://www.adobe.com/devnet/flashplayer/articles/introducing_Starling.html
Not really what Paul is asking for, but still interesting. I think such an API needs a few things: - obviously support for arbitrary sprite sheets (width height rows colums) - ability to set a frame - for animations, set a target fps Should this be in CSS? It seems very-much content to me.
Paul Bakaus
Comment 2
2011-12-01 01:09:39 PST
Hey Dean, yeah, I've seen starling. Nice project, would be lovely to have this on top of WebGL. There's more you can do with the sprite animation API: - easing - b-frame (delta) support It would be interesting to learn from you if you see this as purely API/abstraction win, or if you think, like me, that it can aid performance. Maybe I'm wrong, and above solution can't be accelerated much. Thanks, Paul
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug