1

I am trying to generate svg file from a multipage pdf using 'aniamte' package but without success!

\documentclass[dvisvgm]{standalone}
   \usepackage{animate}
   \usepackage{graphicx}    
   \begin{document}
     \animategraphics[controls]{0.75}{mymultipagepdf}{}{}
   \end{document} 

I run xelatex -no-pdf main.tex

then dvisvgm --font-format=woff --exact --zoom=-1 --page=1 main.xdv

I got the following svg file which is not displayed in the my browsers (firefox nor chromium):

<?xml version='1.0' encoding='UTF-8'?>
<!-- This file was generated by dvisvgm 3.0.3 -->
<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='-72.000004 -72.000009 283 297.780925'>
<g id='page1'>
<!-- animation by LaTeX-package `animate', https://ctan.org/tex-archive/macros/latex/contrib/animate, v. 2023/06/18 -->
<defs>
<g class='xform' id='_obj0' transform='translate(72.000004,-209.999991)'>
</g>
</defs>
<defs>
<g class='xform' id='_obj1' transform='translate(72.000004,-209.999991)'>
</g>
</defs>
<defs>
<g class='xform' id='_obj2' transform='translate(72.000004,-209.999991)'>
</g>
</defs>
<defs>
<g class='xform' id='_obj3' transform='translate(72.000004,-209.999991)'>
</g>
</defs>
<svg height='281.9993' overflow='hidden' viewBox='-72.000004 -71.999309 282.9993 281.9993' width='282.9993' x='-72.000004' y='-71.999309'>
<g class='ocg' id='_0.0'>
<use transform='matrix(1 0 0 1 0 0)' x='-72.000004' xlink:href='#_obj0' y='209.999991'/>
</g>
<g class='ocg' id='_0.1' visibility='hidden'>
<use transform='matrix(1 0 0 1 0 0)' x='-72.000004' xlink:href='#_obj1' y='209.999991'/>
</g>
<g class='ocg' id='_0.2' visibility='hidden'>
<use transform='matrix(1 0 0 1 0 0)' x='-72.000004' xlink:href='#_obj2' y='209.999991'/>
</g>
<g class='ocg' id='_0.3' visibility='hidden'>
<use transform='matrix(1 0 0 1 0 0)' x='-72.000004' xlink:href='#_obj3' y='209.999991'/>
</g>
</svg>
<defs>
<script type='text/javascript'>
<![CDATA[
var a0_idx;
var a0_on;
var a0_fr;
var a0_btnPauseLeft,a0_btnPlayLeft,a0_btnPauseRight,a0_btnPlayRight;
var a0_playsRight,a0_isPaused,a0_playing;
var a0_int;
var a0_pause,a0_playRight,a0_playLeft,a0_playBwd,a0_playFwd;
var a0_fps,a0_spd;
var a0_setFps;
var a0_seekFrame,a0_gotoNext,a0_gotoPrev;
var a0_stopFirst,a0_stopLast;
var a0_playPauseBwd,a0_playPauseFwd;
var a0_stepBwd,a0_stepFwd;
var a0_spdIncr,a0_spdDecr,a0_spdReset;
(function(){
function onload(){
if(!a0_fr){
a0_fr=new Array();
a0_on=0;
var ocg=document.getElementsByClassName('ocg');
for(var i=0;i<ocg.length;i++){
var ocgName=ocg[i].getAttribute('id').slice(1).split('.');
if(ocgName[0]==0){
a0_fr[ocgName[1]]=ocg[i];
}
}
a0_btnPauseLeft=document.getElementById('_0.PauseLeft');
a0_btnPlayLeft=document.getElementById('_0.PlayLeft');
a0_btnPauseRight=document.getElementById('_0.PauseRight');
a0_btnPlayRight=document.getElementById('_0.PlayRight');
a0_playsRight=true;
a0_isPaused=false;
a0_playing=false;
a0_fps=0.75;
a0_spd=1;
a0_setFps=function(f){
a0_fps=(f==0?1e-6:f);
if(a0_playing){
if(a0_playsRight){a0_playRight();}else{a0_playLeft();}
}
};
a0_seekFrame=function(f){
if(f>3||f<0){return -1;}
a0_idx=f;
a0_fr[a0_on].setAttribute('visibility','hidden');
a0_fr[f].setAttribute('visibility','visible');
a0_on=f;
return 0;
};
a0_stopFirst=function(){a0_pause(true);a0_seekFrame(0);};
a0_stopLast=function(){a0_pause(true);a0_seekFrame(3);};
a0_gotoNext=function(){
if(a0_seekFrame(a0_idx+1)<0){
a0_stopLast();
}
};
a0_gotoPrev=function(){
if(a0_seekFrame(a0_idx-1)<0){
a0_stopFirst();
}
};
a0_pause=function(stop){
try{clearInterval(a0_int);}catch(e){}
a0_playing=false;
a0_isPaused=!stop;
a0_btnPauseLeft.setAttribute('visibility','hidden');
a0_btnPlayLeft.setAttribute('visibility','visible');
a0_btnPauseRight.setAttribute('visibility','hidden');
a0_btnPlayRight.setAttribute('visibility','visible');
};
a0_playRight=function(){
var tmp_int;
try{tmp_int=setInterval('a0_gotoNext()',1000/a0_fps/a0_spd);}catch(e){}
try{clearInterval(a0_int);}catch(e){}
a0_int=tmp_int;
a0_playsRight=true;
a0_playing=true;
a0_isPaused=false;
a0_btnPauseLeft.setAttribute('visibility','visible');
a0_btnPlayLeft.setAttribute('visibility','hidden');
a0_btnPauseRight.setAttribute('visibility','visible');
a0_btnPlayRight.setAttribute('visibility','hidden');
};
a0_playLeft=function(){
var tmp_int;
try{tmp_int=setInterval('a0_gotoPrev()',1000/a0_fps/a0_spd);}catch(e){}
try{clearInterval(a0_int);}catch(e){}
a0_int=tmp_int;
a0_playsRight=false;
a0_playing=true;
a0_isPaused=false;
a0_btnPauseLeft.setAttribute('visibility','visible');
a0_btnPlayLeft.setAttribute('visibility','hidden');
a0_btnPauseRight.setAttribute('visibility','visible');
a0_btnPlayRight.setAttribute('visibility','hidden');
};
a0_playPauseBwd=function(){if(a0_playing){a0_pause();}else{a0_playBwd();}};
a0_playPauseFwd=function(){if(a0_playing){a0_pause();}else{a0_playFwd();}};
a0_spdIncr=function(){a0_spd*=1.1;a0_setFps(a0_fps);};
a0_spdDecr=function(){a0_spd/=1.1;a0_setFps(a0_fps);};
a0_spdReset=function(){a0_spd=1;a0_setFps(a0_fps);};
a0_stepBwd=function(){if(!a0_playing){a0_seekFrame(a0_idx-1);a0_isPaused=true;}};
a0_stepFwd=function(){if(!a0_playing){a0_seekFrame(a0_idx+1);a0_isPaused=true;}};
a0_playBwd=function(){if(a0_idx==0){a0_stopLast();}a0_playLeft();};
a0_playFwd=function(){if(a0_idx==3){a0_stopFirst();}a0_playRight();};
a0_seekFrame(0);
}
document.getElementById('anm0').addEventListener('mouseup',onMouseUpWdgt);
document.getElementById('anm0').addEventListener('mousedown',onMouseDownWdgt);
document.getElementById('anm0').addEventListener('touchend',onTouchEndWdgt);
onvisible();
}
function onvisible(){
}
function onhidden(){
if(a0_playing){a0_pause(true);}
if(!a0_isPaused)a0_playsRight=true;
if(!a0_isPaused&&a0_idx!=0)a0_seekFrame(0);
}
function onVisibilityChange(){
if(document.hidden){try{onhidden();}catch(e){}}else{try{onvisible();}catch(e){}}
}
document.addEventListener('visibilitychange',onVisibilityChange);
window.addEventListener('load',onload);
function onWidgetUpAction(event){
try{
if(event.shiftKey)a0_playsRight=!a0_playsRight;
var doplay=true;
if(a0_idx==3&&a0_playsRight){a0_stopFirst();}
if(a0_idx==0&&!a0_playsRight){a0_stopLast();}
if(doplay){if(a0_playsRight){a0_playRight();}else{a0_playLeft();}}
}catch(e){}
}
function onTouchEndWdgt(event){
event.preventDefault();event.stopPropagation();
if(a0_playing){try{a0_pause();}catch(e){}}else{
try{
if(event.shiftKey)a0_playsRight=!a0_playsRight;
var doplay=true;
if(a0_idx==3&&a0_playsRight){a0_stopFirst();}
if(a0_idx==0&&!a0_playsRight){a0_stopLast();}
if(doplay){if(a0_playsRight){a0_playRight();}else{a0_playLeft();}}
}catch(e){}
}
}
function onMouseDownWdgt(event){
event.preventDefault();event.stopPropagation();
try{if(a0_playing){a0_pause();}}catch(e){}
}
function onMouseUpWdgt(event){
event.preventDefault();event.stopPropagation();
onWidgetUpAction(event);
}
})();
]]>
</script>
</defs>
<path class='annot' cursor='pointer' d='M-72.000004 209.999991H210.999995V-72.000004H-72.000004Z' id='anm0' opacity='0'/>
<defs>
<g class='xform' id='_obj4' transform='translate(-2.790029,-225.780916)'>
<g transform='translate(2.790029,225.780916)scale(0.95645,0.95645)scale(-1)translate(2.790029,225.780916)scale(-1)'>
<path d='M11.28903 224.781244H14.78903C15.8906 224.781244 16.78903 223.88281 16.78903 222.78124V219.28124V213.7812C16.78903 212.6797 15.8906 211.7812 14.78903 211.7812H11.28903H5.789C4.6875 211.7812 3.789 212.6797 3.789 213.7812V219.28124V222.78124C3.789 223.88281 4.6875 224.781244 5.789 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M13.28903 221.08203L9.19138 218.28124L13.28903 215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M7.789 221.08203V215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='2.790029' xlink:href='#_obj4' y='225.780916'/>
<path class='annot' cursor='pointer' d='M2.790029 225.780916H17.136255V211.434689H2.790029Z' onmousedown='event.preventDefault();event.stopPropagation();a0_stopFirst();' opacity='0'/>
<defs>
<g class='xform' id='_obj5' transform='translate(-17.136255,-225.780916)'>
<g transform='translate(17.136255,225.780916)scale(0.95645,0.95645)scale(-1)translate(17.136255,225.780916)scale(-1)'>
<path d='M25.63672 224.781244H29.13672C30.23828 224.781244 31.13672 223.88281 31.13672 222.78124V219.28124V213.7812C31.13672 212.6797 30.23828 211.7812 29.13672 211.7812H25.63672H20.1367C19.0352 211.7812 18.1367 212.6797 18.1367 213.7812V219.28124V222.78124C18.1367 223.88281 19.0352 224.781244 20.1367 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M26.63672 221.08203L22.53516 218.28124L26.63672 215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='17.136255' xlink:href='#_obj5' y='225.780916'/>
<path class='annot' cursor='pointer' d='M17.136255 225.780916H31.482481V211.434689H17.136255Z' onmousedown='event.preventDefault();event.stopPropagation();a0_stepBwd();' opacity='0'/>
<defs>
<g class='xform' id='_obj6' transform='translate(-31.482481,-225.780916)'>
<g transform='translate(31.482481,225.780916)scale(0.95645,0.95645)scale(-1)translate(31.482481,225.780916)scale(-1)'>
<path d='M46.484377 224.781244H34.4844C33.3828 224.781244 32.4844 223.88281 32.4844 222.78124V219.28124V213.7812C32.4844 212.6797 33.3828 211.7812 34.4844 211.7812H46.484377' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M44.28125 221.78124V214.7812' stroke='#000' fill='none' stroke-width='2' stroke-miterlimit='10' stroke-linejoin='bevel'/>
</g>
</g>
</defs>
<g class='ocg' id='_0.PauseLeft' visibility='hidden'>
<use transform='matrix(1 0 0 1 0 0)' x='31.482481' xlink:href='#_obj6' y='225.780916'/>
</g>
<defs>
<g class='xform' id='_obj7' transform='translate(-31.482481,-225.780916)'>
<g transform='translate(31.482481,225.780916)scale(0.95645,0.95645)scale(-1)translate(31.482481,225.780916)scale(-1)'>
<path d='M46.484377 224.781244H34.4844C33.3828 224.781244 32.4844 223.88281 32.4844 222.78124V219.28124V213.7812C32.4844 212.6797 33.3828 211.7812 34.4844 211.7812H46.484377' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M46.484377 211.7812V224.781244' stroke='#000' fill='none' stroke-width='.1' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M41.48438 221.78124V214.7812L36.48438 218.28124Z' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
</g>
</g>
</defs>
<g class='ocg' id='_0.PlayLeft'>
<use transform='matrix(1 0 0 1 0 0)' x='31.482481' xlink:href='#_obj7' y='225.780916'/>
</g>
<path class='annot' cursor='pointer' d='M31.482481 225.780916H45.828707V211.434689H31.482481Z' onmousedown='event.preventDefault();event.stopPropagation();a0_playPauseBwd();' opacity='0'/>
<defs>
<g class='xform' id='_obj8' transform='translate(-45.828707,-225.780916)'>
<g transform='translate(45.828707,225.780916)scale(0.95645,0.95645)scale(-1)translate(45.828707,225.780916)scale(-1)'>
<path d='M45.828124 224.781244H57.8281C58.9297 224.781244 59.8281 223.88281 59.8281 222.78124V219.28124V213.7812C59.8281 212.6797 58.9297 211.7812 57.8281 211.7812H45.828124' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M48.02734 221.78124V214.7812' stroke='#000' fill='none' stroke-width='2' stroke-miterlimit='10' stroke-linejoin='bevel'/>
</g>
</g>
</defs>
<g class='ocg' id='_0.PauseRight' visibility='hidden'>
<use transform='matrix(1 0 0 1 0 0)' x='45.828707' xlink:href='#_obj8' y='225.780916'/>
</g>
<defs>
<g class='xform' id='_obj9' transform='translate(-45.828707,-225.780916)'>
<g transform='translate(45.828707,225.780916)scale(0.95645,0.95645)scale(-1)translate(45.828707,225.780916)scale(-1)'>
<path d='M45.828124 224.781244H57.8281C58.9297 224.781244 59.8281 223.88281 59.8281 222.78124V219.28124V213.7812C59.8281 212.6797 58.9297 211.7812 57.8281 211.7812H45.828124' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M45.828124 211.7812V224.781244' stroke='#000' fill='none' stroke-width='.1' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M50.82812 221.78124V214.7812L55.82812 218.28124Z' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
</g>
</g>
</defs>
<g class='ocg' id='_0.PlayRight'>
<use transform='matrix(1 0 0 1 0 0)' x='45.828707' xlink:href='#_obj9' y='225.780916'/>
</g>
<path class='annot' cursor='pointer' d='M45.828707 225.780916H60.174933V211.434689H45.828707Z' onmousedown='event.preventDefault();event.stopPropagation();a0_playPauseFwd();' opacity='0'/>
<defs>
<g class='xform' id='_obj10' transform='translate(-60.174933,-225.780916)'>
<g transform='translate(60.174933,225.780916)scale(0.95645,0.95645)scale(-1)translate(60.174933,225.780916)scale(-1)'>
<path d='M66.67578 224.781244H63.17578C62.07422 224.781244 61.17578 223.88281 61.17578 222.78124V219.28124V213.7812C61.17578 212.6797 62.07422 211.7812 63.17578 211.7812H66.67578H72.1758C73.2773 211.7812 74.1758 212.6797 74.1758 213.7812V219.28124V222.78124C74.1758 223.88281 73.2773 224.781244 72.1758 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M65.67578 221.08203L69.77344 218.28124L65.67578 215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='60.174933' xlink:href='#_obj10' y='225.780916'/>
<path class='annot' cursor='pointer' d='M60.174933 225.780916H74.521159V211.434689H60.174933Z' onmousedown='event.preventDefault();event.stopPropagation();a0_stepFwd();' opacity='0'/>
<defs>
<g class='xform' id='_obj11' transform='translate(-74.521159,-225.780916)'>
<g transform='translate(74.521159,225.780916)scale(0.95645,0.95645)scale(-1)translate(74.521159,225.780916)scale(-1)'>
<path d='M81.01953 224.781244H77.51953C76.41797 224.781244 75.519529 223.88281 75.519529 222.78124V219.28124V213.7812C75.519529 212.6797 76.41797 211.7812 77.51953 211.7812H81.01953H86.5195C87.6211 211.7812 88.5195 212.6797 88.5195 213.7812V219.28124V222.78124C88.5195 223.88281 87.6211 224.781244 86.5195 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M79.01953 221.08203L83.12109 218.28124L79.01953 215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M84.51953 221.08203V215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='74.521159' xlink:href='#_obj11' y='225.780916'/>
<path class='annot' cursor='pointer' d='M74.521159 225.780916H88.867385V211.434689H74.521159Z' onmousedown='event.preventDefault();event.stopPropagation();a0_stopLast();' opacity='0'/>
<defs>
<g class='xform' id='_obj12' transform='translate(-93.171283,-225.780916)'>
<g transform='translate(93.171283,225.780916)scale(0.95645,0.95645)scale(-1)translate(93.171283,225.780916)scale(-1)'>
<path d='M99.67187 224.781244H96.17187C95.07031 224.781244 94.17187 223.88281 94.17187 222.78124V219.28124V213.7812C94.17187 212.6797 95.07031 211.7812 96.17187 211.7812H99.67187H105.1719C106.2734 211.7812 107.1719 212.6797 107.1719 213.7812V219.28124V222.78124C107.1719 223.88281 106.2734 224.781244 105.1719 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M97.87109 218.28124H103.4727' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linejoin='bevel'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='93.171283' xlink:href='#_obj12' y='225.780916'/>
<path class='annot' cursor='pointer' d='M93.171283 225.780916H107.517509V211.434689H93.171283Z' onmousedown='event.preventDefault();event.stopPropagation();a0_spdDecr();' opacity='0'/>
<defs>
<g class='xform' id='_obj13' transform='translate(-107.517509,-225.780916)'>
<g transform='translate(107.517509,225.780916)scale(0.95645,0.95645)scale(-1)translate(107.517509,225.780916)scale(-1)'>
<path d='M114.01953 224.781244H110.51953C109.41797 224.781244 108.51953 223.88281 108.51953 222.78124V219.28124V213.7812C108.51953 212.6797 109.41797 211.7812 110.51953 211.7812H114.01953H119.5195C120.6211 211.7812 121.5195 212.6797 121.5195 213.7812V219.28124V222.78124C121.5195 223.88281 120.6211 224.781244 119.5195 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M115.01953 221.08203V215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M111.01953 220.78124L114.51953 218.28124L111.01953 215.78124Z'/>
<path d='M119.0195 220.78124L115.51953 218.28124L119.0195 215.78124Z'/>
<path d='M110.51953 218.28124H111.01953M119.5195 218.28124H119.0195' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linecap='square'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='107.517509' xlink:href='#_obj13' y='225.780916'/>
<path class='annot' cursor='pointer' d='M107.517509 225.780916H121.863735V211.434689H107.517509Z' onmousedown='event.preventDefault();event.stopPropagation();a0_spdReset();' opacity='0'/>
<defs>
<g class='xform' id='_obj14' transform='translate(-121.863735,-225.780916)'>
<g transform='translate(121.863735,225.780916)scale(0.95645,0.95645)scale(-1)translate(121.863735,225.780916)scale(-1)'>
<path d='M128.36328 224.781244H124.86328C123.76172 224.781244 122.863283 223.88281 122.863283 222.78124V219.28124V213.7812C122.863283 212.6797 123.76172 211.7812 124.86328 211.7812H128.36328H133.8633C134.9648 211.7812 135.8633 212.6797 135.8633 213.7812V219.28124V222.78124C135.8633 223.88281 134.9648 224.781244 133.8633 224.781244Z' stroke='#000' fill='none' stroke-width='.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/>
<path d='M126.5625 218.28124H132.1641M129.36328 221.08203V215.4805' stroke='#000' fill='none' stroke-miterlimit='10' stroke-linejoin='bevel'/>
</g>
</g>
</defs>
<use transform='matrix(1 0 0 1 0 0)' x='121.863735' xlink:href='#_obj14' y='225.780916'/>
<path class='annot' cursor='pointer' d='M121.863735 225.780916H136.209962V211.434689H121.863735Z' onmousedown='event.preventDefault();event.stopPropagation();a0_spdIncr();' opacity='0'/>
</g>
</svg>
10
  • 2
    As we don't know your mymultipagepdf it is hard to say a lot. But if I do the same with example-image-a4-numbered instead of mymultipagepdf, it does work and, e.g., firefox shows the red page number 1 with the controls.
    – cabohah
    Nov 13, 2023 at 16:33
  • I tested with example-movie.pdf, also part of pkg mwe, and the SVG output made with OP's workflow looks and runs as normal in Chromium. Using TeXLive 2023 (dvisvgm 3.0.3) and Ghostscript 10.02.0 on Linux.
    – AlexG
    Nov 13, 2023 at 16:41
  • 1
    Could you, perhaps, make your PDF available for download somewhere?
    – AlexG
    Nov 13, 2023 at 16:48
  • @AlexG mymultipagepdf generated with asymptote Nov 13, 2023 at 19:22
  • @cabohah I have updated the post with a link to the pdf file I have used! Nov 13, 2023 at 19:29

1 Answer 1

1

dvisvgm relies on external software to convert PDF to SVG code. Formerly, it used Ghostscript. But recently, Ghostscript got a new PDF interpreter that is no more compatible with the needs of dvisvgm. Therefore, M. Gieseking, the developer of dvisvgm, had to resort to an alternative PDF interpreter, which is mutool. It is part of the MuPDF software package and is open-source. It is available as precompiled binary pkgs for Windows and other platforms, but also as source code. On Linux, use the system's package manager to install MuPDF. The upstream download site is: https://mupdf.com/releases/

The dvisvgm manual says that mutool is automatically chosen as PDF interpreter if it is found in the search PATH for binaries: https://dvisvgm.de/Manpage/dvisvgm.pdf#page=9

Also, acc. to the manual, the use of mutool can be enforced via the environment variable DVISVGM_PDF_PROC. Invoke dvisvgm as

DVISVGM_PDF_PROC=mutool dvisvgm ...

on the command line.

16
  • mutool 1.23 was already installed on my system. Since you have mutool 1.22 I will downgrade and try again! May be ??? Nov 13, 2023 at 20:47
  • Don't think that downgrading MuPDF is needed. It is rather a settings issue of dvisvgm.
    – AlexG
    Nov 13, 2023 at 20:49
  • So what can I do? Nov 13, 2023 at 20:56
  • Are you on Linux? Can mutool be invoked on the command line? See the link to the dvisvgm manual at the end of my answer.
    – AlexG
    Nov 13, 2023 at 21:00
  • 1
    Sorry, then I fear you need to update dvisvgm.
    – Martin
    Nov 14, 2023 at 10:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .