Add Vector Screen Holder mod - #5426
Conversation
|
Thanks for the pull request! This repository uses a two-stage review: an AI review that you run yourself, followed by a human review. To get started, comment See the pull request review process for the full details. |
A Windhawk tool mod that fills a chosen display with generative line art and holds the screen awake while it runs. Everything is stroked geometry drawn through Direct2D, generated for whatever size the selected display is. Four styles, each with a wheel parameter and a right-click amount: flow field ribbons, topographic contours, differential growth, and a harmonograph. The overlay sits above the wallpaper but below application windows, never steals focus, and stays out of Alt+Tab. Scenes advance on a wall-clock step clock, so the frame rate changes how smooth the motion is without changing how fast anything draws; contours interpolate between sampled noise fields so their movement stays continuous. Co-Authored-By: Claude AI <noreply@anthropic.com> Co-Authored-By: Big-Pickle (opencode) <noreply@opencode.ai>
79576ff to
86fbb11
Compare
Windhawk 2.0 rejects a setting that uses $options unless its value is a string or an array of strings, which failed the compatibility check against 2.0.0-alpha.3: Failed to parse settings: instance[9].amount must be a string or array of strings to use $options The amount notch was an int (0-4) with numeric option keys. It is now stored by name (minimal / sparse / balanced / dense / maximal) and mapped back to an index on load, which also reads better in the settings UI. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
/ai-review |
Submission reviewNote: This review was done by Claude. Due to the amount of submissions, doing a fully manual review for each pull request is no longer feasible. Thank you for understanding. Remember: The AI reviewer can be wrong - it may misread code, flag correct code as broken, or suggest changes that make things worse. Treat its findings as suggestions to verify, not instructions to follow blindly. You're responsible for the code you submit, so if a finding doesn't hold up, say so instead of changing working code to satisfy it. Please address the following issues. The items in the collapsed sections are optional, so it's your call whether to address them. The tool-mod choice is right, the DPI handling is right, and installing the low-level hook only while the overlay is up is a good instinct. The findings below are mostly about integration with Windhawk and about two behaviours the code doesn't actually deliver. 1. Scope: this is a standalone application, not a modification of an existing program. Windhawk mods change the behaviour of Windows programs; the "mods as tools" pattern exists for utilities that were shell mods and shouldn't be injected (theme scheduler, network indicator, virtual-desktop helper) — they still act on the shell/system. This mod hooks nothing, reads nothing from a host process, and modifies no program's behaviour: it is a ~2,600-line generative-art screensaver plus a keep-awake toggle, packaged as a mod. Expect the maintainer to question whether it belongs in the catalog at all rather than being shipped as a normal Related: the keep-awake half duplicates mods/caffeine.wh.cpp (same 2. The overlay never actually sinks to the bottom of the z-order — its own case WM_WINDOWPOSCHANGING: {
WINDOWPOS* wpos = (WINDOWPOS*)lp;
wpos->flags |= SWP_NOZORDER; // line 1824
return 0;
}so the SetWindowPos(hwnd_, HWND_BOTTOM, 0, 0, 0, 0,
SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE | SWP_NOSENDCHANGING);or, better, re-sink on every position change instead of freezing the z-order: wpos->hwndInsertAfter = HWND_BOTTOM;
wpos->flags &= ~SWP_NOZORDER;3. The 4. void WhTool_ModUninit() {
g_running = false;
if (g_workerThreadId) {
PostThreadMessageW(g_workerThreadId, WM_VSH_QUIT, 0, 0);
}
if (g_thread) {
WaitForSingleObject(g_thread, INFINITE);
CloseHandle(g_thread);
g_thread = nullptr;
}
}This also makes the existing cleanup at the end of 5. The tool-mod boilerplate deviates from the wiki snippet. It should be a verbatim copy of the wiki code so it can be diffed at a glance; two pieces were changed:
Please restore the snippet exactly as published (including the 6. The int amount = ClampT(Wh_GetIntValue(L"state.amount", g_settings.amount), 0, kAmountCount - 1);
float param = ClampT(Wh_GetIntValue(L"state.param", g_settings.parameter * 10), 0, 1000) / 1000.0f;Once the user has right-clicked or scrolled once, 7. Null dereference if device-resource creation partially fails. if (!rt_ && !CreateDeviceResources()) { // line 1724
return;
}
...
buf_->BeginDraw(); // line 1745 — buf_ may be nullAfter a 8. Display configuration changes aren't handled. 9. The README documents an on-screen readout that doesn't exist. "The style name and its two readouts appear only while you are actively changing something, then fade away again" (and the same claim in the PR body) is implemented by: static void Controller_Hud() {
// Reserved for the on-screen readout; the overlay is deliberately clean
// and the values are persisted, so nothing is drawn here yet.
}Please either implement it or remove the claim from the README and delete the stub and its three call sites — as written, a user has no feedback at all about which style, amount or parameter value they just switched to. 10. Add a screenshot or GIF to the README. The mod is entirely visual and has four distinct styles with two axes of variation each; a still per style (or a short GIF) is the only way a user can tell what they're enabling. Only 11. The toggle event is created with an over-broad DACL, in the wrong namespace. // EVENT_MODIFY_STATE only, and Local\ (per-session) rather than Global\.
ConvertStringSecurityDescriptorToSecurityDescriptorW(
L"D:(A;;0x0002;;;WD)S:(ML;;NW;;;LW)", SDDL_REVISION_1, &psd, nullptr);Given that the configurable global hotkey already covers "toggle from anywhere", it's also worth asking whether the named event, its SDDL, and the VBScript in the README are needed at all — dropping them removes this surface entirely. Optional improvements
Minor polish — none of this affects users, so it's your call.
Functionality notes
Non-critical observations and ideas about the feature behaviour itself.
Next steps:
See the review process for details. |
Adds Vector Screen Holder, a tool mod that fills a display of your choosing with generative line art and holds the screen awake while it runs.
The use case it was built for: you're downloading something large, or running a long build, render or backup, and you need the machine not to sign you out or drop to idle. Put the Screen Holder on a side monitor next to your task monitor and walk away — the work keeps running, the screen stays awake, and progress is still readable from across the room.
What it does
windhawk.exeprocess, so it is never injected into other applications.SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED | ES_DISPLAY_REQUIRED), cleared the moment it closes. It does not synthesise input.Styles
Four, each with a wheel parameter (its character) and a right-click amount (how much information is on screen, five notches):
Controls
Esccloses, left click cycles style, right click steps the amount, the wheel adjusts the parameter, and holdingSpaceslides the hue. A configurable global hotkey toggles it, and it also listens on a named event so a desktop shortcut can drive it. The overlay is clean when it opens — labels appear only while you're actively changing something.Notes on implementation
Builds clean with the bundled toolchain at
-O2 -Wall -Wextra.Changelog
If this pull request updates an existing mod, describe the changes below:
Mod authorship
If this pull request introduces a new mod, please complete the section below.
This mod was created by:
Please select the options that best apply. Your selection does not affect the acceptance criteria, but it helps reviewers understand the context of the code and provide relevant feedback.
🤖 Generated with Claude Code