Mercurial > hg > aimc
comparison src/Modules/Output/Graphics/Scale/Scale.cc @ 230:2aa72aa8a0d4
- Well, most of the graphics stuff at least compiles now. Next step is getting it running.
M Modules/Output/Graphics/GraphicsView.h
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceMovieDirect.cc
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceMovieDirect.h
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceCairo.cc
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceCairo.h
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceMovie.cc
M Modules/Output/Graphics/Devices/GraphicsOutputDeviceMovie.h
M Modules/Output/Graphics/Scale/ScaleLog.h
M Modules/Output/Graphics/Scale/ScaleERB.h
M Modules/Output/Graphics/Scale/ScaleLinear.h
M Modules/Output/Graphics/Scale/ScaleLogScaled.h
M Modules/Output/Graphics/Scale/Scale.cc
M Modules/Output/Graphics/Scale/Scale.h
M Support/Common.h
author | tom@acousticscale.org |
---|---|
date | Sat, 16 Oct 2010 23:05:26 +0000 |
parents | ddf35dd82d63 |
children |
comparison
equal
deleted
inserted
replaced
229:ddf35dd82d63 | 230:2aa72aa8a0d4 |
---|---|
14 #include "Modules/Output/Graphics/Scale/ScaleLinear.h" | 14 #include "Modules/Output/Graphics/Scale/ScaleLinear.h" |
15 #include "Modules/Output/Graphics/Scale/ScaleERB.h" | 15 #include "Modules/Output/Graphics/Scale/ScaleERB.h" |
16 #include "Modules/Output/Graphics/Scale/ScaleLog.h" | 16 #include "Modules/Output/Graphics/Scale/ScaleLog.h" |
17 #include "Modules/Output/Graphics/Scale/ScaleLogScaled.h" | 17 #include "Modules/Output/Graphics/Scale/ScaleLogScaled.h" |
18 | 18 |
19 namespace aimc { | |
20 | |
19 Scale *Scale::Create(ScaleType iType, | 21 Scale *Scale::Create(ScaleType iType, |
20 unsigned int min, | 22 unsigned int min, |
21 unsigned int max, | 23 unsigned int max, |
22 float density) { | 24 float density) { |
23 switch(iType) { | 25 switch(iType) { |
28 case SCALE_LOG: | 30 case SCALE_LOG: |
29 return static_cast<Scale*>(new ScaleLog(min, max, density)); | 31 return static_cast<Scale*>(new ScaleLog(min, max, density)); |
30 case SCALE_LOGSCALED: | 32 case SCALE_LOGSCALED: |
31 return static_cast<Scale*>(new ScaleLogScaled(min, max, density)); | 33 return static_cast<Scale*>(new ScaleLogScaled(min, max, density)); |
32 default: | 34 default: |
33 aimASSERT(0); | 35 AIM_ASSERT(0); |
34 break; | 36 break; |
35 } | 37 } |
36 // Unreachable code | 38 // Unreachable code |
37 aimASSERT(0); | 39 AIM_ASSERT(0); |
38 return NULL; | 40 return NULL; |
39 } | 41 } |
40 | 42 |
41 Scale *Scale::Create(ScaleType iType) { | 43 Scale *Scale::Create(ScaleType iType) { |
42 return Create(iType, 0, 0, 0); | 44 return Create(iType, 0, 0, 0); |
66 m_fMin = fMin; | 68 m_fMin = fMin; |
67 m_fMax = fMax; | 69 m_fMax = fMax; |
68 } | 70 } |
69 | 71 |
70 void Scale::FromLinearScaledExtrema(Scale *pScale) { | 72 void Scale::FromLinearScaledExtrema(Scale *pScale) { |
71 aimASSERT(pScale); | 73 AIM_ASSERT(pScale); |
72 FromLinearScaledExtrema(pScale->m_fMin, pScale->m_fMax); | 74 FromLinearScaledExtrema(pScale->m_fMin, pScale->m_fMax); |
73 } | 75 } |
76 } // namespace aimc |