1 /*
2  Copyright (c) 2013 yvt
3 
4  This file is part of OpenSpades.
5 
6  OpenSpades is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  OpenSpades is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with OpenSpades.  If not, see <http://www.gnu.org/licenses/>.
18 
19  */
20 #pragma once
21 
22 #include <Core/SettingSet.h>
23 
24 namespace spades {
25 	namespace draw {
26 		class GLSettings : public SettingSet {
27 		public:
28 			GLSettings();
29 
30 			TypedItemHandle<bool> r_blitFramebuffer     { *this, "r_blitFramebuffer" };
31 			TypedItemHandle<bool> r_bloom               { *this, "r_bloom" };
32 			TypedItemHandle<bool> r_cameraBlur          { *this, "r_cameraBlur", ItemFlags::Latch };
33 			TypedItemHandle<bool> r_colorCorrection     { *this, "r_colorCorrection" };
34 			TypedItemHandle<bool> r_debugTiming         { *this, "r_debugTiming" };
35 			TypedItemHandle<bool> r_debugTimingOutputScreen { *this, "r_debugTimingOutputScreen" };
36 			TypedItemHandle<bool> r_debugTimingOutputLog { *this, "r_debugTimingOutputLog" };
37 			TypedItemHandle<bool> r_debugTimingAverage  { *this, "r_debugTimingAverage" };
38 			TypedItemHandle<bool> r_debugTimingGPUTime  { *this, "r_debugTimingGPUTime" };
39 			TypedItemHandle<float> r_debugTimingOutputBarScale { *this, "r_debugTimingOutputBarScale" };
40 			TypedItemHandle<bool> r_debugTimingFlush    { *this, "r_debugTimingFlush" };
41 			TypedItemHandle<bool> r_debugTimingFillGap  { *this, "r_debugTimingFillGap" };
42 			TypedItemHandle<int> r_depthOfField         { *this, "r_depthOfField" };
43 			TypedItemHandle<float> r_depthOfFieldMaxCoc { *this, "r_depthOfFieldMaxCoc" };
44 			TypedItemHandle<bool> r_depthPrepass        { *this, "r_depthPrepass" };
45 			TypedItemHandle<bool> r_dlights             { *this, "r_dlights" };
46 			TypedItemHandle<float> r_exposureValue      { *this, "r_exposureValue" };
47 			TypedItemHandle<bool> r_fogShadow           { *this, "r_fogShadow", ItemFlags::Latch };
48 			TypedItemHandle<bool> r_fxaa                { *this, "r_fxaa" };
49 			TypedItemHandle<bool> r_hdr                 { *this, "r_hdr", ItemFlags::Latch };
50 			TypedItemHandle<float> r_hdrAutoExposureMin { *this, "r_hdrAutoExposureMin" };
51 			TypedItemHandle<float> r_hdrAutoExposureMax { *this, "r_hdrAutoExposureMax" };
52 			TypedItemHandle<float> r_hdrAutoExposureSpeed{ *this, "r_hdrAutoExposureSpeed" };
53 			TypedItemHandle<float> r_hdrGamma           { *this, "r_hdrGamma" };
54 			TypedItemHandle<bool> r_highPrec            { *this, "r_highPrec", ItemFlags::Latch };
55 			TypedItemHandle<bool> r_lens                { *this, "r_lens" };
56 			TypedItemHandle<bool> r_lensFlare           { *this, "r_lensFlare" };
57 			TypedItemHandle<bool> r_lensFlareDynamic    { *this, "r_lensFlareDynamic" };
58 			TypedItemHandle<bool> r_mapSoftShadow       { *this, "r_mapSoftShadow", ItemFlags::Latch };
59 			TypedItemHandle<float> r_maxAnisotropy      { *this, "r_maxAnisotropy", ItemFlags::Latch };
60 			TypedItemHandle<bool> r_modelShadows        { *this, "r_modelShadows", ItemFlags::Latch };
61 			TypedItemHandle<int> r_multisamples         { *this, "r_multisamples", ItemFlags::Latch };
62 			TypedItemHandle<bool> r_occlusionQuery      { *this, "r_occlusionQuery" };
63 			TypedItemHandle<bool> r_optimizedVoxelModel { *this, "r_optimizedVoxelModel", ItemFlags::Latch };
64 			TypedItemHandle<bool> r_physicalLighting    { *this, "r_physicalLighting", ItemFlags::Latch };
65 			TypedItemHandle<int> r_radiosity            { *this, "r_radiosity", ItemFlags::Latch };
66 			TypedItemHandle<float> r_saturation         { *this, "r_saturation" };
67 			TypedItemHandle<int> r_shadowMapSize        { *this, "r_shadowMapSize", ItemFlags::Latch };
68 			TypedItemHandle<bool> r_softParticles       { *this, "r_softParticles" };
69 			TypedItemHandle<bool> r_sparseShadowMaps    { *this, "r_sparseShadowMaps", ItemFlags::Latch };
70 			TypedItemHandle<bool> r_srgb                { *this, "r_srgb", ItemFlags::Latch };
71 			TypedItemHandle<bool> r_srgb2D              { *this, "r_srgb2D", ItemFlags::Latch };
72 			TypedItemHandle<int> r_ssao                 { *this, "r_ssao", ItemFlags::Latch };
73 			TypedItemHandle<int> r_water                { *this, "r_water", ItemFlags::Latch };
74 		};
75 	}
76 }
77