StelGeometryBuilder.cpp   StelGeometryBuilder.cpp 
skipping to change at line 294 skipping to change at line 294
const float cosSinRho1 = cosSinRho[1]; const float cosSinRho1 = cosSinRho[1];
float s = flipTexture ? 1.0f : 0.0f; float s = flipTexture ? 1.0f : 0.0f;
const float* cosSinTheta = COS_SIN_THETA; const float* cosSinTheta = COS_SIN_THETA;
// Used to bake light colors into lit spheres' verti ces // Used to bake light colors into lit spheres' verti ces
Vec4f color; Vec4f color;
for (int slice = 0; slice <= slices; ++slice) for (int slice = 0; slice <= slices; ++slice)
{ {
const Vec3f v(-cosSinTheta[1] * cosSinRho1, const Vec3f v(-cosSinTheta[1] * cosSinRho1,
cosSinTheta[0] * cosSinRho1, cosSinTheta[0] * cosSinRho1,
nsign * cosSinRho0 * oneMinusO blateness); nsign * cosSinRho0 * oneMinusO blateness);
if(lit) if(lit)
{ {
const float c = const float c =
std::max(0.0, nsign * (light Pos[0] * v[0] * oneMinusOblateness + std::max(0.0, nsign * (light Pos[0] * v[0] * oneMinusOblateness +
light light
Pos[1] * v[1] * oneMinusOblateness + Pos[1] * v[1] * oneMinusOblateness +
light light
Pos[2] * v[2] / oneMinusOblateness)); Pos[2] * v[2] / oneMinusOblateness));
const Vec4f color = std::min(c, 0.5f ) * diffuseLight + ambientLight; const Vec4f color = std::min(c, 0.5f ) * diffuseLight + ambientLight;
litVertices->addVertex(VertexP3T2C4( v * radius, Vec2f(s, t), color)); litVertices->addVertex(VertexP3T2C4( v * radius, Vec2f(s, t), color));
} }
else else
{ {
unlitVertices->addVertex(VertexP3T2( v * radius, Vec2f(s, t))); unlitVertices->addVertex(VertexP3T2( v * radius, Vec2f(s, t)));
} }
s += ds; s += ds;
cosSinTheta += 2; cosSinTheta += 2;
} }
 End of changes. 2 change blocks. 
5 lines changed or deleted 5 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/