We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0d6560a commit bf8d8b9Copy full SHA for bf8d8b9
src/aliceVision/image/io.cpp
@@ -483,7 +483,26 @@ oiio::ParamValueList getMetadataFromMap(const std::map<std::string, std::string>
483
{
484
oiio::ParamValueList metadata;
485
for (const auto& metadataPair : metadataMap)
486
+ {
487
+ if (metadataPair.first == "version")
488
489
+ //OpenEXR may crash if version is not stored as an int.
490
+ int version = 0;
491
+ try
492
493
+ version = std::stoi(metadataPair.second);
494
+ metadata.push_back(oiio::ParamValue(metadataPair.first, version));
495
+ continue;
496
+ }
497
+ catch (...)
498
499
+ //If not an int, then business as usual
500
501
502
+
503
metadata.push_back(oiio::ParamValue(metadataPair.first, metadataPair.second));
504
505
506
return metadata;
507
}
508
0 commit comments