Skip to content
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

Compare frames based on bounds as well. #18

Open
gskinner opened this issue Oct 10, 2014 · 2 comments
Open

Compare frames based on bounds as well. #18

gskinner opened this issue Oct 10, 2014 · 2 comments
Assignees

Comments

@gskinner
Copy link
Member

Zoe uses the origin to compare frames to one another for frame reuse. This makes the most sense in a variety of cases, but it means it fails to reuse frames when the only change is a graphic translating (x,y). For example, an animation of a bouncing ball could be reduced to a single image frame, and a series of frame definitions with varying regY.

It would be nice if Zoe could also check for frame similarities based on the bounds of each frame (possibly aligning from the center, to reduce the impact of antialiasing). It would double the performance cost, but would likely be worth it.

See also:
http://community.createjs.com/discussions/zoe/115-when-variable-frames-and-reuse-frames-are-used-at-the-same-time-zoe-doesnt-provide-a-correct-output-for-the-frames-arrwy

@Tom-Sesselmann
Copy link

We've been using workarounds for this bug for years, just found this thread and it would be great if we could get a fix for this 😄

@Cleod9
Copy link

Cleod9 commented Apr 21, 2015

@Tom-Sesselmann
Sorry Grant, I promise this is the last time I'll try to steal the spotlight! But I released a project recently called SpriteSatchel that's an alternative to Zoe which might help. It can handle frame-re-use fairly well when translating, especially if you are using whole number positioning. Only catch is that it requires a slightly different method of organizing your animations (a more preferable way imo), you may want to have a look:
https://github.com/cleod9/spritesatchel

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants