Commit b1943451 authored by Alexander Shishkov's avatar Alexander Shishkov

reverted the floating-point number formatting (exception in ml tests)

parent 80dfdf8f
...@@ -775,7 +775,7 @@ icvDoubleToString( char* buf, double value ) ...@@ -775,7 +775,7 @@ icvDoubleToString( char* buf, double value )
sprintf( buf, "%d.", ivalue ); sprintf( buf, "%d.", ivalue );
else else
{ {
static const char* fmt = "%.17g"; static const char* fmt = "%.16e";
char* ptr = buf; char* ptr = buf;
sprintf( buf, fmt, value ); sprintf( buf, fmt, value );
if( *ptr == '+' || *ptr == '-' ) if( *ptr == '+' || *ptr == '-' )
...@@ -814,7 +814,7 @@ icvFloatToString( char* buf, float value ) ...@@ -814,7 +814,7 @@ icvFloatToString( char* buf, float value )
sprintf( buf, "%d.", ivalue ); sprintf( buf, "%d.", ivalue );
else else
{ {
static const char* fmt = "%.9g"; static const char* fmt = "%.8e";
char* ptr = buf; char* ptr = buf;
sprintf( buf, fmt, value ); sprintf( buf, fmt, value );
if( *ptr == '+' || *ptr == '-' ) if( *ptr == '+' || *ptr == '-' )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment