summaryrefslogtreecommitdiff
path: root/Build/source/utils/asymptote/base/three_surface.asy
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-03-07 18:10:02 +0000
committerKarl Berry <karl@freefriends.org>2017-03-07 18:10:02 +0000
commita6dc131e8a2ff8ce660543a262d771380fdf1b4e (patch)
tree33ab70fd89ae0842cedcfce676aaa6d64a9eb7dc /Build/source/utils/asymptote/base/three_surface.asy
parent78cc0e8d7d1977f9cf5c8c9ba3d9de81ed6e03a3 (diff)
asy 2.40 sources
git-svn-id: svn://tug.org/texlive/trunk@43422 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/utils/asymptote/base/three_surface.asy')
-rw-r--r--Build/source/utils/asymptote/base/three_surface.asy17
1 files changed, 7 insertions, 10 deletions
diff --git a/Build/source/utils/asymptote/base/three_surface.asy b/Build/source/utils/asymptote/base/three_surface.asy
index c6d439e9fb0..6e10246c774 100644
--- a/Build/source/utils/asymptote/base/three_surface.asy
+++ b/Build/source/utils/asymptote/base/three_surface.asy
@@ -1273,13 +1273,15 @@ patch subpatch(patch s, pair a, pair b)
return patch(subpatch(s.P,a,b),s.straight,s.planar);
}
-// return an array containing an intersection times of path p and surface s.
+// return an array containing the times for one intersection of path p and
+// patch s.
real[] intersect(path3 p, patch s, real fuzz=-1)
{
return intersect(p,s.P,fuzz);
}
-// return an array containing an intersection times of path p and surface s.
+// return an array containing the times for one intersection of path p and
+// surface s.
real[] intersect(path3 p, surface s, real fuzz=-1)
{
for(int i=0; i < s.s.length; ++i) {
@@ -1402,14 +1404,9 @@ void draw3D(frame f, int type=0, patch s, triple center=O, material m,
if(prc())
PRCshininess=PRCshininess(m.shininess);
- if(s.triangular)
- drawbeziertriangle(f,s.P,center,s.straight && s.planar,m.p,
- m.opacity,m.shininess,PRCshininess,s.colors,
- interaction.type);
- else
- draw(f,s.P,center,s.straight && s.planar,m.p,m.opacity,m.shininess,
- PRCshininess,s.planar ? s.normal(0.5,0.5) : O,s.colors,
- interaction.type,prc);
+ (s.triangular ? drawbeziertriangle : draw)
+ (f,s.P,center,s.straight && s.planar,m.p,m.opacity,m.shininess,
+ PRCshininess,s.colors,interaction.type,prc);
}
// Draw triangles on a frame.