mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-04-23 04:30:09 -05:00
Fixes to prevent crashes when data is not available
This commit is contained in:
@@ -118,7 +118,7 @@ std::string LabelParser::encode(std::string line) {
|
||||
return "";
|
||||
}
|
||||
|
||||
void LabelParser::create(){
|
||||
bool LabelParser::create() {
|
||||
auto imageComparer = [](const Image &a, const Image &b)->bool{
|
||||
return a.startTime < b.startTime;
|
||||
};
|
||||
@@ -132,7 +132,7 @@ void LabelParser::create(){
|
||||
ghoul::filesystem::Directory sequenceDir(_fileName, true);
|
||||
if (!FileSys.directoryExists(sequenceDir)) {
|
||||
LERROR("Could not load Label Directory '" << sequenceDir.path() << "'");
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
std::vector<std::string> sequencePaths = sequenceDir.read(true, false); // check inputs
|
||||
for (auto path : sequencePaths){
|
||||
@@ -255,6 +255,7 @@ void LabelParser::create(){
|
||||
////print all
|
||||
for (auto target : _subsetMap){
|
||||
_instrumentTimes.push_back(std::make_pair(lblName, _subsetMap[target.first]._range));
|
||||
|
||||
// std::string min, max;
|
||||
// SpiceManager::ref().getDateFromET(target.second._range._min, min);
|
||||
// SpiceManager::ref().getDateFromET(target.second._range._max, max);
|
||||
@@ -281,6 +282,7 @@ void LabelParser::create(){
|
||||
|
||||
sendPlaybookInformation(PlaybookIdentifierName);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void LabelParser::createImage(Image& image, double startTime, double stopTime, std::vector<std::string> instr, std::string targ, std::string pot) {
|
||||
|
||||
Reference in New Issue
Block a user