Answer the question
In order to leave comments, you need to log in
How to implement the following effect?
Hello! Perhaps someone knows how to implement the effect shown in the picture. those. dragging the arrow changes the picture. like "before and after". Perhaps there are some libraries?
ps These are two pictures. Before - the first, after - the second.
Answer the question
In order to leave comments, you need to log in
The easiest way is to overlay two blocks on top of each other with pictures before and after, and resize the top block when moving
you can also set 2 blocks equal width and change their width by dragging..
this effect cannot be done with only one picture. you need either a ready-made processed one, or some kind of black-and-white mask, by which you can then calculate the pixels that need to be highlighted. but the first option is better.
I'm not talking about the width correctly here. here you need to make a mask, and not resize the pictures.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question