12 glBegin( GL_TRIANGLE_FAN );
14 glMaterialfv(GL_FRONT, GL_DIFFUSE, m.
diffuse);
15 glMaterialfv(GL_FRONT, GL_SPECULAR, m.
specular);
16 glMaterialf(GL_FRONT, GL_SHININESS, m.
shinyness );
19 glVertex3fv( south_pole );
20 for (
int x = 0; x <=
NLON; ++x )
28 for (
int y = 1; y <
NLAT - 1; ++y )
30 glBegin( GL_QUAD_STRIP);
32 glMaterialfv(GL_FRONT, GL_DIFFUSE, m.
diffuse);
33 glMaterialfv(GL_FRONT, GL_SPECULAR, m.
specular);
34 glMaterialf(GL_FRONT, GL_SHININESS, m.
shinyness );
35 for (
int x = 0; x <=
NLON; ++x )
47 glBegin( GL_TRIANGLE_FAN );
49 glMaterialfv(GL_FRONT, GL_DIFFUSE, m.
diffuse);
50 glMaterialfv(GL_FRONT, GL_SPECULAR, m.
specular);
51 glMaterialf(GL_FRONT, GL_SHININESS, m.
shinyness );
54 glVertex3fv( north_pole );
55 for (
int x =
NLON; x >= 0; --x )
67 static const Real conv_deg_rad = 2.0 * M_PI / 360.0;
68 latitude *= conv_deg_rad;
69 longitude *= conv_deg_rad;
71 + radius *
Point3( cos( longitude ) * cos( latitude ),
72 sin( longitude ) * cos( latitude ),