# HG changeset patch
# User Benjamin Golinvaux <bgo@osimis.io>
# Date 1596207971 -7200
# Node ID fa30f275cd8023a77e9b11b5895a2717006ec1cd
# Parent  bc4c50a53bd3a68f8a4e3f95f20b2e0e4300c45c
Removed requirement for a non-empty RTDOSE

diff -r bc4c50a53bd3 -r fa30f275cd80 OrthancStone/Samples/Common/RtViewerApp.cpp
--- a/OrthancStone/Samples/Common/RtViewerApp.cpp	Fri Jul 31 13:36:49 2020 +0200
+++ b/OrthancStone/Samples/Common/RtViewerApp.cpp	Fri Jul 31 17:06:11 2020 +0200
@@ -157,12 +157,36 @@
     ORTHANC_ASSERT(HasArgument("ctseries") && HasArgument("rtdose") && HasArgument("rtstruct"));
 
     LOG(INFO) << "About to load:";
-    LOG(INFO) << "  CT       : " << GetArgument("ctseries");
-    LOG(INFO) << "  RTDOSE   : " << GetArgument("rtdose");
-    LOG(INFO) << "  RTSTRUCT : " << GetArgument("rtstruct");
-    ctLoader_->LoadSeries(GetArgument("ctseries"));
-    doseLoader_->LoadInstance(GetArgument("rtdose"));
-    rtstructLoader_->LoadInstanceFullVisibility(GetArgument("rtstruct"));
+
+    if (GetArgument("ctseries") == "")
+    {
+      LOG(INFO) << "  CT       : <unspecified>";
+    }
+    else
+    {
+      LOG(INFO) << "  CT       : " << GetArgument("ctseries");
+      ctLoader_->LoadSeries(GetArgument("ctseries"));
+    }
+    
+    if (GetArgument("rtdose") == "")
+    {
+      LOG(INFO) << "  RTDOSE   : <unspecified>";
+    }
+    else
+    {
+      LOG(INFO) << "  RTDOSE   : " << GetArgument("rtdose");
+      doseLoader_->LoadInstance(GetArgument("rtdose"));
+    }
+
+    if (GetArgument("rtstruct") == "")
+    {
+      LOG(INFO) << "  RTSTRUCT : : <unspecified>";
+    }
+    else
+    {
+      LOG(INFO) << "  RTSTRUCT : : " << GetArgument("rtstruct");
+      rtstructLoader_->LoadInstanceFullVisibility(GetArgument("rtstruct"));
+    }
   }
 
   void RtViewerApp::HandleGeometryReady(const DicomVolumeImage::GeometryReadyMessage& message)