Jump to content
Search Community

anandpatel

Members
  • Posts

    6
  • Joined

  • Last visited

Posts posted by anandpatel

  1. I have managed to resolve the positioning issue, however I have been struggling on how to increase the duration each image is displayed for. Currently the 5th image is shown the longest.

     

    Is it possible to change the timeline so that each image is shown an equal amount of time?

  2. I am trying to replicate a similar affect, but instead of crossfade between images straight away, does anyone have any ideas how to fade out the previous image completely before fading in the next image?

     

    const fadeImagesTrigger = document.querySelector('[data-scroll="fadeImagesTrigger"]');
    const fadeImages = document.querySelectorAll('[data-scroll="fadeInOut"]');
    const fadeInOut = new TweenMax.set(fadeImages, {autoAlpha: 0});
    let tween = TweenMax.staggerTo(fadeImages, 1, {autoAlpha: 1}, 1);
    
    let scene = new ScrollMagic.Scene({
        triggerElement: fadeImagesTrigger,
        duration: '200%',
    })
        .setTween(tween)
        .addIndicators()
        .addTo(controller);
×
×
  • Create New...