1
0
mirror of git://projects.qi-hardware.com/cae-tools.git synced 2024-12-22 23:26:27 +02:00

Yet another overlap display correction. Avoid truncation on save-load cycle.

- solidify/overlap.c (merge_matrix): don't shrink the offset vector
- solidify/project.c (read_face_data): the value to assign to f->z_ref
  needs rounding or truncation will go wrong from time to time
This commit is contained in:
Werner Almesberger 2010-09-25 06:35:29 -03:00
parent e8d6837065
commit e08bd77d51
2 changed files with 3 additions and 3 deletions

View File

@ -185,10 +185,10 @@ static void merge_matrix(struct matrix *m, const struct solid *s,
m->a[0][0] *= f_x;
m->a[0][1] *= f_x;
m->b[0] *= f_x;
// m->b[0] *= f_x;
m->a[1][0] *= f_y;
m->a[1][1] *= f_y;
m->b[1] *= f_y;
// m->b[1] *= f_y;
/*
* The transformation matrix f->m describes a transformation of

View File

@ -67,7 +67,7 @@ static void read_face_data(FILE *file, struct face *f)
if (fscanf(file, "%f", &v) != 1)
return;
f->z_ref = v/f->z_step;
f->z_ref = round(v/f->z_step);
if (fscanf(file, "%f", &v) != 1)
return;