Expand description
In-memory helpers for exercising the engine in downstream tests.
None of this is required at runtime; it exists so consumers can verify
their MediaSource/MediaSink/Observer implementations against a real
engine without standing up a socket.
Structs§
- Collecting
Sink - A
MediaSinkthat records every frame it receives. Useful for asserting what a pipeline produced. - Counting
Observer - An
Observerthat counts the events it sees. Cheap to clone (shared counters) so a copy can be handed to the engine and another kept for asserts. - InMemory
Storage - An in-memory
StorageBackendfor testing packagers and recorders without touching the filesystem. Cheap to clone (shared object map). - Null
Sink - A
MediaSinkthat discards everything — the/dev/nullof sinks.
Functions§
- audio_
frame - Build an audio
MediaFrameatpts(ms). - video_
frame - Build a video
MediaFrameatpts(ms), keyframe or delta. A terse fixture for tests and examples.