A cross-platform engine for desktop input feedback, input visualization, automation mapping, and WASM-powered extensibility.
Star · Issues · Releases · Docs
🇨🇳 中文 | 🇬🇧 English
MFCMouseEffect is not just a mouse-click effect app.
It is evolving into a full desktop interaction-feedback platform with:
- mouse effects:
click / trail / scroll / hold / hover - cursor decoration: native and WASM-backed decoration lanes
- input indicator: mouse, wheel, and keyboard visualization
- automation mapping: mouse actions and gestures to shortcut injection
- WASM plugin runtime: separate
effectsandindicatorsurfaces - shared Web settings UI: cross-platform, observable, and testable
- Mouse Companion: plugin-first desktop companion direction
This project is a great fit if you care about:
- making tutorials, demos, and screen recordings more expressive
- building desktop interaction feedback beyond a few hardcoded animations
- adding bounded, debuggable WASM extensibility inside a C++ host
- maintaining long-term cross-platform desktop architecture across Windows and macOS
- Host-owned rendering boundary: plugins compute logic, the host controls rendering and resources
- Shared semantics and settings flows across Windows and macOS
- WebSettings, diagnostics, regression scripts, and self-checks were designed together
- Native built-ins, plugin lanes, and fallback paths can coexist cleanly
- Clear layering across Core, Platform, Server, WebUI, Tools, and Docs
| Feature | Main Image | Feature | Main Image |
|---|---|---|---|
| Cursor Effects | ![]() |
Cursor Decoration | ![]() |
| Input Indicator | ![]() |
Automation Mapping | ![]() |
| WASM Plugin Runtime | ![]() |
Plugin Management | ![]() |
| Mouse Companion | ![]() |
Shared WebSettings | ![]() |
Feature Overview and Detail Images (expand)
Five core interaction lanes are available:
clicktrailscrollholdhover
Why it matters:
- these are separate capability lanes, not just cosmetic variants of one effect
- type normalization and config mapping are continuously aligned across Windows and macOS
- settings, tuning, and diagnostics are exposed through WebSettings
- parts of the effect stack can be handed off to WASM plugins
The project also has a dedicated cursor-decoration layer:
- built-in
ring / orbdecoration - additive lane independent from the five main effect lanes
- can run as native fallback or a dedicated
cursor_decorationWASM lane - integrated with blacklist policy, fallback control, and plugin state
Input indicator support includes:
- mouse left / right / middle click feedback
- wheel direction and streak labels such as
W+ x2 - keyboard labels and combos such as
Cmd+Tab - relative / absolute positioning
- multi-monitor targeting and offsets
- native fallback and WASM indicator routing
Automation mapping is a real product surface, not a side feature:
- mouse button and wheel mappings to shortcuts
- drag gesture recognition with direction chains such as
up_right - configurable trigger button, sample step, stroke threshold, and max segments
- app-scope matching and deterministic priority behavior
- draw-and-save gesture flow plus self-check and regression coverage
This is one of the strongest differentiators of the project:
- separate
effectsandindicatorsurfaces - manifest load, reload, import, and export flows
- budget control, command validation, fallback, and machine-readable diagnostics
- transient and retained rendering semantics
- ABI documentation and a bundled plugin template
Current command coverage already includes high-value primitives such as:
spawn_textspawn_imagespawn_pulsespawn_polylinespawn_path_strokespawn_path_fillspawn_ribbon_stripspawn_glow_batchspawn_sprite_batchspawn_quad_batch- retained emitter / trail / quad-field / group primitives
The repo already has a dedicated plugin-management surface:
- unified
Plugin Managementsection - policy binding for effect lanes, indicator lanes, and cursor-decoration lanes
- manifest path, enabled-state, failure-state, and fallback visibility
- apply flow reflects real backend state instead of only mutating a form
Plugins are a first-class feature. Start here:
- Template:
examples/wasm-plugin-template/README.md - Core doc:
docs/architecture/custom-effects-wasm-route.md - ABI spec:
docs/architecture/wasm-plugin-abi-v3-design.md - Load path: WebSettings
Plugin Management-> choose manifest -> Apply
More guidance (expand)
- Pick the correct surface:
effectsorindicator - If Apply reverts, check manifest path and load status first
- WebSettings shows diagnostics and fallback state for quick triage
Mouse Companion is one of the most visible active feature directions:
- plugin-first route for long-term extensibility
- macOS currently has a Phase1 visual host
- Windows is on Phase1.5 with renderer seams and runtime diagnostics
- the goal is a sustainable companion architecture, not a one-off pet demo
The current settings UI is organized around focused product areas:
GeneralMouse CompanionCursor EffectsInput IndicatorAutomation MappingPlugin Management
Benefits:
- cleaner capability boundaries
- backend-state-driven apply behavior
- easier platform reuse, debugging, and future expansion
The structure below is ready for later screenshot replacement.
| Module | Preview | Module | Preview |
|---|---|---|---|
| Settings page | ![]() |
Click effect | ![]() |
| Trail effect | ![]() |
Scroll effect | ![]() |
| Hold effect | ![]() |
Hover effect | ![]() |
| Platform | Status | Notes |
|---|---|---|
| Windows 10+ | Stable mainline | Most complete capability set, regression compatibility preserved |
| macOS | Active mainline | Current priority lane for effects, indicator, automation, and WASM |
| Linux | Follow lane | Compile gate and contract coverage focused |
Current project priority is
macOS mainline first, while keeping Windows behavior regression-free.
Recommended path:
- Open
MFCMouseEffect.slnxinVisual Studio 2026 - Use
Release | x64by default - Run
x64/Release/MFCMouseEffect.exe
You can also use the wrapper commands:
.\mfx.cmd build
.\mfx.cmd build --shipping
.\mfx.cmd build --gpu
.\mfx.cmd packageNotes:
builddefaults toRelease | x64 | no-gpubuild --shippingcreates a leaner delivery buildbuild --gpuenables the Windows GPU hold runtime buildpackagegenerates the installer
# Build and run the core host
./mfx run
# Run without rebuilding core/WebUI
./mfx run-no-build
# Fast manual validation with auto stop
./mfx run-no-build --seconds 30
# Effects self-check
./mfx effects
# Recommended daily regression
./mfx verify-effects
# Full POSIX regression suite
./mfx verify-full
# Packaging
./mfx package
./mfx package-no-buildImportant Notes And FAQ (expand)
This section is intentionally front-loaded to reduce install and first-run friction.
Check system permissions first:
AccessibilityInput Monitoring
The macOS runtime depends on those permissions for global input capture.
When permissions are missing, the runtime can degrade gracefully and recover after the permissions are restored.
That is an intentional project policy:
- default is
--no-gpu - it is more stable for the common path
- it avoids extra runtime payload by default
- use
./mfx build --gpuonly when you explicitly want that route
Shipping keeps the main runtime and WebUI, but trims deep testing and heavy diagnostics:
- no full
/api/testdeep test surface - better for delivery
- not the best target for deepest runtime proof workflows
Not yet.
Linux currently follows the project mainly through:
- compile success
- contract coverage
- structural alignment with the mainline architecture
For the best experience, prefer Windows or macOS.
Many settings are backend-state-driven.
If the backend binding did not actually succeed, the UI will reconcile back to the real runtime state instead of pretending the apply succeeded.
Typical things to check:
- manifest path validity
- whether the target lane is enabled
- platform support for that route
- fallback state and plugin load failures
No.
This is one of the core architecture boundaries:
- plugins compute logic
- the host owns rendering execution, budget checks, fallback, and resources
That constraint is deliberate and central to the project's long-term design.
Yes:
- current macOS packages are unsigned
- Gatekeeper may block first launch
- users may need Finder
Openon first run - notarization is not part of the current packaging path yet
Repository Structure (expand)
MFCMouseEffect/
├── MFCMouseEffect/
│ ├── MouseFx/ # Core engine: effects, automation, wasm, diagnostics, server
│ ├── Platform/ # Windows / macOS / Linux implementations
│ ├── WebUIWorkspace/ # Svelte settings UI source
│ ├── Runtime/ # Runtime resources and dependencies
│ ├── Assets/ # Companion and visual assets
│ └── WasmRuntimeBridge/ # WASM runtime bridge layer
├── tools/
│ ├── platform/regression/ # Regression scripts
│ ├── platform/manual/ # Manual and self-check helpers
│ └── docs/ # Doc routing and doc-governance scripts
├── docs/ # Architecture, roadmap, workflow, issue docs
├── examples/ # Examples and templates
└── mfx / mfx.cmd # Preferred command entrypoints
MouseFx/Coreowns semantics and reusable capability contractsPlatform/windows,Platform/macos, andPlatform/linuxkeep platform code separatedMouseFx/ServerplusWebUIWorkspaceform a clear settings-server boundarytools/platform/regressionandtools/platform/manualmake the project verifiable- docs are maintained as part of the engineering system, not as an afterthought
Regression And Self-Check Entry Points (expand)
# Full POSIX suite
./tools/platform/regression/run-posix-regression-suite.sh --platform auto
# Effects-focused suite
./tools/platform/regression/run-posix-effects-regression-suite.sh --platform auto
# Automation contract suite
./tools/platform/regression/run-posix-core-automation-contract-regression.sh --platform auto
# WASM-focused suite
./tools/platform/regression/run-posix-wasm-regression-suite.sh --platform auto# macOS WebSettings manual runner
./tools/platform/manual/run-macos-core-websettings-manual.sh --auto-stop-seconds 60
# macOS effects parity self-check
./tools/platform/manual/run-macos-effects-type-parity-selfcheck.sh --skip-build
# macOS automation injection self-check
./tools/platform/manual/run-macos-automation-injection-selfcheck.sh --skip-build
# macOS WASM runtime self-check
./tools/platform/manual/run-macos-wasm-runtime-selfcheck.sh --skip-buildDocumentation (expand)
- Docs overview: docs/README.md
- Chinese docs index: docs/README.zh-CN.md
- Current active context: docs/agent-context/current.md
- macOS mainline snapshot: docs/refactoring/phase-roadmap-macos-m1-status.md
- P2 capability router: docs/agent-context/p2-capability-index.md
Contributing (expand)
Issues, ideas, suggestions, and pull requests are all welcome.
For larger features, architecture changes, or behavior changes across platforms, it is best to align first before implementation so work does not split across conflicting directions.
Recommended flow:
- open an Issue
- discuss the change briefly
- then send a PR
- for larger collaboration or architecture topics, email first
Contact:
Good contribution areas:
- new visual effects and styles
- WebSettings UX improvements
- WASM plugin samples and tooling
- Windows and macOS behavior alignment
- docs, testing, self-checks, and regression tooling
This project is released under the MIT License.
You are free to use, modify, and distribute it under the license terms.
If it helps, please star ⭐ and share feedback in Issues/Discussions.












