GearVRf
GearVRf copied to clipboard
Animations in reverse?
Do we have an option to play animations in reverse?
For now the GVRRepeatMode options are ONCE, REPEATED and PINGPONG. Given that GVRRepeatMode.PINGPONG can do start to finish and finish to start. Would it be easy to add a new option for reverse?
This makes it convenient to create one animation and play it forward and reverse when needed instead of having 2 separate animations.
There are different ways to do that. I think we can consider a couple of things:
- Add speed and time as properties. Reverse can be done by setting speed to -1, and time to the last.
- An API may be added to set the reverse mode.
I think the repeat mode can still apply when you play an animation in reverse.
I've seen other animation engine doing this. I think it might be a cleaner design than adding REVERSE in the repeat mode.