Showing the changes to interface/src/scripting/RenderScriptingInterface.cpp (1 of 7 files). Show all
Unified · Split
| @@ -30,11 +30,13 @@ void RenderScriptingInterface::loadSettings() { · 29 unmodified lines | ||
| 30 | 30 | _shadowsEnabled = (_shadowsEnabledSetting.get()); |
| 31 | 31 | _ambientOcclusionEnabled = (_ambientOcclusionEnabledSetting.get()); |
| 32 | 32 | _antialiasingEnabled = (_antialiasingEnabledSetting.get()); |
| 33 | + _viewportResolutionScale = (_viewportResolutionScaleSetting.get()); | |
| 33 | 34 | }); |
| 34 | 35 | forceRenderMethod((RenderMethod)_renderMethod); |
| 35 | 36 | forceShadowsEnabled(_shadowsEnabled); |
| 36 | 37 | forceAmbientOcclusionEnabled(_ambientOcclusionEnabled); |
| 37 | 38 | forceAntialiasingEnabled(_antialiasingEnabled); |
| 39 | + forceViewportResolutionScale(_viewportResolutionScale); | |
| 38 | 40 | } |
| 39 | 41 | |
| 40 | 42 | RenderScriptingInterface::RenderMethod RenderScriptingInterface::getRenderMethod() const { |
| @@ -159,7 +161,7 @@ void RenderScriptingInterface::setViewportResolutionScale(float scale) { · 118 unmodified lines | ||
| 159 | 161 | void RenderScriptingInterface::forceViewportResolutionScale(float scale) { |
| 160 | 162 | _renderSettingLock.withWriteLock([&] { |
| 161 | 163 | _viewportResolutionScale = (scale); |
| 162 | − // _antialiasingEnabledSetting.set(enabled); | |
| 164 | + _viewportResolutionScaleSetting.set(scale); | |
| 163 | 165 | |
| 164 | 166 | auto renderConfig = qApp->getRenderEngine()->getConfiguration(); |
| 165 | 167 | assert(renderConfig); |
| @@ -173,19 +175,5 @@ void RenderScriptingInterface::forceViewportResolutionScale(float scale) { · 7 unmodified lines | ||
| 173 | 175 | if (forwardView) { |
| 174 | 176 | forwardView->setProperty("resolutionScale", _viewportResolutionScale); |
| 175 | 177 | } |
| 176 | −/* | |
| 177 | − auto mainViewJitterCamConfig = qApp->getRenderEngine()->getConfiguration()->getConfig<JitterSample>("RenderMainView.JitterCam"); | |
| 178 | − auto mainViewAntialiasingConfig = qApp->getRenderEngine()->getConfiguration()->getConfig<Antialiasing>("RenderMainView.Antialiasing"); | |
| 179 | − if (mainViewJitterCamConfig && mainViewAntialiasingConfig) { | |
| 180 | − Menu::getInstance()->setIsOptionChecked(MenuOption::AntiAliasing, enabled); | |
| 181 | − if (enabled) { | |
| 182 | − mainViewJitterCamConfig->play(); | |
| 183 | − mainViewAntialiasingConfig->setDebugFXAA(false); | |
| 184 | − } | |
| 185 | − else { | |
| 186 | − mainViewJitterCamConfig->none(); | |
| 187 | − mainViewAntialiasingConfig->setDebugFXAA(true); | |
| 188 | − } | |
| 189 | − }*/ | |
| 190 | 178 | }); |
| 191 | 179 | } |