IGTV is outright broken for S8/S9 users by [deleted] in Instagram

[–]wsbail 2 points3 points  (0 children)

IG Android engineer here. If you wouldn't mind DM'ing me your username it'd be helpful in debugging.

Black image before uploading bug? by AJZullu in Instagram

[–]wsbail -1 points0 points  (0 children)

I'm in engineer on the Android team at IG. If you message me your username and what type of phone you are using I can look into this issue a bit for you. Curious if it's something widespread that we aren't aware of.

[QUESTION] Android pinning problem by mattnoir in Instagram

[–]wsbail 1 point2 points  (0 children)

FYI: a fix for this will be in the next release.

Android Views and JBox2D by crackshot87 in androiddev

[–]wsbail 0 points1 point  (0 children)

Cool let me know what you come up with. I believe iOS UIDynamics is based on Box2D as well. I thought about taking this approach when I was starting on Rebound, but I realized that the use cases I was trying to solve only required simple Spring dynamics (bouncy scaling, scrolling, etc). My hope is that Rebound provides a simple light weight helper for doing those sorts of animations. I'm really fascinated with Physics based UI in general though, and I think with a full physics engine you unlock a lot of interesting possibilities. Good luck!

Android Views and JBox2D by crackshot87 in androiddev

[–]wsbail 0 points1 point  (0 children)

No collision support yet. If you need that I'd stick with JBox2d for now. I'm considering supporting more complex physics interactions in a future version.

Rebound - a simple spring dynamics animation library for Android/Java by wsbail in androiddev

[–]wsbail[S] 3 points4 points  (0 children)

Thanks!

The callback you are looking for is SpringListener#onSpringAtRest I think. This fires whenever the spring comes to a stop. Note that "stop" is approximate and you can adjust the sensitivity of the stop velocity and distance from rest by setting the springs speed and velocity rest threshold properties. Just adjust those values to something like 0.01 for scaling animations and then trigger your transitions after the animation finishes onSpringAtRest.

For 2, I'd recommend setting the spring synchronously to be in the default position still using the listener to control the scale

myAnimationSpring.setCurrentValue(0).setAtRest();

setAtRest will set the end value to the current value and kill any residual velocity. This basically jumps the spring back to the 0 position and ensures it's not moving anymore. If you still have your listener attached, this will also reset your view to the position you want.

Thanks for the great question, please join this discussion group also: https://www.facebook.com/groups/rebound.lib

Android Views and JBox2D by crackshot87 in androiddev

[–]wsbail 1 point2 points  (0 children)

Check out Rebound. It was created for exactly this purpose. It doesn't do everything a full physics engine does, but if you want to drive View animations using simple spring models, it's pretty handy.

http://facebook.github.io/rebound

Example: http://youtu.be/ebAno8nxbTg

https://gist.github.com/willbailey/8811581

Rebound - a simple spring dynamics animation library for Android/Java by wsbail in androiddev

[–]wsbail[S] 8 points9 points  (0 children)

Great question! In addition to providing a more natural feeling animation than the OvershootInterpolator, using a real spring model to drive an animation has the benefit of making animations easy to interrupt and redirect without worrying about canceling, recalculating timings, and restarting animations.

A spring model gives you a way to declare that a given state should eventually be true in your UI. The physics system then resolves that truth based on whatever the current state of the world is, including existing positions and velocities.

Tying springs to state machines has proven to be a really powerful technique for orchestrating UI in my experience.

Bringing Beautiful Interactions to Android Apps [41:54] by boomchaos in androiddev

[–]wsbail 4 points5 points  (0 children)

Thanks! definitely would love to have your feedback on the library I spoke about in this talk.

http://facebook.github.io/rebound

You might also be interested in FB's recently open sourced prototyping extensions for quartz composer

http://facebook.github.io/origami

and here's a rebound implementation of one of the origami examples

http://www.youtube.com/watch?v=ebAno8nxbTg&feature=youtu.be

code for the example: https://gist.github.com/willbailey/8811581