mirror of
git://projects.qi-hardware.com/cae-tools.git
synced 2024-12-23 03:59:00 +02:00
Correct direction of x inclination of z0.
- solidify/povray.c (povray_face), solidify/project.c (read_face_data): x inclination of the z0 plane was reversed in POV-Ray output and in the project file
This commit is contained in:
parent
32a4d4ae85
commit
5170410012
@ -100,7 +100,7 @@ static void povray_face(const struct face *f, const char *side,
|
||||
"\t}\n", prefix, side,
|
||||
f->sx*f->x_step, (f->sz-1)*f->z_step, f->sy*f->y_step,
|
||||
-f->sx*f->x_step/2, f->sy*f->y_step/2,
|
||||
-atan(f->fy)/M_PI*180, -atan(f->fx)/M_PI*180,
|
||||
-atan(f->fy)/M_PI*180, atan(f->fx)/M_PI*180,
|
||||
f->a->min_z*f->z_step,
|
||||
-f->z_ref*f->z_step,
|
||||
a,
|
||||
|
@ -72,7 +72,7 @@ static void read_face_data(FILE *file, struct face *f)
|
||||
|
||||
if (fscanf(file, "%f", &v) != 1)
|
||||
return;
|
||||
f->fx = tan(v/180*M_PI);
|
||||
f->fx = -tan(v/180*M_PI);
|
||||
|
||||
if (fscanf(file, "%f", &v) != 1)
|
||||
return;
|
||||
@ -163,7 +163,7 @@ static void save_face_data(FILE *file, const char *name, const struct face *f)
|
||||
a = 180-a;
|
||||
if (fprintf(file, "%g %g %g\n%g %g %g\n",
|
||||
f->z_ref*f->z_step,
|
||||
atan(f->fx)/M_PI*180, atan(f->fy)/M_PI*180,
|
||||
-atan(f->fx)/M_PI*180, atan(f->fy)/M_PI*180,
|
||||
a, f->m.b[0]*f->x_step, f->m.b[1]*f->y_step) < 0) {
|
||||
perror(name);
|
||||
exit(1);
|
||||
|
Loading…
Reference in New Issue
Block a user