From 9557807ff2f488fc44875bd8b30b8b73a0ca0d08 Mon Sep 17 00:00:00 2001 From: Dan Smith Date: Tue, 8 Aug 2023 08:43:13 -0400 Subject: [PATCH] no LUTs in SIDD 1.0.0 --- six/modules/c++/six/source/NITFReadControl.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/six/modules/c++/six/source/NITFReadControl.cpp b/six/modules/c++/six/source/NITFReadControl.cpp index 7a6ca86cc..d40e95cd3 100644 --- a/six/modules/c++/six/source/NITFReadControl.cpp +++ b/six/modules/c++/six/source/NITFReadControl.cpp @@ -470,6 +470,13 @@ void NITFReadControl::setDisplayLUT(six::NITFImageInfo& currentInfo, const nitf: return; } + const auto version = pData->getVersion(); + if (version == "1.0.0") // TODO: remove this hard-coded SIDD version check + { + // LUTs only with SIDD 2.0 and later + return; + } + // There's no requirement for SIDD 2.0 to have a LUT const auto bandInfo0 = subheader.getBandInfo(0); const int numLUTs = bandInfo0.getNumLUTs();