Small json parse fix

This commit is contained in:
Sebastian Piwell
2016-04-11 14:10:37 -04:00
parent f64804d043
commit 6c72494859
3 changed files with 42 additions and 2 deletions
+20
View File
@@ -0,0 +1,20 @@
{"Run":"Yihua_Zheng_011116_1",
"Model":"SWMF",
"Discipline":"magnetosphere",
"Central Body":"Earth",
"Spatial Scale (Custom)":"R_E",
"Spatial Scale (SI)":"6371000 m",
"Coordinates":"GSM",
"Coordinate Type":"Cartesian",
"Plot Variable":"N",
"Plot Variable Unit (Custom)":"amu/cm^3",
"Plot Variable Unit (SI)":"1.0e+06 amu/m^3",
"Plot XMIN":-224.0,
"Plot XMAX":32.0,
"Plot YMIN":0.0,
"Plot YMAX":0.0,
"Plot ZMIN":-48.0,
"Plot ZMAX":48.0,
"Plot Scaling":"logarithmic (base: 10)",
"ISWA_UPDATE_SECONDS":240
}
+20
View File
@@ -0,0 +1,20 @@
{"Run":"Yihua_Zheng_011116_1",
"Model":"SWMF",
"Discipline":"magnetosphere",
"Central Body":"Earth",
"Spatial Scale (Custom)":"R_E",
"Spatial Scale (SI)":"6371000 m",
"Coordinates":"GSM",
"Coordinate Type":"Cartesian",
"Plot Variable":"N",
"Plot Variable Unit (Custom)":"amu/cm^3",
"Plot Variable Unit (SI)":"1.0e+06 amu/m^3",
"Plot XMIN":-224.0,
"Plot XMAX":32.0,
"Plot YMIN":-48.0,
"Plot YMAX":48.0,
"Plot ZMIN":0.0,
"Plot ZMAX":0.0,
"Plot Scaling":"logarithmic (base: 10)",
"ISWA_UPDATE_SECONDS":240
}
+2 -2
View File
@@ -163,7 +163,7 @@ namespace openspace{
}
void ISWAManager::addISWACygnet(int id, std::string info){
getDictionaryTable(absPath("${OPENSPACE_DATA}/GM_openspace_X0_info.txt"), id);
getDictionaryTable(absPath("${OPENSPACE_DATA}/GM_openspace_Y0_info.txt"), id);
if(id != 0){
std::shared_ptr<ExtensionFuture> extFuture = fileExtension(id);
@@ -309,7 +309,7 @@ namespace openspace{
std::string scale = "{"
+ std::to_string(spatScale*(xmax-xmin)) + ","
+ std::to_string(spatScale*(ymax-ymin)) + ","
+ std::to_string(spatScale*(ymax-ymin)) + ","
+ std::to_string(spatScale*(zmax-zmin)) + ","
+ std::to_string(scalew) +
"}";