DEV Community

Discussion on: A Generative SVG Starter Kit

Collapse
 
jamesthomson profile image
James Thomson

Great write up. I've been using SVG in many different ways over the past years and love it. The fact that it's XML based makes it so easy to manipulate values and bring vector graphics to life.

Do you have much experience with canvas? As a lot of what's discussed in your article could be applied to canvas, I'd be interested in your take on the pros/cons between the two.

Collapse
 
georgedoescode profile image
George Francis

Cheers, James!

I started out doing generative stuff in canvas, by way of p5.js. I still love both SVG and Canvas, but most often reach for SVG nowadays. I tend to only switch to canvas / occasionally webGL when I really need the performance :)

Just as an example - if I was working on a piece with a particle system, or a piece with very large animated elements, I would choose canvas. For just about anything else, I would choose SVG.

It mostly comes down to simplicity for me. I personally just find SVG much easier/quicker to write. I can focus on the creative aspect rather than worrying about lower level graphics code.

Maybe this deserves a blog post of it's own... Thanks so much for taking the time to comment and for making me think about process. It's not something I usually give much thought to! 💡

Collapse
 
jamesthomson profile image
James Thomson

Thanks for the reply. Makes complete sense regarding particles/more intensive animations. Would enjoy a blog post on this. Tag me if you end up writing one 🙂