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

NativeAnimated ? #50

Closed
kamek-pf opened this issue Aug 13, 2016 · 8 comments
Closed

NativeAnimated ? #50

kamek-pf opened this issue Aug 13, 2016 · 8 comments

Comments

@kamek-pf
Copy link

kamek-pf commented Aug 13, 2016

Hey there !
I haven't been following the Animated API too closely, but from what I gathered looking at the RN repo, and correct me if I'm wrong, it looks like the API now has a native driver for each platform.

Maybe it's too soon, but react-native-animatable could probably take advantage of this. See useNativeDriver: true

Has anyone tested these new features ?

@oblador
Copy link
Owner

oblador commented Aug 21, 2016

I'm afraid it's not yet ready for prime time, but I'm following this closely and hopefully soon it will be.

@zibs
Copy link

zibs commented Oct 6, 2016

Also looking forward to the possibility of this!

@oblador
Copy link
Owner

oblador commented Nov 5, 2016

@zibs @kamek-pf @udfalkso @Roconda: Please test this PR out #67

@rdews
Copy link

rdews commented Nov 22, 2016

@oblador I just pulled the PR and tried to make a simple animation native

<Animatable.View animation="fadeInDownBig" duration={500} useNativeDriver>

on android and get this:

E/unknown:React: Exception in native call from JS
                 com.facebook.react.bridge.JSApplicationIllegalArgumentException: Unsupported node type: transform
                     at com.facebook.react.animated.NativeAnimatedNodesManager.createAnimatedNode(NativeAnimatedNodesManager.java:82)
                     at com.facebook.react.animated.NativeAnimatedModule$2.execute(NativeAnimatedModule.java:188)
                     at com.facebook.react.animated.NativeAnimatedModule$1.doFrameGuarded(NativeAnimatedModule.java:110)
                     at com.facebook.react.uimanager.GuardedChoreographerFrameCallback.doFrame(GuardedChoreographerFrameCallback.java:32)
                     at com.facebook.react.uimanager.ReactChoreographer$ReactChoreographerDispatcher.doFrame(ReactChoreographer.java:131)
                     at android.view.Choreographer$CallbackRecord.run(Choreographer.java:872)
                     at android.view.Choreographer.doCallbacks(Choreographer.java:686)
                     at android.view.Choreographer.doFrame(Choreographer.java:618)
                     at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:860)
                     at android.os.Handler.handleCallback(Handler.java:751)
                     at android.os.Handler.dispatchMessage(Handler.java:95)
                     at android.os.Looper.loop(Looper.java:154)
                     at android.app.ActivityThread.main(ActivityThread.java:6119)
                     at java.lang.reflect.Method.invoke(Native Method)
                     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
                     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)

@rdews
Copy link

rdews commented Nov 22, 2016

Looks like transform support is coming:
facebook/react-native@df05311

@oblador
Copy link
Owner

oblador commented Nov 22, 2016

@rdews This works on iOS AFAIK.

@rdews
Copy link

rdews commented Nov 23, 2016

Yes. And after upgrading react to 0.38.0-rc1 it works on android too. Thanks!

@oblador
Copy link
Owner

oblador commented Nov 24, 2016

This was just released in 1.0.0.

@oblador oblador closed this as completed Nov 24, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants