130 |
|
|
131 |
void v(ZVec p) const { |
void v(ZVec p) const { |
132 |
if(flags & 4) { |
if(flags & 4) { |
133 |
glColor3f(1, p.z / 60, p.z / 60); |
glColor3f(1, p.z / 100, p.z / 100); |
134 |
} |
} |
135 |
glVertex(p); |
glVertex(p); |
136 |
} |
} |
137 |
|
|
138 |
void vl(ZVec p) const { |
void vl(ZVec p) const { |
139 |
if(flags & 4) { |
if(flags & 4) { |
140 |
glColor3f(1 - p.z / 60, 0, 0); |
glColor3f(0,p.z / 100, p.z / 100); |
141 |
} |
} |
142 |
glVertex(p); |
glVertex(p); |
143 |
} |
} |
172 |
"\n"; |
"\n"; |
173 |
|
|
174 |
FilletSpan sp(ctr, csize, |
FilletSpan sp(ctr, csize, |
175 |
a1, d1, th1, p1.z, |
a1, d1, th1, lerp(p0.z, p1.z, .5), |
176 |
a2, d2, th2, p2.z); |
a2, d2, th2, lerp(p0.z, p2.z, .5)); |
177 |
// Render it. XXX -- jvk, you need to make this |
// Render it. XXX -- jvk, you need to make this |
178 |
// render the solid fillet. |
// render the solid fillet. |
179 |
if(sp.split()) { |
if(sp.split()) { |
197 |
if(flags & 2) { |
if(flags & 2) { |
198 |
glBegin(GL_LINE_STRIP); |
glBegin(GL_LINE_STRIP); |
199 |
for(float f = 0; f < .5; f+= 1.0 / ndice) { |
for(float f = 0; f < .5; f+= 1.0 / ndice) { |
200 |
Vec p = sp.point(f, BlendSimply()); |
ZVec p = sp.point(f, BlendSimply()); |
201 |
vl(p); |
vl(p); |
202 |
} |
} |
203 |
glEnd(); |
glEnd(); |
204 |
glBegin(GL_LINE_STRIP); |
glBegin(GL_LINE_STRIP); |
205 |
for(float f = 1; f > .5; f-= 1.0 / ndice) { |
for(float f = 1; f > .5; f-= 1.0 / ndice) { |
206 |
Vec p = sp.point(f, BlendSimply()); |
ZVec p = sp.point(f, BlendSimply()); |
207 |
vl(p); |
vl(p); |
208 |
} |
} |
209 |
glEnd(); |
glEnd(); |