Emerald::VLC::EventManager
Thread-safe event queue bridging LibVLC background threads to Godot's main thread. Uses a fixed ring-buffer and OS Thread::Mutex to guarantee zero Boehm GC allocations or fiber context switches when handling LibVLC C callback notifications.
Constants
QUEUE_CAPACITY = 64
Constructors
new(handle : LibVLC::EventManager)
SourceInstance methods
finalize
Sourcehandle
Sourcehandle_native_event(event : LibVLC::Event) : Nil
Called by LibVLC on a background worker thread. Must perform ZERO allocations and only lock the OS Thread::Mutex.
on_ended
Sourceon_ended=(on_ended : -> Nil | Nil)
Sourceon_error
Sourceon_length_changed
Sourceon_paused
Sourceon_paused=(on_paused : -> Nil | Nil)
Sourceon_playing=(on_playing : -> Nil | Nil)
Main-thread Crystal callbacks registered by player or node
on_position_changed
Sourceon_stopped
Sourceon_stopped=(on_stopped : -> Nil | Nil)
Sourceon_time_changed
Sourcepoll_events
Dispatches all pending events to registered callbacks. Must be called regularly on the main thread (e.g. from Godot _process).