Let's say I have some animation stored as a series of frames in list, and I would like to export this so I can show the animation on a web page. I can produce an animated GIF like so (showing a bunch of options I need):

 Image3D[list],   (*All frames stuffed into a single Image3D*)
 "Animation.gif", (*Output file name*)
 "",              (*Comment,none in this case*)
 {0.1},           (*Display duration for each frame*)
 "None",          (*Dithering method,none in this case*)
 100,             (*How many times to play the animation*)
 True,            (*Interlacing*)
 {255, 255, 255}, (*Background color*)
 {255, 255, 255}, (*Transparent color-white*)
 {2}              (*Disposal mode-Restore to background color*)]

My question is: Is there an analogous package that allows me to produce SVG output, so I can get an animated infinite-resolution vector graphic?

  • $\begingroup$ I never heard of such package or command in Mathematica to do animated SVG. Most of the animated SVG I've seen are done using CSS or Javascript. There are external tools that create animated SVG files directly. apparently, there is a way to convert swf to animated SVG file. May be you can look into this. i.e use Mathematica to create swf file, then convert that to svg animation? $\endgroup$ – Nasser Dec 17 '18 at 17:00
  • $\begingroup$ Why not use top level Export[] (with options) to export a GIF? $\endgroup$ – Chip Hurst Dec 18 '18 at 3:30
  • $\begingroup$ Because I want animated vector graphics, not animated bitmaps. $\endgroup$ – Pirx Dec 18 '18 at 3:32
  • $\begingroup$ Exporting to swf and from there converting to animated svg may be an option, if I can find a decent converter. I'll look into it. $\endgroup$ – Pirx Dec 18 '18 at 3:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.