Mercurial > hg > orthanc-stone
comparison Framework/Radiography/RadiographyScene.cpp @ 1258:9c20ae049669
more logs to debug exceptions in Render
author | Alain Mazy <alain@mazy.be> |
---|---|
date | Tue, 14 Jan 2020 15:22:10 +0100 |
parents | 6af941a68472 |
children | 69177b10e2b9 |
comparison
equal
deleted
inserted
replaced
1257:6af941a68472 | 1258:9c20ae049669 |
---|---|
562 bool applyWindowing) const | 562 bool applyWindowing) const |
563 { | 563 { |
564 // Render layers in the background-to-foreground order | 564 // Render layers in the background-to-foreground order |
565 for (size_t index = 0; index < nextLayerIndex_; index++) | 565 for (size_t index = 0; index < nextLayerIndex_; index++) |
566 { | 566 { |
567 Layers::const_iterator it = layers_.find(index); | 567 try |
568 if (it != layers_.end()) | 568 { |
569 { | 569 Layers::const_iterator it = layers_.find(index); |
570 assert(it->second != NULL); | 570 if (it != layers_.end()) |
571 it->second->Render(buffer, viewTransform, interpolation, windowingCenter_, windowingWidth_, applyWindowing); | 571 { |
572 assert(it->second != NULL); | |
573 it->second->Render(buffer, viewTransform, interpolation, windowingCenter_, windowingWidth_, applyWindowing); | |
574 } | |
575 } | |
576 catch (Orthanc::OrthancException& ex) | |
577 { | |
578 LOG(ERROR) << "RadiographyScene::Render: " << index << ", OrthancException: " << ex.GetDetails(); | |
579 throw ex; // rethrow because we want it to crash to see there's a problem ! | |
580 } | |
581 catch (...) | |
582 { | |
583 LOG(ERROR) << "RadiographyScene::Render: " << index << ", unkown exception: "; | |
584 throw; // rethrow because we want it to crash to see there's a problem ! | |
572 } | 585 } |
573 } | 586 } |
574 } | 587 } |
575 | 588 |
576 | 589 |