From e49deb790eb7008e2c587fd53691525216606cbb Mon Sep 17 00:00:00 2001 From: curt Date: Sat, 23 May 1998 15:19:49 +0000 Subject: [PATCH] Output more digits after the decimal place. --- FixObj/obj.c | 15 +++++++++------ Tri2obj/tri2obj.c | 9 ++++++--- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/FixObj/obj.c b/FixObj/obj.c index 77e0d8e13..cf7648604 100644 --- a/FixObj/obj.c +++ b/FixObj/obj.c @@ -159,7 +159,7 @@ void dump_global_bounds( void ) { } - fprintf(out, "gb %.4f %.4f %.4f %.2f\n", refx, refy, refz, radius); + fprintf(out, "gb %.5f %.5f %.5f %.2f\n", refx, refy, refz, radius); } @@ -169,7 +169,7 @@ void dump_nodes( void ) { fprintf(out, "\n"); for ( i = 1; i < ncount; i++ ) { - fprintf(out, "v %.4f %.4f %.4f\n", + fprintf(out, "v %.5f %.5f %.5f\n", nodes[i][0] - refx, nodes[i][1] - refy, nodes[i][2] - refz); } } @@ -181,7 +181,7 @@ void dump_normals( void ) { fprintf(out, "\n"); for ( i = 1; i < vncount; i++ ) { - fprintf(out, "vn %.4f %.4f %.4f\n", + fprintf(out, "vn %.5f %.5f %.5f\n", normals[i][0], normals[i][1], normals[i][2]); } } @@ -477,10 +477,13 @@ void obj_fix(char *infile, char *outfile) { /* $Log$ -/* Revision 1.13 1998/05/20 20:55:19 curt -/* Fixed arbitrary polygon winding problem here so all tristrips are passed -/* to runtime simulator with a consistant counter clockwise winding. +/* Revision 1.14 1998/05/23 15:19:49 curt +/* Output more digits after the decimal place. /* + * Revision 1.13 1998/05/20 20:55:19 curt + * Fixed arbitrary polygon winding problem here so all tristrips are passed + * to runtime simulator with a consistant counter clockwise winding. + * * Revision 1.12 1998/05/16 13:11:26 curt * Fixed an off by one error in node, normal, and face counters. * diff --git a/Tri2obj/tri2obj.c b/Tri2obj/tri2obj.c index 5c6390afe..071c0e359 100644 --- a/Tri2obj/tri2obj.c +++ b/Tri2obj/tri2obj.c @@ -517,7 +517,7 @@ void dump_obj(char *basename) { /* dump vertices */ printf(" writing vertices\n"); for ( i = 1; i <= nodecount; i++ ) { - fprintf(obj, "v %.2f %.2f %.2f\n", + fprintf(obj, "v %.6f %.6f %.6f\n", nodes[i].x, nodes[i].y, nodes[i].z); } @@ -644,9 +644,12 @@ int main(int argc, char **argv) { /* $Log$ -/* Revision 1.15 1998/05/02 01:54:39 curt -/* Converting to polar3d.h routines. +/* Revision 1.16 1998/05/23 15:20:41 curt +/* Output more digits after the decimal place. /* + * Revision 1.15 1998/05/02 01:54:39 curt + * Converting to polar3d.h routines. + * * Revision 1.14 1998/04/18 04:01:32 curt * Now use libMath rather than having local copies of math routines. * -- 2.39.2