summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/asymptote/plain_prethree.asy
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2022-02-27 23:41:11 +0000
committerKarl Berry <karl@freefriends.org>2022-02-27 23:41:11 +0000
commit8027f287eb46d487a0e379911bdbc4d6c2bf44e4 (patch)
treeb6e3aeebab3f5c2560ae1ab892b76cca269eb05e /Master/texmf-dist/asymptote/plain_prethree.asy
parenta4855ce49e2101557c17547c2d22594e1b2a215c (diff)
asymptote 2.78 support files
git-svn-id: svn://tug.org/texlive/trunk@62265 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/asymptote/plain_prethree.asy')
-rw-r--r--Master/texmf-dist/asymptote/plain_prethree.asy13
1 files changed, 6 insertions, 7 deletions
diff --git a/Master/texmf-dist/asymptote/plain_prethree.asy b/Master/texmf-dist/asymptote/plain_prethree.asy
index 968ae2943a6..88663962557 100644
--- a/Master/texmf-dist/asymptote/plain_prethree.asy
+++ b/Master/texmf-dist/asymptote/plain_prethree.asy
@@ -76,7 +76,7 @@ struct projection {
bool center=false; // Center target within bounding volume?
int ninterpolate; // Used for projecting nurbs to 2D Bezier curves.
bool bboxonly=true; // Typeset label bounding box only.
-
+
transformation T;
void calculate() {
@@ -137,8 +137,8 @@ struct projection {
(M.x,m.y,m.z),(M.x,m.y,M.z),(M.x,M.y,m.z),M};
return max(abs(c-target));
}
-
-
+
+
// This is redefined here to make projection as self-contained as possible.
static private real sqrtEpsilon = sqrt(realEpsilon);
@@ -161,7 +161,7 @@ projection currentprojection;
struct light {
real[][] diffuse;
- real[][] specular;
+ real[][] specular; // For PRC only
pen background=nullpen; // Background color of the 3D canvas.
real specularfactor;
triple[] position; // Only directional lights are currently implemented.
@@ -169,14 +169,14 @@ struct light {
transform3 T=identity(4); // Transform to apply to normal vectors.
bool on() {return position.length > 0;}
-
+
void operator init(pen[] diffuse,
pen[] specular=diffuse, pen background=nullpen,
real specularfactor=1,
triple[] position) {
int n=diffuse.length;
assert(specular.length == n && position.length == n);
-
+
this.diffuse=new real[n][];
this.specular=new real[n][];
this.background=background;
@@ -213,4 +213,3 @@ struct light {
}
light currentlight;
-