comparison Framework/Radiography/RadiographyScene.cpp @ 928:1b49e78d91d0

fix for older compilers
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 23 Jul 2019 11:50:21 +0200
parents 6b81c5453382
children b537002f83a9 d33ae2b0db9d
comparison
equal deleted inserted replaced
927:39d2a3661665 928:1b49e78d91d0
604 throw Orthanc::OrthancException(Orthanc::ErrorCode_ParameterOutOfRange); 604 throw Orthanc::OrthancException(Orthanc::ErrorCode_ParameterOutOfRange);
605 } 605 }
606 606
607 Extent2D extent = GetSceneExtent(); 607 Extent2D extent = GetSceneExtent();
608 608
609 int w = static_cast<int>(std::round(extent.GetWidth() / pixelSpacingX)); 609 int w = boost::math::iround(extent.GetWidth() / pixelSpacingX);
610 int h = static_cast<int>(std::round(extent.GetHeight() / pixelSpacingY)); 610 int h = boost::math::iround(extent.GetHeight() / pixelSpacingY);
611 611
612 if (w < 0 || h < 0) 612 if (w < 0 || h < 0)
613 { 613 {
614 throw Orthanc::OrthancException(Orthanc::ErrorCode_InternalError); 614 throw Orthanc::OrthancException(Orthanc::ErrorCode_InternalError);
615 } 615 }