Why my letters' stroke animation doesn't fill completely?

Hi everybody, I just start learning to use svg and how to create some animations with them. So I'm trying here: https://codepen.io/valerio-fluo/pen/gONZmJm , to animate some text. This is an attempt to recreate an handwriting feel. Since I see that the only thing we can near that is to animate strokes, I'm using very thick strokes so they cover the filling of the letters (Sorry if it's not very clear, english isn't my mother's tongue). But as you can see, the strokes don't write themselves completely. Could someone please explain to me why it does so? Thank you.
No description
14 Replies
ἔρως
ἔρως2mo ago
it does
ἔρως
ἔρως2mo ago
this is what's happening
No description
ἔρως
ἔρως2mo ago
you have a line that's widened by a stroke but it is always a straight line it starts straight, ends straight and there is always going to be a corner that won't be filled, because the storke ends when it hits the beginning point (at any angle) the yellow is where both strokes intersect and over-draw on eachother (because red + green = yellow)
Chris Bolson
Chris Bolson2mo ago
Try adding stroke-linecap: square;
ἔρως
ἔρως2mo ago
or even round but square might do the trick it does the trick ... mostly it's actually almost perfect
Chris Bolson
Chris Bolson2mo ago
You can also play around with the stroke-linejoin to fine-tune it.
ἔρως
ἔρως2mo ago
i will say it is "the best effort you can do" but good catch on stroke-linecap
ἔρως
ἔρως2mo ago
it looks a tiny bit funky when it's starting
No description
ἔρως
ἔρως2mo ago
and the O doesn't look 300% rounded
ἔρως
ἔρως2mo ago
you can see it better here
No description
ἔρως
ἔρως2mo ago
but, hey, considering the situation, i see this as an absolute win well done
Chris Bolson
Chris Bolson2mo ago
It might work better with a different font.
ἔρως
ἔρως2mo ago
yes, times new roman wasn't made for new times
ValerioFluo
ValerioFluoOP2mo ago
Wow thank you so much @ἔρως for the crystal clear explanation, thanks to you now I perfectly understand why, and @Chris for the solution. I know... I know... 😅
Want results from more Discord servers?
Add your server