diff options
Diffstat (limited to 'graphics/asymptote/base/plain_shipout.asy')
-rw-r--r-- | graphics/asymptote/base/plain_shipout.asy | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/graphics/asymptote/base/plain_shipout.asy b/graphics/asymptote/base/plain_shipout.asy index a001ce045c..0fd1b71c7a 100644 --- a/graphics/asymptote/base/plain_shipout.asy +++ b/graphics/asymptote/base/plain_shipout.asy @@ -122,7 +122,8 @@ void shipout(string prefix=defaultfilename, picture pic=currentpicture, string options="", string script="", light light=currentlight, projection P=currentprojection) { - pic.uptodate=true; + projection P=centered(P,pic); + if(!uptodate()) { bool inlinetex=settings.inlinetex; bool prc=prc(format) || settings.v3d; @@ -139,7 +140,7 @@ void shipout(string prefix=defaultfilename, picture pic=currentpicture, settings.inlinetex=settings.inlineimage; } frame f; - transform t=pic.calculateTransform(); + transform t=empty3 ? pic.calculateTransform() : identity; if(currentpicture.fitter == null) { pen background=currentlight.background; if(settings.outformat == "html" && background == nullpen) @@ -152,10 +153,14 @@ void shipout(string prefix=defaultfilename, picture pic=currentpicture, else f=pic.fit(prefix,format,view=view,options,script,light,P); - if(!prconly() && (!pic.empty2() || settings.render == 0 || prc || empty3)) + if(!prconly() && (!pic.empty2() || settings.render == 0 || prc || + pic.queueErase)) { shipout(prefix,orientation(f),format,wait,view,t); + pic.queueErase=false; + } settings.inlinetex=inlinetex; } + pic.uptodate=true; } void newpage(picture pic=currentpicture) |