diff options
author | Karl Berry <karl@freefriends.org> | 2024-02-29 23:33:33 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2024-02-29 23:33:33 +0000 |
commit | 0a414e9c571e798fd24be3e88ac13d03e332c0ce (patch) | |
tree | b29483d7cb14923bd95ffe5b9ac6373b335446c8 /Master/texmf-dist/asymptote/graph3.asy | |
parent | 09c3fbc6fd99c8dbe9d7552385c134b86bbb1534 (diff) |
asymptote 2.87 support files, windows binary
git-svn-id: svn://tug.org/texlive/trunk@70267 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/asymptote/graph3.asy')
-rw-r--r-- | Master/texmf-dist/asymptote/graph3.asy | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Master/texmf-dist/asymptote/graph3.asy b/Master/texmf-dist/asymptote/graph3.asy index f17b4e97074..b9b872f4511 100644 --- a/Master/texmf-dist/asymptote/graph3.asy +++ b/Master/texmf-dist/asymptote/graph3.asy @@ -1880,6 +1880,27 @@ surface surface(picture pic=currentpicture, real[][] f, real[] x, real[] y, splinetype ysplinetype=xsplinetype, bool[][] cond={}) { + if(xsplinetype == linear && ysplinetype == linear) { + int nx=f.length-1; + int ny=nx > 0 ? f[0].length-1 : 0; + + if(nx == 0 || ny == 0) return nullsurface; + + bool all=cond.length == 0; + + triple[][] v=new triple[nx+1][ny+1]; + + for(int i=0; i <= nx; ++i) { + bool[] condi=all ? null : cond[i]; + real xi=x[i]; + real[] fi=f[i]; + triple[] vi=v[i]; + for(int j=0; j <= ny; ++j) + vi[j]=(xi,y[j],fi[j]); + } + return surface(pic,v,cond); + } + real[][] f=ScaleZ(pic,f); real[] x=map(pic.scale.x.T,x); real[] y=map(pic.scale.y.T,y); |