[HN Gopher] Vtracer: Next-Gen Raster-to-Vector Conversion
       ___________________________________________________________________
        
       Vtracer: Next-Gen Raster-to-Vector Conversion
        
       Author : s1291
       Score  : 120 points
       Date   : 2023-11-22 10:10 UTC (1 days ago)
        
 (HTM) web link (github.com)
 (TXT) w3m dump (github.com)
        
       | rootlocus wrote:
       | Maybe now Affinity Designer can introduce a tracing feature and
       | further catch up to Adobe Illustrator.
        
         | wiz21c wrote:
         | and inkscape
        
       | devit wrote:
       | Maybe Facebook's Segment Anything could replace the first
       | clustering step?
        
         | spaceprison wrote:
         | I had a similar idea the other day after fighting with inkscape
         | tracing! The problem with auto tracing is lack of content
         | awareness so it's just shapes and colors leading to strange
         | objects that require lots of tinkering.
         | 
         | I'm going to try it: Use segment anything to get object masks,
         | Trace each object separately and combine from there!
        
           | larodi wrote:
           | It may be much slower, though segment-anything works quite
           | okay from my tests. But still - great work, cant wait to use
           | it in my next design. :D
        
           | ttul wrote:
           | This would make for a nice ComfyUI custom node.
        
           | westurner wrote:
           | > _Comparing to Potrace which only accept binarized inputs
           | (Black & White pixmap), VTracer has an image processing
           | pipeline which can handle colored high resolution scans.
           | tl;dr: Potrace uses a O(n^2) fitting algorithm, whereas
           | vtracer is entirely O(n)._
           | 
           | What is the Big-O of the algorithm with Segment Anything or
           | other segmentation approaches?
           | 
           | Potrace: https://en.wikipedia.org/wiki/Potrace
           | 
           | The Ctrl-L to _Simplify_ Inkscape feature attempts to
           | describe the same path with fewer points /bezier curves.
           | 
           | Could this approach also help with 3d digitization?
        
       | raphlinus wrote:
       | For the generation of simplified Bezier paths, I hope they
       | consider the new methods in kurbo[1]. These have some fairly
       | fancy math behind them and result in pretty close to a global
       | optimum in terms of the minimal number of segments needed to hit
       | an error target. They _don 't_ do implicit low-pass filtering,
       | rather treat the input as a source of truth, but perhaps options
       | could be added for that.
       | 
       | [1]: https://docs.rs/kurbo/latest/kurbo/simplify/index.html
        
       | Animats wrote:
       | It doesn't seem to do all that well on blueprint type line
       | art.[1] It seems to do a lot better when it has areas to
       | separate. Which is not surprising, considering the approach.
       | 
       | This is about as well as I was doing on scanned engineering
       | drawings in 1983. I wrote Autodesk's CAD/Camera. 20 minutes of
       | compute to process a drawing on an IBM PC/AT. You can be too
       | early. By now, a product in that space should be recognizing not
       | just lines, but dimensions, and generating a properly dimensioned
       | CAD model.
       | 
       | [1]
       | https://github.com/visioncortex/vtracer/blob/master/docs/ima...
        
         | ska wrote:
         | > You can be too early.
         | 
         | Yes, yes you can. I worked on a project than included hardware
         | are related workflow for digitizing analog input to essentially
         | a digital image processing workflow, just because the digital
         | sensors weren't _quite_ there yet. A few years later, they
         | were.
        
       | andrewstuart wrote:
       | This is the most impressive raster to vector I have seen:
       | 
       | https://vectormagic.com
       | 
       | Vtracer doesn't seem to do as well.
        
         | icyfox wrote:
         | This is the best I've found as well. They also have a new
         | offering (different internal model, similar quality evidently)
         | that I've used back when it was in a free unlimited trial. Not
         | sure the status right now: https://vectorizer.ai/
        
         | ChrisMarshallNY wrote:
         | I use Adobe Illustrator for the fairly rare occasions that I
         | need to do it.
         | 
         | Since I already have it, and use it to generate almost all my
         | graphic assets, it makes sense.
        
           | solardev wrote:
           | IME VectorMagic does a much better job on more complex
           | drawings.
        
       ___________________________________________________________________
       (page generated 2023-11-23 23:01 UTC)