diff options
Diffstat (limited to 'graphics/asymptote/examples/filesurface.asy')
-rw-r--r-- | graphics/asymptote/examples/filesurface.asy | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/graphics/asymptote/examples/filesurface.asy b/graphics/asymptote/examples/filesurface.asy index b895ec803e..bfa500ebf5 100644 --- a/graphics/asymptote/examples/filesurface.asy +++ b/graphics/asymptote/examples/filesurface.asy @@ -6,16 +6,9 @@ size3(200,IgnoreAspect); file in=input("filesurface.dat").line(); real[] x=in; real[] y=in; - real[][] z=in; -triple f(pair t) { - int i=round(t.x); - int j=round(t.y); - return (x[i],y[j],z[i][j]); -} - -surface s=surface(f,(0,0),(x.length-1,y.length-1),x.length-1,y.length-1); +surface s=surface(z,x,y,linear,linear); real[] level=uniform(min(z)*(1-sqrtEpsilon),max(z)*(1+sqrtEpsilon),4); s.colors(palette(s.map(new real(triple v) {return find(level >= v.z);}), |