forked from genewildish/Mainline
refactor: modularize display backends and add benchmark runner
- Create engine/display/ package with registry pattern - Move displays to engine/display/backends/ (terminal, null, websocket, sixel) - Add DisplayRegistry with auto-discovery - Add benchmark.py for performance testing effects × displays matrix - Add mise tasks: benchmark, benchmark-json, benchmark-report - Update controller to use new display module
This commit is contained in:
@@ -3,18 +3,25 @@ Stream controller - manages input sources and orchestrates the render stream.
|
||||
"""
|
||||
|
||||
from engine.config import Config, get_config
|
||||
from engine.display import MultiDisplay, NullDisplay, SixelDisplay, TerminalDisplay
|
||||
from engine.display import (
|
||||
DisplayRegistry,
|
||||
MultiDisplay,
|
||||
NullDisplay,
|
||||
SixelDisplay,
|
||||
TerminalDisplay,
|
||||
WebSocketDisplay,
|
||||
)
|
||||
from engine.effects.controller import handle_effects_command
|
||||
from engine.eventbus import EventBus
|
||||
from engine.events import EventType, StreamEvent
|
||||
from engine.mic import MicMonitor
|
||||
from engine.ntfy import NtfyPoller
|
||||
from engine.scroll import stream
|
||||
from engine.websocket_display import WebSocketDisplay
|
||||
|
||||
|
||||
def _get_display(config: Config):
|
||||
"""Get the appropriate display based on config."""
|
||||
DisplayRegistry.initialize()
|
||||
display_mode = config.display.lower()
|
||||
|
||||
displays = []
|
||||
|
||||
Reference in New Issue
Block a user