Jump to content

Specify precision for floating-point numbers when setting XML args / data


photo

Recommended Posts

I have a dmat4 where one of the elements is both large and with several significant digits following the decimal point: -52016.774965. When I call Xml::setDMat4Arg using this dmat4 and then write the XML to a file, this element value has been rounded to -52016.8. This results in strange behavior in my application when I later read this XML arg back in and try to work with it.

 

Workaround is to write my own mySetDMat4Arg function with different String::format parameters than are used by Xml::setDMat4Arg, but it would be nice if this weren't necessary.

Link to comment
  • 5 months later...
×
×
  • Create New...