GeorgLegato / Txt2Vectorgraphics

Custom Script for Automatics1111 StableDiffusion-WebUI.
GNU General Public License v3.0
362 stars 29 forks source link

Color #3

Open TCNOco opened 1 year ago

TCNOco commented 1 year ago

This may be out of scope for this project, may not be... Assuming I generate cartoons, is there a similar tool for creating SVG images with coloured shapes? I assume a lot of compressing colours and gradients down to solid shapes would need to be done, but even generating something "South Park"-inspired, for example.

It this tool currently able to do something like this?

GeorgLegato commented 1 year ago

I have a preview already implemented, but too bad quality... i post it in few mins on reddit

TCNOco commented 1 year ago

Yeah, I see potrace is B&W only, but I have seen a few tools online that convert (relatively well) images to color SVGs. Don't know of anything that can be locally run/called.

Take Adobe's image to SVG for example.

GeorgLegato commented 1 year ago

https://www.reddit.com/r/StableDiffusion/comments/xtu3e9/preview_colored_icons_as_txt2vectorgraphics/

Adobe struggles as well on the halftones in picture: image

GeorgLegato commented 1 year ago

something like that i guess. check the results are too pickled and noise inside the svg (Kim Kardashain in southpark)

txt2png: download

svg: 00001-3395043740

VexedPanda commented 1 year ago

Looking close at the vtracer demos on their site, it’s evident there too. It’s introducing patches of a third colour in between boundaries of two colours.

GeorgLegato commented 1 year ago

btw, vectormagic.com has exactly the solution as needed. they produce really perfect vectors on colored/antialiased input. closed source ,-)

some9000 commented 1 year ago

Also really looked into finding something that could do colored tracing here. No usable results. And yeah, Vector Magic is the best vectorizer by far. Around 2010 they had a desktop app. If you look really hard, you can probably find a usable version. Not sure about licensing, though.