Mercurial > hg > orthanc-wsi
changeset 322:778e08291d52
re-enabling built-in support of plain TIFF
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 16 Oct 2024 18:42:10 +0200 |
parents | 0c34b6625c67 |
children | 429c4efa1fde |
files | Applications/Dicomizer.cpp |
diffstat | 1 files changed, 15 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/Applications/Dicomizer.cpp Wed Oct 16 15:01:46 2024 +0200 +++ b/Applications/Dicomizer.cpp Wed Oct 16 18:42:10 2024 +0200 @@ -1084,17 +1084,23 @@ catch (Orthanc::OrthancException&) { LOG(WARNING) << "This is not a standard hierarchical TIFF file, fallback to plain TIFF"; - break; } - sourceCompression = OrthancWSI::ImageCompression_Unknown; - return new OrthancWSI::PlainTiff(path, - parameters.GetTargetTileWidth(512), - parameters.GetTargetTileHeight(512), - parameters.GetTiffAlignment(), - parameters.GetBackgroundColorRed(), - parameters.GetBackgroundColorGreen(), - parameters.GetBackgroundColorBlue()); + try + { + sourceCompression = OrthancWSI::ImageCompression_Unknown; + return new OrthancWSI::PlainTiff(path, + parameters.GetTargetTileWidth(512), + parameters.GetTargetTileHeight(512), + parameters.GetTiffAlignment(), + parameters.GetBackgroundColorRed(), + parameters.GetBackgroundColorGreen(), + parameters.GetBackgroundColorBlue()); + } + catch (Orthanc::OrthancException&) + { + LOG(WARNING) << "This is not a standard plain TIFF file, fallback to OpenSlide (if enabled)"; + } } default: