I have read Animations in LaTeX, but my question (I think) is different.

I have an SVG animated file and I want to create the same animation in LaTeX, without rewriting the code. An example is this one (created with Inskape). I have tried to obtain the PDF from Inkscape, but in this way I lost the animation.

Apologize if this question is a duplicate.


I am looking for a LaTeX code. ;-)

  • +1 I didn't know that SVG supported animations. I couldn't see or edit the animation with Inkscape by the way. I opened the SVG in an editor, and it says "inkscape:version="0.48.4 r9939". I also found some It has some "<animatation>" XML tags. It is possible that this is not really SVG but some XML hack for web browsers because I see it is also interactive. – alfC Feb 9 '16 at 10:12
  • 2
    @alfC BTW, animate can now export to animated SVG. (Though not import, as asked here.) – AlexG Dec 3 '18 at 9:07
  • 2
    @alfC: No. Exporting to JS driven animated SVG is a new feature, added about 10 days ago ;). Same look and feel (control buttons, interactivity) as PDF animations. Can be embedded in HTML or viewed as standalone files in a Web browser. See: tex.stackexchange.com/a/136919 for a trivial example and click on the image to load the SVG. – AlexG Dec 3 '18 at 9:45
  • 2
    @AlexG, excellent, dvisvgm (which I didn't know) was the answer. Congratulations for the new feature. – alfC Dec 3 '18 at 17:34
  • 2
    PDF anims are frame-based, while SMIL-type SVG animations animate object properties, such as position, scale, colour, transparency. An external programme is needed to convert such into image sequences. I don't know whether Inkscape (or other software) is able to do this. – AlexG Dec 28 '18 at 13:16

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.