Files
wled-screen-controller-mixed/TODO.md
alexei.dolgolyov 294d704eb0 Add CSPT entity, processed CSS source type, reverse filter, and UI improvements
- Add Color Strip Processing Template (CSPT) entity: reusable filter chains
  for 1D LED strip postprocessing (backend, storage, API, frontend CRUD)
- Add "processed" color strip source type that wraps another CSS source and
  applies a CSPT filter chain (dataclass, stream, schema, modal, cards)
- Add Reverse filter for strip LED order reversal
- Add CSPT and processed CSS nodes/edges to visual graph editor
- Add CSPT test preview WS endpoint with input source selection
- Add device settings CSPT template selector (add + edit modals with hints)
- Use icon grids for palette quantization preset selector in filter lists
- Use EntitySelect for template references and test modal source selectors
- Fix filters.css_filter_template.desc missing localization
- Fix icon grid cell height inequality (grid-auto-rows: 1fr)
- Rename "Processed" subtab to "Processing Templates"
- Localize all new strings (en/ru/zh)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 02:16:59 +03:00

4.3 KiB
Raw Blame History

Pending Features & Issues

Priority: P1 quick win · P2 moderate · P3 large effort

Processing Pipeline

  • P3 Transition effects — Crossfade, wipe, or dissolve between sources/profiles instead of instant cut
    • Complexity: large — requires a new transition layer concept in ProcessorManager; must blend two live streams simultaneously during switch, coordinating start/stop timing
    • Impact: medium — polishes profile switching UX but ambient lighting rarely switches sources frequently

Output Targets

  • P2 Art-Net / sACN (E1.31) — Stage/theatrical lighting protocols, DMX controllers
    • Complexity: medium — UDP-based protocols with well-documented specs; similar architecture to DDP client; needs DMX universe/channel mapping UI
    • Impact: medium — opens stage/theatrical use case, niche but differentiating

Capture Engines

  • P3 SCRCPY capture engine — Implement SCRCPY-based screen capture for Android devices
    • Complexity: large — external dependency on scrcpy binary; need to manage subprocess lifecycle, parse video stream (ffmpeg/AV pipe), handle device connect/disconnect
    • Impact: medium — enables phone screen mirroring to ambient lighting; appeals to mobile gaming use case

Code Health

  • P1 "Start All" targets button — "Stop All" exists but "Start All" is missing
  • P2 Manual backup trigger endpointPOST /system/auto-backup/trigger (~5 lines)
  • P2 Scene snapshot should capture device brightnesssoftware_brightness not saved/restored
  • P2 Distinguish "crashed" vs "stopped" in dashboardmetrics.last_error is already populated
  • P3 CSS source import/export — share individual sources without full config backup

Backend Review Fixes (2026-03-14)

Performance

  • P1 PIL blocking in async handlers → asyncio.to_thread
  • P2 subprocess.run blocking event loop → asyncio.create_subprocess_exec
  • P3 Audio enum blocking async → asyncio.to_thread
  • P4 Display enum blocking async → asyncio.to_thread
  • P5 colorsys scalar loop in hot path → vectorize numpy
  • P6 MappedStream per-frame allocation → double-buffer
  • P7 Audio/effect per-frame temp allocs → pre-allocate
  • P8 Blocking httpx.get in stream init → documented (callers use to_thread)
  • P9 No-cache middleware runs on all requests → scope to static
  • P10 Sync file I/O in async handlers (stores) → documented as accepted risk (< 5ms)
  • P11 frame_time float division every loop iter → cache field
  • P12 _check_name_unique O(N) + no lock → add threading.Lock
  • P13 Imports inside 1-Hz metrics loop → move to module level

Code Quality

  • Q1 DeviceStore not using BaseJsonStore
  • Q2 ColorStripStore 275-line god methods → factory dispatch
  • Q3 Layer violation: core imports from routes → extract to utility
  • Q4 20+ field-by-field update in Device/routes → dataclass + generic update
  • Q5 WebSocket auth copy-pasted 9x → extract helper
  • Q6 set_device_brightness bypasses store → use update_device
  • Q7 DI via 16+ module globals → registry pattern
  • Q8 _css_to_response 30+ getattr → polymorphic to_response
  • Q9 Private attribute access across modules → expose as properties
  • Q10 ColorStripSource.to_dict() emits ~25 nulls → per-subclass override
  • Q11 DeviceStore.get_device returns None vs raises → raise ValueError
  • Q12 list_all_tags fragile method-name probing → use get_all()
  • Q13 Route create/update pass 30 individual fields → **kwargs

UX

  • P1 Collapse dashboard running target stats — Show only FPS chart by default; uptime, errors, and pipeline timings in an expandable section collapsed by default
  • P1 Daylight brightness value source — New value source type that reports a 0255 brightness level based on daylight cycle time (real-time or simulated), reusing the daylight LUT logic
  • P1 Tags input: move under name, remove hint/title — Move the tags chip input directly below the name field in all entity editor modals; remove the hint toggle and section title for a cleaner layout