Skip to content

Commit 2fb3104

Browse files
Merge branch 'RtxOptionFixes' into 'main'
[REMIX-4852] fix RtxOptions that would not save (or load) correctly See merge request lightspeedrtx/dxvk-remix-nv!1853
2 parents f7256b0 + f7cb274 commit 2fb3104

File tree

14 files changed

+268
-261
lines changed

14 files changed

+268
-261
lines changed

RtxOptions.md

Lines changed: 58 additions & 58 deletions
Large diffs are not rendered by default.

src/dxvk/imgui/dxvk_imgui.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -622,11 +622,6 @@ namespace dxvk {
622622
, m_about (new ImGuiAbout)
623623
, m_splash (new ImGuiSplash)
624624
, m_graphGUI (new RtxGraphGUI) {
625-
// Clamp Option ranges
626-
627-
RTX_OPTION_CLAMP(reflexStatRangeInterpolationRate, 0.0f, 1.0f);
628-
RTX_OPTION_CLAMP_MIN(reflexStatRangePaddingRatio, 0.0f);
629-
630625
// Set up constant state
631626
m_rsState.polygonMode = VK_POLYGON_MODE_FILL;
632627
m_rsState.cullMode = VK_CULL_MODE_BACK_BIT;

src/dxvk/imgui/dxvk_imgui.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -284,8 +284,10 @@ namespace dxvk {
284284
RTX_OPTION("rtx.gui", bool, showLegacyTextureGui, false, "A setting to toggle the old texture selection GUI, where each texture category is represented as its own list.");
285285
RTX_OPTION("rtx.gui", bool, legacyTextureGuiShowAssignedOnly, false, "A setting to show only the textures in a category that are assigned to it (Unassigned textures are found in the new \"Uncategorized\" list at the top).\nRequires: \'Split Texture Category List\' option to be enabled.");
286286
RTX_OPTION("rtx.gui", std::uint32_t, hudMessageAnimatedDotDurationMilliseconds, 1000, "A duration in milliseconds between each dot in the animated dot sequence for HUD messages. Must be greater than 0.\nThese dots help indicate progress is happening to the user with a bit of animation which can be configured to animate at whatever speed is desired.");
287-
RTX_OPTION("rtx.gui", float, reflexStatRangeInterpolationRate, 0.05f, "A value controlling the interpolation rate applied to the Reflex stat graph ranges for smoother visualization.");
288-
RTX_OPTION("rtx.gui", float, reflexStatRangePaddingRatio, 0.05f, "A value specifying the amount of padding applied to the Reflex stat graph ranges as a ratio to the calculated range.");
287+
RTX_OPTION_ARGS("rtx.gui", float, reflexStatRangeInterpolationRate, 0.05f, "A value controlling the interpolation rate applied to the Reflex stat graph ranges for smoother visualization.",
288+
args.minValue = 0.0f, args.maxValue = 1.0f);
289+
RTX_OPTION_ARGS("rtx.gui", float, reflexStatRangePaddingRatio, 0.05f, "A value specifying the amount of padding applied to the Reflex stat graph ranges as a ratio to the calculated range.",
290+
args.minValue = 0.0f);
289291

290292
public: static void onThemeChange(DxvkDevice* device);
291293
public: static void onBackgroundAlphaChange(DxvkDevice* device);

src/dxvk/rtx_render/rtx_global_volumetrics.cpp

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -173,21 +173,6 @@ namespace dxvk {
173173
RtxGlobalVolumetrics::RtxGlobalVolumetrics(DxvkDevice* device) : CommonDeviceObject(device), RtxPass(device) {
174174
// Volumetrics Options
175175

176-
RTX_OPTION_CLAMP_MIN(froxelGridResolutionScale, static_cast<uint32_t>(1));
177-
RTX_OPTION_CLAMP(froxelDepthSlices, static_cast<uint16_t>(1), std::numeric_limits<uint16_t>::max());
178-
RTX_OPTION_CLAMP(restirFroxelDepthSlices, static_cast<uint16_t>(1), std::numeric_limits<uint16_t>::max());
179-
RTX_OPTION_CLAMP(maxAccumulationFrames, static_cast<uint8_t>(1), std::numeric_limits<uint8_t>::max());
180-
RTX_OPTION_CLAMP_MIN(froxelDepthSliceDistributionExponent, 1e-4f);
181-
RTX_OPTION_CLAMP_MIN(froxelMaxDistanceMeters, 0.0f);
182-
// Note: Clamp to positive values as negative luminance thresholds are not valid.
183-
RTX_OPTION_CLAMP_MIN(froxelFireflyFilteringLuminanceThreshold, 0.0f);
184-
185-
RTX_OPTION_CLAMP_MIN(initialRISSampleCount, static_cast<uint32_t>(1));
186-
RTX_OPTION_CLAMP(temporalReuseMaxSampleCount, static_cast<uint16_t>(1), std::numeric_limits<uint16_t>::max());
187-
188-
RTX_OPTION_CLAMP_MIN(transmittanceMeasurementDistanceMeters, 0.0f);
189-
RTX_OPTION_CLAMP(anisotropy, -1.0f, 1.0f);
190-
191176
transmittanceColor.setDeferred(Vector3(
192177
std::clamp(transmittanceColor().x, 0.0f, 1.0f),
193178
std::clamp(transmittanceColor().y, 0.0f, 1.0f),
@@ -197,21 +182,6 @@ namespace dxvk {
197182
std::clamp(singleScatteringAlbedo().y, 0.0f, 1.0f),
198183
std::clamp(singleScatteringAlbedo().z, 0.0f, 1.0f)));
199184

200-
RTX_OPTION_CLAMP_MIN(noiseFieldSubStepSizeMeters, 0.0f);
201-
RTX_OPTION_CLAMP_MIN(noiseFieldTimeScale, 0.0f);
202-
RTX_OPTION_CLAMP_MIN(noiseFieldDensityScale, 0.0f);
203-
RTX_OPTION_CLAMP_MIN(noiseFieldDensityExponent, 0.0f);
204-
RTX_OPTION_CLAMP(noiseFieldOctaves, static_cast<uint32_t>(1), static_cast<uint32_t>(8));
205-
RTX_OPTION_CLAMP_MIN(noiseFieldInitialFrequencyPerMeter, 0.0f);
206-
RTX_OPTION_CLAMP_MIN(noiseFieldLacunarity, 0.0f);
207-
RTX_OPTION_CLAMP_MIN(noiseFieldGain, 0.0f);
208-
209-
RTX_OPTION_CLAMP_MIN(fogRemapMaxDistanceMinMeters, 0.0f);
210-
RTX_OPTION_CLAMP_MIN(fogRemapMaxDistanceMaxMeters, 0.0f);
211-
RTX_OPTION_CLAMP_MIN(fogRemapTransmittanceMeasurementDistanceMinMeters, 0.0f);
212-
RTX_OPTION_CLAMP_MIN(fogRemapTransmittanceMeasurementDistanceMaxMeters, 0.0f);
213-
RTX_OPTION_CLAMP_MIN(fogRemapColorMultiscatteringScale, 0.0f);
214-
215185
fogRemapMaxDistanceMinMeters.setDeferred(std::min(fogRemapMaxDistanceMinMeters(), fogRemapMaxDistanceMaxMeters()));
216186
fogRemapMaxDistanceMaxMeters.setDeferred(std::max(fogRemapMaxDistanceMinMeters(), fogRemapMaxDistanceMaxMeters()));
217187
fogRemapTransmittanceMeasurementDistanceMinMeters.setDeferred(std::min(fogRemapTransmittanceMeasurementDistanceMinMeters(), fogRemapTransmittanceMeasurementDistanceMaxMeters()));

0 commit comments

Comments
 (0)