Jump to content
Search Community

Scrolltrigger svg mask

Sukru test
Moderator Tag

Go to solution Solved by mvaneijgen,

Recommended Posts

The image needs to be part of the SVG via the <image> tag https://developer.mozilla.org/en-US/docs/Web/SVG/Element/image

 

Or the SVG mask needs to be 1px by 1px, see following post https://davesmyth.com/clip-path-scaling

 

If your mask is just a 'simple' shape it is much easier to use a CSS clip-path https://bennettfeely.com/clippy/ (make sure if you want to animate a clipPath that you animate between shapes that have the same amount of points and that all your values are suffixed with a '%' sign. 

 

Hope it helps and happy tweening! 

  • Like 1
Link to comment
Share on other sites

  • Solution

I don't know what you're saying. I would just use a clip-path if your shape isn't to complex. You can just make your shapes with  https://bennettfeely.com/clippy/ (make sure if you want to animate a clipPath that you animate between shapes that have the same amount of points and that all your values are suffixed with a '%' sign)

 

See the Pen rNPWdQP?editors=0010 by mvaneijgen (@mvaneijgen) on CodePen

  • 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...