| 968 |
|
datin = in; |
| 969 |
|
strcpy(tltname, dfltname); |
| 970 |
|
} else { |
| 971 |
< |
/* If the line is "TILE=<filename>", use that file |
| 971 |
> |
/* If the line is "TILT=<filename>", use that file |
| 972 |
|
* name as the source of tilt data. */ |
| 973 |
|
if (ISDIRSEP(tltspec[0])) |
| 974 |
|
strcpy(buf, tltspec); |
| 1125 |
|
/* Output distribution "brightdata" primitive. Start handling |
| 1126 |
|
the various cases of symmetry of the distribution. */ |
| 1127 |
|
strcat(strcpy(id, filename(name)), "_dist"); |
| 1128 |
< |
fprintf(out, "\n%s brightdata %s\n", mod, id); |
| 1128 |
> |
fprintf(out, "\n'%s' brightdata '%s'\n", mod, id); |
| 1129 |
|
if (nangles[1] < 2) |
| 1130 |
|
fprintf(out, "4 "); |
| 1131 |
|
else if (pmtype == PM_B) |
| 1143 |
|
dosides = (doupper & dolower && sinf->h > MINDIM); /* Sides */ |
| 1144 |
|
|
| 1145 |
|
/* Select the appropriate function and parameters from source.cal */ |
| 1146 |
< |
fprintf(out, "%s %s source.cal ", |
| 1146 |
> |
fprintf(out, "%s '%s' source.cal ", |
| 1147 |
|
sinf->type==SPHERE ? "corr" : |
| 1148 |
|
!dosides ? "flatcorr" : |
| 1149 |
|
sinf->type==DISK ? "cylcorr" : "boxcorr", |
| 1213 |
|
/* First, describe the light. If a materials and geometry |
| 1214 |
|
* file is given, generate an illum instead. */ |
| 1215 |
|
strcat(strcpy(lname, name), "_light"); |
| 1216 |
< |
fprintf(fp, "\n%s %s %s\n", mod, |
| 1216 |
> |
fprintf(fp, "\n'%s' %s '%s'\n", mod, |
| 1217 |
|
shp->isillum ? "illum" : "light", lname); |
| 1218 |
|
fprintf(fp, "0\n0\n3 %g %g %g\n", |
| 1219 |
|
lampcolor[0], lampcolor[1], lampcolor[2]); |
| 1425 |
|
int d |
| 1426 |
|
) |
| 1427 |
|
{ |
| 1428 |
< |
fprintf(fp, "\n%s polygon %s%s\n0\n0\n12\n", mod, name, suffix); |
| 1428 |
> |
fprintf(fp, "\n'%s' polygon '%s%s'\n0\n0\n12\n", mod, name, suffix); |
| 1429 |
|
putpoint(shp, fp, a); |
| 1430 |
|
putpoint(shp, fp, b); |
| 1431 |
|
putpoint(shp, fp, c); |
| 1470 |
|
) |
| 1471 |
|
{ |
| 1472 |
|
if (up) { |
| 1473 |
< |
fprintf(fp, "\n%s ring %s.u\n", mod, name); |
| 1473 |
> |
fprintf(fp, "\n'%s' ring '%s.u'\n", mod, name); |
| 1474 |
|
fprintf(fp, "0\n0\n8\n"); |
| 1475 |
|
fprintf(fp, "\t0 0 %g\n", .5*shp->h*meters2out); |
| 1476 |
|
fprintf(fp, "\t0 0 1\n"); |
| 1477 |
|
fprintf(fp, "\t0 %g\n", .5*shp->w*meters2out); |
| 1478 |
|
} else { |
| 1479 |
< |
fprintf(fp, "\n%s ring %s.d\n", mod, name); |
| 1479 |
> |
fprintf(fp, "\n'%s' ring '%s.d'\n", mod, name); |
| 1480 |
|
fprintf(fp, "0\n0\n8\n"); |
| 1481 |
|
fprintf(fp, "\t0 0 %g\n", -.5*shp->h*meters2out); |
| 1482 |
|
fprintf(fp, "\t0 0 -1\n"); |
| 1493 |
|
char *name |
| 1494 |
|
) |
| 1495 |
|
{ |
| 1496 |
< |
fprintf(fp, "\n%s cylinder %s.c\n", mod, name); |
| 1496 |
> |
fprintf(fp, "\n'%s' cylinder '%s.c'\n", mod, name); |
| 1497 |
|
fprintf(fp, "0\n0\n7\n"); |
| 1498 |
|
fprintf(fp, "\t0 0 %g\n", .5*shp->h*meters2out); |
| 1499 |
|
fprintf(fp, "\t0 0 %g\n", -.5*shp->h*meters2out); |
| 1510 |
|
char *name |
| 1511 |
|
) |
| 1512 |
|
{ |
| 1513 |
< |
fprintf(fp, "\n%s sphere %s.s\n", mod, name); |
| 1513 |
> |
fprintf(fp, "\n'%s' sphere '%s.s'\n", mod, name); |
| 1514 |
|
fprintf(fp, "0\n0\n4 0 0 0 %g\n", .5*shp->w*meters2out); |
| 1515 |
|
} |
| 1516 |
|
|