Add resilient SRT stream requirements
This commit is contained in:
parent
2feec62654
commit
3aa401ffac
6 changed files with 101 additions and 0 deletions
|
|
@ -27,6 +27,8 @@ Build a fast C++ Unreal Engine plugin called/described as `SRT Stream Unreal Eng
|
|||
- Plugin should output native Unreal resources such as dynamic texture, render target, material instance, and a stream plate actor/component.
|
||||
- Motion Design compatibility is important: streams should be usable as normal scene/media/texture elements as much as possible.
|
||||
- Leading MVP direction is FFmpeg with SRT support, or libsrt plus FFmpeg/libavcodec.
|
||||
- Stream receiver must be resilient: phone disconnects, restarts, reconnects, changed bitrate, resolution, frame rate, codec/profile, or timing should not break the Unreal scene.
|
||||
- Missing video should automatically show a technical fallback slate with stream/phone/rider metadata, then switch back to live video when the stream returns.
|
||||
|
||||
## Current State
|
||||
|
||||
|
|
@ -38,6 +40,7 @@ The knowledge base now treats `SRT Stream Unreal Engine Plugin` as the first con
|
|||
- Scaffold the SRT Stream plugin.
|
||||
- Choose and package FFmpeg/SRT or libsrt plus FFmpeg dependencies.
|
||||
- Implement one listener and render decoded frames to a texture/render target.
|
||||
- Implement no-signal/reconnect/error recovery and automatic fallback slate early.
|
||||
- Expose stream controls through Remote Control.
|
||||
- Verify a synthetic SRT stream before testing Android phone streaming.
|
||||
|
||||
|
|
|
|||
|
|
@ -16,3 +16,12 @@
|
|||
- Design direction: Expose add/delete/start/stop stream controls, port, passphrase, latency, stream name/id, and status through Remote Control. Output decoded frames as Unreal texture/render target/material through a stream actor/component such as `ASrtStreamPlateActor`, with later Media Framework compatibility considered if needed for Motion Design/Media Plate.
|
||||
- Files changed: Updated translation technical specification, status, decisions, repositories, notes, and agent log.
|
||||
- Next handoff: On the Unreal computer, create or locate a C++ Unreal project, scaffold the SRT Stream plugin, choose dependency packaging for FFmpeg/SRT or libsrt plus FFmpeg, and make one listener render to a texture/render target before adding multiple streams.
|
||||
|
||||
## 2026-06-02 - Resilient Stream And Technical Slate Requirement
|
||||
|
||||
- Machine: current Codex Mac.
|
||||
- Agent: Codex.
|
||||
- Summary: User clarified that the SRT Stream plugin must be broadcast-resilient. If a phone disconnects, restarts, or returns with different bitrate/resolution/frame rate/codec/profile, the stream actor should recover rather than breaking the scene. While video is missing, the output should switch to an automatic technical fallback slate and switch back to live video when the stream returns.
|
||||
- Design direction: Add a stream state machine with recoverable states such as `Idle`, `Listening`, `WaitingForSignal`, `Receiving`, `Reconnecting`, `NoSignal`, and `Error`. Keep stream metadata such as stream id, phone/device name, rider/athlete name, team/number, listener port, status, last seen time, and last known video parameters. Motion Design overlays and telemetry should keep running over fallback slate mode.
|
||||
- Files changed: Updated translation technical specification, status, decisions, notes, agent log, and dialogue summary.
|
||||
- Next handoff: On the Unreal computer, include reconnect/no-signal handling and fallback slate output in the first plugin architecture, not as a late afterthought.
|
||||
|
|
|
|||
|
|
@ -29,3 +29,15 @@ Reason: This keeps the system fast and compatible with Unreal/Motion Design work
|
|||
Decision: The SRT plugin should present streams as designer-friendly Unreal resources, such as `ASrtStreamPlateActor`, component, dynamic texture, render target, material instance, or later a Media Framework compatible source. Motion Design should be able to use SRT streams as normal scene/media/texture elements.
|
||||
|
||||
Reason: The user wants SRT phone streams to fit existing Unreal Engine Motion Design tooling rather than become a closed custom subsystem.
|
||||
|
||||
## 2026-06-02 - SRT Stream Receiver Must Be Resilient
|
||||
|
||||
Decision: The SRT Stream plugin must treat phone disconnects, sender restarts, reconnects, and changed stream parameters as normal recoverable events. It should keep the Unreal scene and Motion Design layout alive, switch to a technical fallback slate while video is missing, and switch back to live video when the stream returns.
|
||||
|
||||
Reason: The user wants broadcast-grade reliability. If a phone stops transmitting or returns with a different bitrate, resolution, frame rate, codec/profile, or timing, the operator should not see a broken scene or need to rebuild the stream element.
|
||||
|
||||
## 2026-06-02 - Technical Fallback Slate Carries Stream Metadata
|
||||
|
||||
Decision: Each stream should keep metadata such as stream id/name, phone/device name, rider/athlete name, team/number if available, listener port, status, last seen time, and last known video parameters. The fallback slate should display enough of this information for an operator to know which rider/phone stream is missing.
|
||||
|
||||
Reason: During a lost phone stream, Motion Design overlays and telemetry should continue, and the technical picture should explain what source is expected instead of showing black or an error.
|
||||
|
|
|
|||
|
|
@ -36,3 +36,30 @@ Android camera app
|
|||
The best MVP direction is likely FFmpeg with SRT support, or libsrt plus FFmpeg/libavcodec. CPU decode is acceptable for the first proof. GPU decode can be investigated later if latency or CPU load requires it.
|
||||
|
||||
For Motion Design compatibility, avoid a closed custom-only system. The plugin should expose SRT streams as normal Unreal scene/media resources as much as practical: stream actor/component, output texture/render target, material instance, and possibly later Media Framework source/player support.
|
||||
|
||||
## 2026-06-02 Resilient Stream Requirement
|
||||
|
||||
The user clarified that the plugin must be very resilient. A phone stream can disappear and later return with different parameters. This must not break the Unreal scene or Motion Design page.
|
||||
|
||||
Expected behavior:
|
||||
|
||||
- phone stops streaming -> stream actor switches to technical fallback slate;
|
||||
- phone reconnects -> stream actor switches back to live video automatically;
|
||||
- phone restarts sender with different bitrate/resolution/frame rate/codec profile -> plugin attempts to renegotiate/reinitialize decoding and continue;
|
||||
- Motion Design overlays and telemetry remain active while video is missing;
|
||||
- stream identity persists across reconnects.
|
||||
|
||||
The technical slate should be automatic. It can be generated in Unreal from a PNG/background plus text, material, UMG/widget render target, TextRender overlay, or a future Motion Design template.
|
||||
|
||||
The slate should show useful operator information:
|
||||
|
||||
- stream id/name;
|
||||
- phone/device name;
|
||||
- rider/athlete name;
|
||||
- team/number when available;
|
||||
- listener port;
|
||||
- current state such as `WAITING FOR SRT`, `NO SIGNAL`, or `RECONNECTING`;
|
||||
- last seen time;
|
||||
- last known codec/resolution/frame rate/bitrate if available.
|
||||
|
||||
The core idea is that the stream plate always renders something usable: either live video or a technical picture explaining what source is missing.
|
||||
|
|
|
|||
|
|
@ -12,6 +12,9 @@ Create a live broadcast workflow where an Android phone sends camera video over
|
|||
- First concrete module is `SRT Stream Unreal Engine Plugin`: a fast C++ Unreal plugin that receives SRT streams, exposes listener controls through Remote Control Web API, and outputs Unreal-usable textures/render targets/materials for Motion Design.
|
||||
- Remote Control Web API is a control surface only, not the video transport path.
|
||||
- MVP target: Unreal acts as SRT listener; Android phone acts as SRT caller.
|
||||
- New resilience requirement: the stream receiver must survive phone disconnects, sender restarts, reconnects, and changed stream parameters such as bitrate, resolution, frame rate, codec/profile, or timing.
|
||||
- When video is unavailable, the stream actor should automatically show a technical fallback slate instead of black/broken video. When video returns, it should switch back to live video automatically.
|
||||
- Stream metadata should persist across disconnects, including stream name/id, phone/device name, rider/athlete name, team/number if available, listener port, status, and last seen/last known video parameters.
|
||||
- Leading implementation approach: FFmpeg with SRT support, or libsrt plus FFmpeg/libavcodec, with decoded frames uploaded to a dynamic texture or render target.
|
||||
- Android phone is the expected camera source.
|
||||
- An existing Android/sensor app exists, but the repository and implementation details have not been reviewed yet.
|
||||
|
|
@ -25,6 +28,8 @@ Create a live broadcast workflow where an Android phone sends camera video over
|
|||
- Create or locate a C++ Unreal Engine project for the SRT Stream plugin.
|
||||
- Scaffold `SRT Stream Unreal Engine Plugin`.
|
||||
- Implement one SRT listener with configurable port, stream name, passphrase placeholder, and latency.
|
||||
- Implement stream state machine for `Idle`, `Listening`, `WaitingForSignal`, `Receiving`, `Reconnecting`, `NoSignal`, and recoverable `Error`.
|
||||
- Implement automatic technical fallback slate for no-signal states, with stream/rider/phone metadata.
|
||||
- Output decoded frames to an Unreal texture/render target and display them through a stream actor/material.
|
||||
- Expose stream control through Unreal Remote Control Web API.
|
||||
- Create a small test plan for synthetic SRT stream first, then Android phone stream.
|
||||
|
|
@ -37,6 +42,8 @@ Create a live broadcast workflow where an Android phone sends camera video over
|
|||
- Existing Android app repository/path is not known.
|
||||
- Dependency/package path for FFmpeg/SRT or libsrt is not selected.
|
||||
- Exact Unreal output integration is not selected: dynamic texture/render target first vs full Media Framework integration.
|
||||
- Exact fallback slate implementation is not selected: generated material, PNG plus text, UMG/widget render target, Motion Design template, or another approach.
|
||||
- Exact MVP handling of parameter changes is not selected: resolution/framerate/bitrate changes only, or full codec/profile changes as well.
|
||||
- Telemetry protocol/format is not known.
|
||||
|
||||
## Open Questions
|
||||
|
|
@ -46,5 +53,7 @@ Create a live broadcast workflow where an Android phone sends camera video over
|
|||
- Should the first proof use a test SRT sender before the phone?
|
||||
- Should stream outputs be implemented first as dynamic textures/render targets, or as Media Framework compatible sources?
|
||||
- Which object should Remote Control expose first: stream manager subsystem, manager actor, individual stream actors, or a combination?
|
||||
- What metadata fields are required to bind a phone stream to a rider/athlete in the first version?
|
||||
- What should the first technical slate look like, and should it be generated entirely in Unreal?
|
||||
- What latency and quality targets are acceptable?
|
||||
- What final broadcast output path is required?
|
||||
|
|
|
|||
|
|
@ -49,6 +49,29 @@ Later scope includes:
|
|||
- set passphrase when SRT encryption is used;
|
||||
- set latency and other safe listener parameters;
|
||||
- report status such as `idle`, `waiting`, `connected`, `receiving`, `error`, and `stopped`.
|
||||
- The plugin must be resilient to stream loss, reconnects, and changed stream parameters. If a phone stops transmitting, restarts, reconnects, or returns with different bitrate, resolution, frame rate, codec/profile, or stream timing, the stream object should recover without crashing Unreal, breaking the scene, or requiring the operator to rebuild the Motion Design layout.
|
||||
- Recoverable stream state should be represented explicitly, for example:
|
||||
- `Idle`;
|
||||
- `Listening`;
|
||||
- `WaitingForSignal`;
|
||||
- `Receiving`;
|
||||
- `Reconnecting`;
|
||||
- `NoSignal`;
|
||||
- `Error`.
|
||||
- `Error` should be treated as recoverable whenever possible. It should not mean the stream actor, scene, or Motion Design page is dead.
|
||||
- When live video is unavailable, the stream output should automatically switch to a technical fallback slate rather than black video or a broken material.
|
||||
- When live video returns, the stream output should automatically switch back from the technical slate to live video.
|
||||
- The fallback slate should identify the missing stream and expected source. It should support metadata such as:
|
||||
- stream id/name;
|
||||
- phone/device name;
|
||||
- rider/athlete name;
|
||||
- team/number when available;
|
||||
- listener port;
|
||||
- current status;
|
||||
- last seen time;
|
||||
- last known codec/resolution/frame rate/bitrate when available.
|
||||
- The fallback slate may be implemented as a generated Unreal material, UMG/widget render target, TextRender/UMG overlay, or PNG/background texture plus generated text. For MVP, a simple generated technical slate is acceptable.
|
||||
- Motion Design overlays, telemetry graphics, and layout should keep running when the live video source is missing. Only the stream plate's video content should switch between live video and fallback slate.
|
||||
- Remote Control Web API is only the control layer. Video frames must not be transported through the web API.
|
||||
- The plugin should expose a designer-friendly stream object, such as `ASrtStreamPlateActor` or equivalent component, that can be placed in a scene.
|
||||
- Each stream object should provide an Unreal-usable output:
|
||||
|
|
@ -77,6 +100,7 @@ Later scope includes:
|
|||
- The ingest path should be documented with exact plugin, dependency, build, and runtime steps.
|
||||
- Latency, stability, and stream recovery behavior should be measured once the first stream works.
|
||||
- The plugin should prioritize low latency and runtime performance.
|
||||
- The plugin should prioritize broadcast-grade robustness: stream dropouts, phone restarts, sender reconnects, and parameter changes should be normal operating events, not fatal errors.
|
||||
- The first implementation may use FFmpeg with SRT support, or libsrt plus FFmpeg/libavcodec, if that gives the fastest practical MVP.
|
||||
- CPU decode is acceptable for first proof. GPU decode such as NVDEC/D3D11/D3D12 can be investigated later if performance requires it.
|
||||
- The integration should avoid locking the project into a web-only control model; Remote Control Web API is for operator controls, while video ingest/rendering remains native Unreal C++.
|
||||
|
|
@ -96,6 +120,7 @@ Later scope includes:
|
|||
- The leading MVP approach is FFmpeg with SRT support inside a C++ Unreal plugin, receiving `srt://` listener streams and uploading decoded frames to an Unreal texture/render target.
|
||||
- A fuller Media Framework integration may be evaluated later if it improves compatibility with Media Plate, Motion Design, Sequencer, or broadcast workflows.
|
||||
- Motion Design should be able to treat SRT streams like normal media/texture scene elements as much as possible.
|
||||
- A stream source should carry identity/metadata separate from the current video connection, so a rider/phone assignment survives disconnects and reconnects.
|
||||
|
||||
## Data And Inputs
|
||||
|
||||
|
|
@ -105,6 +130,12 @@ Later scope includes:
|
|||
- wheel speed;
|
||||
- heart rate.
|
||||
- Race metadata for overlays, to be defined later.
|
||||
- Stream metadata for technical slates and Motion Design binding:
|
||||
- stream id/name;
|
||||
- phone/device name;
|
||||
- rider/athlete name;
|
||||
- team/number if available;
|
||||
- expected listener port.
|
||||
- Graphic/title design requirements, to be defined later.
|
||||
|
||||
## Output
|
||||
|
|
@ -112,6 +143,7 @@ Later scope includes:
|
|||
- Unreal Engine scene containing the live video feed.
|
||||
- One or more SRT stream plate actors/components or equivalent scene elements.
|
||||
- Output texture/render target/material per active SRT stream.
|
||||
- Automatic technical fallback slate when a stream is not currently receiving live video.
|
||||
- Motion Design overlays composited over the feed.
|
||||
- Final broadcast output path is not yet defined.
|
||||
|
||||
|
|
@ -124,6 +156,10 @@ Later scope includes:
|
|||
- Operator can configure at least port and stream name through exposed controls.
|
||||
- Passphrase and latency are represented in the plugin API even if encryption/performance tuning are not fully validated in the first MVP.
|
||||
- Motion Design can use the stream output as a scene/media/texture element for overlay work.
|
||||
- If the phone stream stops, Unreal remains stable and the stream actor switches to a technical fallback slate.
|
||||
- If the phone stream reconnects with changed bitrate/resolution/frame rate/codec profile, the plugin attempts to recover and display the returned stream without recreating the scene.
|
||||
- Fallback slate includes enough text metadata for an operator to identify which phone/rider/stream is missing.
|
||||
- Telemetry/Motion Design overlays continue to function while video is in fallback slate mode.
|
||||
- The setup steps are documented well enough for another agent to reproduce.
|
||||
- At least one verified restore-point commit/tag exists for the working SRT ingest milestone once implementation starts.
|
||||
- Failed ingest approaches are documented and preserved on separate branches when useful.
|
||||
|
|
@ -137,6 +173,9 @@ Later scope includes:
|
|||
- Implement one SRT listener using FFmpeg/SRT or libsrt plus FFmpeg.
|
||||
- Decode the video stream and upload frames to a dynamic texture or render target.
|
||||
- Create the first stream actor/component, such as `ASrtStreamPlateActor`.
|
||||
- Add resilient stream state handling for no-signal/reconnect/error recovery.
|
||||
- Add automatic technical fallback slate for no-signal state.
|
||||
- Add stream metadata fields for phone/device and rider/athlete assignment.
|
||||
- Expose stream properties/functions to Remote Control.
|
||||
- Create a simple Remote Control web page or use the existing Remote Control web app to start/stop/configure the listener.
|
||||
- Test with a local synthetic SRT stream.
|
||||
|
|
@ -159,6 +198,8 @@ Later scope includes:
|
|||
- Should the MVP output be a dynamic texture/render target first, or should the plugin immediately implement a Media Framework source/player?
|
||||
- What exact Remote Control exposed object structure should be used: manager actor, subsystem, stream actors, or all three?
|
||||
- How should Motion Design pages select and bind a stream source?
|
||||
- What is the final fallback slate design: generated material, UMG render target, Motion Design template, PNG background plus text, or another approach?
|
||||
- Which stream parameter changes must be handled in MVP: resolution, frame rate, bitrate, codec profile, or full codec changes such as H.264 to H.265?
|
||||
- What resolution, frame rate, bitrate, and latency are required?
|
||||
- What is the target final output: Unreal viewport, NDI, SDI, RTMP/SRT out, recording, or another path?
|
||||
- What exact cycling race graphics are required?
|
||||
|
|
|
|||
Reference in a new issue