From: Stéphane A. <otb...@gm...> - 2016-07-21 10:43:06
|
Hello, I'm developer on the OTB project (https://www.orfeo-toolbox.org/) which uses OSSIM and runs on some Linux/Windows/OSX non-english systems (such as fr_FR.UTF-8). Those systems use the comma ',' as decimal point as opposed to the POSIX dot '.' decimal separator. However, the product meta-data always use the point '.' decimal separator and the ossimString class always considers the system locale (on a French system the decimal separator will be the comma ','). So, there are some issues regarding conversion of meta-data values on our target platforms. As for an example a '1.5' string would be converted to a 1 numerical value. Please find enclosed a patch I started but remains unfinished and untested which consists in: 1. adding a useCLocal force flag to all string-numerical conversion functions of the ossimString 2. use the std::istringstream.imbue( std::locale::classic() ) to do that 3. also include some ossimString private template functions to factorize some code 4. use the useCLocale everywhere in the OSSIM library were meta-data string-value conversion occurs and let other use of the ossimString class choose to use the system or C/POSIX locale. The OTB PSC and developer team would like to know if the people of the OSSIM project would be interested in including such a a patch in future OSSIM releases. Best regards, http://orfeo-toolbox.org Stéphane ALBERT Ingénieur d'études et développement Business Unit E-SPACE & Geo Information, Département APPLICATIONS CS Systèmes d'Information Parc de la Grande Plaine - 5, Rue Brindejonc des Moulinais - BP 15872 31506 Toulouse Cedex 05 - France |