comparison Framework/Scene2D/LookupTableStyleConfigurator.cpp @ 1179:177e7d431cd1 broker

log scale in textures, remove redundant code for LUTs
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 20 Nov 2019 15:24:20 +0100
parents 287ec78f63b4
children 0ca50d275b9a
comparison
equal deleted inserted replaced
1178:3c7cdbf32e2a 1179:177e7d431cd1
37 } 37 }
38 38
39 LookupTableStyleConfigurator::LookupTableStyleConfigurator() : 39 LookupTableStyleConfigurator::LookupTableStyleConfigurator() :
40 revision_(0), 40 revision_(0),
41 hasLut_(false), 41 hasLut_(false),
42 hasRange_(false) 42 hasRange_(false),
43 applyLog_(false)
43 { 44 {
44 } 45 }
45 46
46 void LookupTableStyleConfigurator::SetLookupTable(Orthanc::EmbeddedResources::FileResourceId resource) 47 void LookupTableStyleConfigurator::SetLookupTable(Orthanc::EmbeddedResources::FileResourceId resource)
47 { 48 {
80 minValue_ = minValue; 81 minValue_ = minValue;
81 maxValue_ = maxValue; 82 maxValue_ = maxValue;
82 } 83 }
83 } 84 }
84 85
86 void LookupTableStyleConfigurator::SetApplyLog(bool apply)
87 {
88 applyLog_ = apply;
89 revision_++;
90 }
91
85 TextureBaseSceneLayer* LookupTableStyleConfigurator::CreateTextureFromImage(const Orthanc::ImageAccessor& image) const 92 TextureBaseSceneLayer* LookupTableStyleConfigurator::CreateTextureFromImage(const Orthanc::ImageAccessor& image) const
86 { 93 {
87 throw Orthanc::OrthancException(Orthanc::ErrorCode_NotImplemented); 94 throw Orthanc::OrthancException(Orthanc::ErrorCode_NotImplemented);
88 } 95 }
89 96
102 } 109 }
103 else 110 else
104 { 111 {
105 l.FitRange(); 112 l.FitRange();
106 } 113 }
114
115 l.SetApplyLog(applyLog_);
107 } 116 }
108 } 117 }