fix bug in idfcyl utility

This commit is contained in:
unknown 2015-04-09 20:56:52 +02:00 committed by jean-pierre charras
parent ec17455d35
commit ea11c013b6
1 changed files with 2 additions and 2 deletions

View File

@ -350,9 +350,9 @@ void make_vcyl( bool inch, bool axial, double dia, double length,
fprintf( fp, "0 0 0 0\n" ); fprintf( fp, "0 0 0 0\n" );
if( inch ) if( inch )
fprintf( fp, "0 %d 0 360\n", (int) (dia * 1000) ); fprintf( fp, "0 %d 0 360\n", (int) (dia * 500) );
else else
fprintf( fp, "0 %.3f 0 360\n", dia ); fprintf( fp, "0 %.3f 0 360\n", dia / 2.0 );
fprintf( fp, ".END_ELECTRICAL\n" ); fprintf( fp, ".END_ELECTRICAL\n" );
fclose( fp ); fclose( fp );