Skip to content

Changed animation to use native driver #81

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

Merged
merged 6 commits into from
Aug 30, 2017
Merged

Changed animation to use native driver #81

merged 6 commits into from
Aug 30, 2017

Conversation

RodrigoCS
Copy link

Scroll animation now has useNativeDriver, this greatly improves performance.
Also added a prop to scale interpolation outputScaleValue

@skizzo
Copy link

skizzo commented Aug 29, 2017

This is great @RodrigoCS, thanks! But unfortunately, I can't get it to work:

Environment

react-native: v0.41.2
react: v15.4.2

Code Snippet:

<ParallaxScrollView
      ref={comp => {this.parallaxScrollView = comp}}
      parallaxHeaderHeight={PARALLAX_HEADER_HEIGHT}
      stickyHeaderHeight={STICKY_HEADER_HEIGHT}
      renderBackground={this.renderParallaxBackground}
      renderForeground={this.renderParallaxForeground}
      renderStickyHeader={this.renderParallaxStickyHeader}
      renderFixedHeader={this.renderParallaxFixedHeader}
      >
      <View>...</View>
</ParallaxScrollView>

Result:

screen shot 2017-08-29 at 19 42 09

Any ideas what I might be doing wrong? Thanks!

@jaysoo jaysoo merged commit a5b11cf into i6mi6:master Aug 30, 2017
fungilation added a commit to fungilation/react-native-parallax-scroll-view that referenced this pull request Sep 8, 2017
@fungilation
Copy link
Collaborator

@RodrigoCS thanks for this patch. I confirm my app now have almost always 60 fps scroll animation even when RN js thread is bogged down! 👍🏼

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

Successfully merging this pull request may close these issues.

4 participants