summaryrefslogtreecommitdiff
path: root/Build/source/utils/asymptote/glrender.cc
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-05-18 23:33:08 +0000
committerKarl Berry <karl@freefriends.org>2009-05-18 23:33:08 +0000
commit0a3a4a0193ef03921995cac67f8c91c6e352d059 (patch)
tree4fd204ddd01ff808c75e91ce290a9b28a1e90696 /Build/source/utils/asymptote/glrender.cc
parent7c769b8e95cd5bd87da30c618e5198d6d12461e1 (diff)
asymptote 1.73
git-svn-id: svn://tug.org/texlive/trunk@13217 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/utils/asymptote/glrender.cc')
-rw-r--r--Build/source/utils/asymptote/glrender.cc11
1 files changed, 6 insertions, 5 deletions
diff --git a/Build/source/utils/asymptote/glrender.cc b/Build/source/utils/asymptote/glrender.cc
index 29136c36358..5979aa708ba 100644
--- a/Build/source/utils/asymptote/glrender.cc
+++ b/Build/source/utils/asymptote/glrender.cc
@@ -100,6 +100,7 @@ int minimumsize=50; // Minimum initial rendering window width and height
const double degrees=180.0/M_PI;
const double radians=1.0/degrees;
+double *Background;
size_t Nlights;
triple *Lights;
double *Diffuse;
@@ -180,6 +181,7 @@ void lighting()
void initlighting()
{
+ glClearColor(Background[0],Background[1],Background[2],Background[3]);
glEnable(GL_LIGHTING);
glLightModeli(GL_LIGHT_MODEL_TWO_SIDE,getSetting<bool>("twosided"));
@@ -1062,9 +1064,9 @@ void init()
void glrender(const string& prefix, const picture *pic, const string& format,
double width, double height,
double angle, const triple& m, const triple& M, double *t,
- size_t nlights, triple *lights, double *diffuse,
- double *ambient, double *specular, bool Viewportlighting,
- bool view, int oldpid)
+ double *background, size_t nlights, triple *lights,
+ double *diffuse, double *ambient, double *specular,
+ bool Viewportlighting, bool view, int oldpid)
{
#ifndef __CYGWIN__
Iconify=getSetting<bool>("iconify");
@@ -1081,6 +1083,7 @@ void glrender(const string& prefix, const picture *pic, const string& format,
Picture=pic;
Format=format;
T=t;
+ Background=background;
Nlights=min(nlights,(size_t) GL_MAX_LIGHTS);
Lights=lights;
Diffuse=diffuse;
@@ -1230,8 +1233,6 @@ void glrender(const string& prefix, const picture *pic, const string& format,
initialized=true;
- glClearColor(1.0,1.0,1.0,1.0);
-
glMatrixMode(GL_MODELVIEW);
home();