Archive Playback (Streaming)
While video recordings are written to disk as fMP4 for crash resiliency, web browsers and video players require standard HLS streams for random seeking and scrub bar playback.
RUSEON Core bridges this gap via zero-transcode, in-memory on-the-fly transmuxing.
On-the-Fly Transmuxing Architecture
- Box Parsing: When
/hls/:id/archive.m3u8?file=...is requested, the indexer parses the fMP4moov,moof, andmdatatom headers to map all GOPs to segment sequence numbers without loading the whole file into RAM. - Dynamic Segments: When
/hls/:id/segment.ts?file=...&seq=...is fetched, the server seeks directly to the target byte offset in the.mp4file, extracts the raw H.264/H.265 NAL units, and wraps them in MPEG-TS PES packets in a temporarysync.Poolmemory buffer.
Endpoints
1. Archive Master Playlist
- URL:
GET /hls/:id/archive.m3u8?file={filename} - Query Parameter:
file(string, required): Filename inrecordings/<id>/directory. - Response:
#EXTM3Uplaylist containing sequence-indexed.tsreferences.
2. Archive TS Segment
- URL:
GET /hls/:id/segment.ts?file={filename}&seq={index} - Query Parameters:
file: Recording filename.seq: Segment index (0, 1, 2...).
- Response:
video/mp2tsegment data.