496 |
496 |
497 // ============================================================================= |
497 // ============================================================================= |
498 // ----------------------------------------------------------------------------- |
498 // ----------------------------------------------------------------------------- |
499 LDFile* generatePrimitive (PrimitiveType type, int segs, int divs, int num) |
499 LDFile* generatePrimitive (PrimitiveType type, int segs, int divs, int num) |
500 { // Make the description |
500 { // Make the description |
501 str frac = ftoa ( ( (float) segs) / divs); |
501 str frac = str::number ((float) segs / divs); |
502 str name = radialFileName (type, segs, divs, num); |
502 str name = radialFileName (type, segs, divs, num); |
503 str descr; |
503 str descr; |
504 |
504 |
505 // Ensure that there's decimals, even if they're 0. |
505 // Ensure that there's decimals, even if they're 0. |
506 if (frac.indexOf (".") == -1) |
506 if (frac.indexOf (".") == -1) |