Repository navigation
examples/camera_streamer: add a camera-free mock sender and publish the first decoded picture - #1476
Open
gareth-morgan-nv wants to merge 4 commits into
Open
gareth-morgan-nv wants to merge 4 commits into
gareth-morgan-nv wants to merge 4 commits into
Conversation
Serve AVS1 HEVC over TCP so the receiver and CUDA IPC consumers can run without a Jetson or cameras. Like argus_sender it is the TCP server, serves one receiver at a time and starts each connection at an IDR with a new session. Streams are mono, may run at different rates, and can be paused or disconnected on a schedule. Timing comes from a synthetic clock with a configurable offset and drift; SOF/TSC and Argus frame timestamps are never marked valid. Tests check the records against the receiver's AVS1 parser, mixed-rate presence, resume at an IDR after a pause, and a new session on reconnect. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: Gareth Morgan <gmorgan@nvidia.com>
…tart-of-frame Mark each frame's start-of-frame TSC valid, a fixed --sof-lag-ms before capture-ready, with the matching TSC anchor in the bundle header, so the receiver derives the sensor start time in the sender's wall domain as it does for Argus. The TSC domain is the mock's own and the stamp stays synthetic. Default the synthetic clock offset to zero, as with chrony-synced clocks: consumers that compare sender stamps with the host clock otherwise see the offset as latency. The mock's accept loop now returns when its listener is closed. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: Gareth Morgan <gmorgan@nvidia.com>
…UDA IPC buffers Run mock_sender, the unmodified camera_receiver (NVDEC) and the consumer's CUDA IPC client together. Assert frame geometry, sequence and session metadata, the synthetic SOF lag and real decoded pixels, and that a forced disconnect yields a new session with restarted counters. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: Gareth Morgan <gmorgan@nvidia.com>
The NVDEC parser holds a picture back until the next packet begins unless the packet is marked as a complete picture. Every packet here is exactly one access unit, so the first IDR of each session produced no output and every later picture was published one frame late, under the next frame's metadata. Mark each packet CUVID_PKT_ENDOFPICTURE. The pipeline test now requires stream_sequence 1 first and checks that the decoded luma of flat-level frames matches the metadata frame_number. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: Gareth Morgan <gmorgan@nvidia.com>
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
gareth-morgan-nv
requested review from
farbod-nv,
jsepulveda-nvidia,
nv-jakob and
tengw-nv
November 11, 2026 04:35
This was referenced Nov 11, 2026
gareth-morgan-nv
had a problem deploying
to
dev
November 11, 2026 05:04 — with
GitHub Actions
Failure
This branch had an error being deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Stacked on #1410.
Decode()with no end-of-picture flag, so NVDEC held each picture until the next packet began. The first IDR of every session produced no output and every later picture was published one frame late under the next frame's metadata. Every AVS1 sample is exactly one access unit, so each packet is now markedCUVID_PKT_ENDOFPICTURE, with a pixel-versus-metadata test.Testing
Mock unit and wire tests (
python3 -m unittest discover -s mock_sender/tests) andtests.test_mock_to_ipc_pipeline(needs a GPU). With a flat-luma-per-frame stream the pixel/metadata offset was -1 frame before the fix and 0 after. Nothing here has run on an Orin or real cameras.🤖 Generated with Claude Code