comparison Framework/Layers/RenderStyle.cpp @ 726:4f2416d519b4

moving layers, widgets and loaders to Deprecated namespace
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 21 May 2019 11:43:25 +0200
parents 3080ec4ec6b9
children
comparison
equal deleted inserted replaced
714:d2c0e347ddc2 726:4f2416d519b4
21 21
22 #include "RenderStyle.h" 22 #include "RenderStyle.h"
23 23
24 #include <Core/OrthancException.h> 24 #include <Core/OrthancException.h>
25 25
26 namespace OrthancStone 26 namespace Deprecated
27 { 27 {
28 RenderStyle::RenderStyle() 28 RenderStyle::RenderStyle()
29 { 29 {
30 visible_ = true; 30 visible_ = true;
31 reverse_ = false; 31 reverse_ = false;
32 windowing_ = ImageWindowing_Custom; 32 windowing_ = OrthancStone::ImageWindowing_Custom;
33 alpha_ = 1; 33 alpha_ = 1;
34 applyLut_ = false; 34 applyLut_ = false;
35 lut_ = Orthanc::EmbeddedResources::COLORMAP_HOT; 35 lut_ = Orthanc::EmbeddedResources::COLORMAP_HOT;
36 drawGrid_ = false; 36 drawGrid_ = false;
37 drawColor_[0] = 255; 37 drawColor_[0] = 255;
38 drawColor_[1] = 255; 38 drawColor_[1] = 255;
39 drawColor_[2] = 255; 39 drawColor_[2] = 255;
40 customWindowCenter_ = 128; 40 customWindowCenter_ = 128;
41 customWindowWidth_ = 256; 41 customWindowWidth_ = 256;
42 interpolation_ = ImageInterpolation_Nearest; 42 interpolation_ = OrthancStone::ImageInterpolation_Nearest;
43 fontSize_ = 14; 43 fontSize_ = 14;
44 } 44 }
45 45
46 46
47 void RenderStyle::ComputeWindowing(float& targetCenter, 47 void RenderStyle::ComputeWindowing(float& targetCenter,
48 float& targetWidth, 48 float& targetWidth,
49 float defaultCenter, 49 float defaultCenter,
50 float defaultWidth) const 50 float defaultWidth) const
51 { 51 {
52 if (windowing_ == ImageWindowing_Custom) 52 if (windowing_ == OrthancStone::ImageWindowing_Custom)
53 { 53 {
54 targetCenter = customWindowCenter_; 54 targetCenter = customWindowCenter_;
55 targetWidth = customWindowWidth_; 55 targetWidth = customWindowWidth_;
56 } 56 }
57 else 57 else