Jump to content
Search Community

Image Effect Parallax

Olga__Kondr test
Moderator Tag

Recommended Posts

hello GSAP!
I need help from the world's best library again <3.
So, I try to recreate the image parallax effect from rezo-zero. Yes, I've seen the posts on the forum, but please don't send me there I've already viewed them.

Please take a look at my demonstration, I almost achieved the desired result. The only thing I can't understand is how to make the effect very similar to these examples: 
1. https://www.rezo-zero.com/projects/
2. https://cuberto.com/about/

what needs to be corrected?
That is, I want the parallax effect to be not only from below but also from above. As in the case of cuberto or rezo.

See the Pen jOryXay by Ollymolly (@Ollymolly) on CodePen

Link to comment
Share on other sites

Hey Olga.

 

This is just an issue of your ScrollTrigger's start and end positions :) You want the scrub animation to start when the image first comes into view (start: "top bottom") and finish when the image leaves the viewport (end: "bottom top"). Those are actually the default values, so just completely removing the start and end for your ScrollTrigger gives you the effect that you want! It might be good to watch the ScrollTrigger video again to get a better grasp of what's happening.

See the Pen LYZxqrG?editors=0010 by GreenSock (@GreenSock) on CodePen

 

Side note: We recommend using the condensed string form of eases so your Power0.easeNone would become just "none".

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...