Closing flame at the top.

This commit is contained in:
Faerbit 2015-03-01 16:11:43 +01:00
parent 81d2de5344
commit 9150c628b4

View File

@ -29,7 +29,10 @@ void main() {
float step = abs(end-begin)/resolution; float step = abs(end-begin)/resolution;
for (float i = begin; i<end; i+=step) { for (float i = begin; i<end; i+=step) {
float downRadius = radiusFunction(i); float downRadius = radiusFunction(i);
float upRadius = radiusFunction(i+step); float upRadius = 0.0f;
if (i != end-step) {
upRadius = radiusFunction(i+step);
}
for (int j = 0; j<resolution; j++) { for (int j = 0; j<resolution; j++) {
float leftAngle = PI * 2.0 / resolution * j; float leftAngle = PI * 2.0 / resolution * j;
float rightAngle = PI * 2.0 / resolution * (j+1); float rightAngle = PI * 2.0 / resolution * (j+1);