Activate your free membership today | Log-in

Monday, March 29th, 2010

CanVG: Using Canvas to render SVG files

Category: Canvas, SVG

<p>We love to recursively implement one technology on top of another. We have had Canvas support added to IE via VML, Flash, and Silverlight. We have had SVG implemented in Flash. Flash implemented in SVG.

The latest experiment is from Gabe Lerner and is CanVG. As you can guess, it renders SVG files via the <canvas> element. All in a few hundred lines of code!.

Check out the test playground to see it in action.

canvg

Related Content:

  • SVG
    W3c vector graphics image file...
  • Get ready for HTML5 and canvas elements
    The HTML5 canvas element is a new way to display active graphics and manipulate images with JavaScript. Find out what the new element will mean for...
  • vector graphics rendering (VML)
    Vector graphics rendering, sometimes abbreviated VML, refers to scalable vector graphics (SVG) used in Web...
  • VML
    Vector graphics rendering, sometimes abbreviated VML, refers to scalable vector graphics (SVG) used in Web...
  • SVG
    Return To Castle Wolfenstein Savegame...

Posted by Dion Almaer at 6:23 am
4 Comments

+++--
3.7 rating from 19 votes

4 Comments »

Comments feed TrackBack URI

This is pretty cool, however it borked at all of the SVGs I threw at it, such as that famous tiger image.

Comment by devongovett — March 29, 2010

Yes, canvg has a long way to go. If you can, please reduce the SVGs that cause a problem to a small enough test case and open a bug with the test file.

P.S. Someone should pay attention to the spam on this blog, it’s gotten out of hand lately.

Comment by codedread — March 29, 2010

@devongovett
I’ve been working on a similar parser and… it does render tiger perfectly (but shhh… don’t tell anyone yet :))

Comment by kangax — March 29, 2010

I knew this was possible! With this, you can rasterize SVG and export to PNG.

Comment by westonruter — March 29, 2010

Leave a comment

You must be logged in to post a comment.