Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ Config LoadConfig(const std::wstring& path) {
"tickHzCap=0\n"
"; vsync: 1=present locked to display refresh (smooth, capped); 0=no vsync, paced by tickHzCap (restart to apply)\n"
"vsync=1\n"
"; dwmFlush: 1=pace the zoomed loop to DWM's composition (smooth, default); 0=old vsync pacing\n"
"dwmFlush=1\n"
"; dwmFlush: 0=plain vsync pacing (default, fewer stutters); 1=align to DWM's composition\n"
"dwmFlush=0\n"
"; diagnostics=1 logs frame timing to %TEMP%\\wind_diag.log (restart to apply)\n"
"diagnostics=0\n"
"; cursorSensitivity: pan speed per raw count\n"
Expand Down
10 changes: 5 additions & 5 deletions src/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ struct Config {
// Present sync while zoomed (render engine): 1 = vsync (Present sync-interval 1, locked to
// the display refresh); 0 = no vsync (Present 0), with the loop paced by tickHzCap instead.
int vsync = 1;
// Pace the zoomed loop with DwmFlush() instead of vsync/timer: present immediately (no vsync
// block) then block until DWM's next composition, so our frames align 1:1 with the
// compositor. Fixes the blt-model microstutter (phase mismatch between our Present and DWM's
// composite) - default ON. 1 = on (overrides vsync while zoomed), 0 = old vsync pacing.
int dwmFlush = 1;
// Zoomed-loop pacing. 0 (default) = plain vsync Present(1,0); measured fewer stutters in
// general (desktop + games), and it doesn't slip toward half-rate under a heavy fullscreen
// game the way DwmFlush can. 1 = present immediately then DwmFlush() to align 1:1 with DWM's
// composition (overrides vsync while zoomed). Hot-reloadable.
int dwmFlush = 0;
int diagnostics = 0; // 1 = log frame-timing to wind_diag.log

// --- Own GPU renderer ---------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion tests/test_config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ TEST_CASE("renderer knobs have sane defaults") {
CHECK(c.hdrTonemap == 1); // on by default (no-op on SDR)
CHECK(c.cursorVisibility == "auto"); // follow the focused app by default
CHECK(c.vsync == 1); // vsync on by default
CHECK(c.dwmFlush == 1); // DwmFlush pacing on by default (the smooth path)
CHECK(c.dwmFlush == 0); // plain vsync pacing by default (fewer stutters)
CHECK(c.tickHzCap == 0); // 0 = auto-detect display refresh rate
}
TEST_CASE("vsync, dwmFlush, tickHzCap can be set") {
Expand Down
6 changes: 3 additions & 3 deletions tools/uiaccess_setup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,9 @@ brightness=1.0
hdrTonemap=1
tickHzCap=0
vsync=1
; dwmFlush: 1=pace the zoomed loop to DWM's composition (microstutter test). Hot-reloadable -
; edit this to 0 and save to compare (run notepad as admin, or via the tray "Edit config").
dwmFlush=1
; dwmFlush: 0=plain vsync pacing (default, fewer stutters); 1=align to DWM's composition.
; Hot-reloadable - edit and save to compare (notepad as admin, or the tray "Edit config").
dwmFlush=0
"@
Set-Content -Path "C:\Program Files\Wind\magnifier.ini" -Value $ini -Encoding ASCII

Expand Down
Loading