Streammux Source ID

DS Version :- 6.2, Hardware :- Jetson

I have a pipeline that looks like this
appsrc -> jpegparser -> nvv4l2decoder -> streammux -> pgie -> tracker -> sink

Im using need-data callback of appsrc, when it gets invoked, a function read_data is called.

On the other hand, I have a program ( say camera_client) that taken images from cameras and puts them in a redis queue.

when I interface multiple cameras with camera_client, the way it this program is written is, it will take images from n cameras and put them into a redis queue…

when the read_data function reads images from this redis queue, converts them into GstBuffer and pushes them in the pipeline.

the problem is, streammux is assuming that all the images are coming from a single source ( as it should, no complaints). I want it to handle each stream context differently.

can I do this ? → If I attach stream_id as custom_meta to the buffer before I push it in the pipeline and then at sink pad of streammux, I manually update/modify the NvDsFrameMeta->source_id, will this solve my problem? will tracker have different context for each stream if I do this ?
or is there any other way ?

Yes. You can try to set the source id yourself.
As our pipeline can accept multiple sources directly, you can also send multiple camera videos too.
Also the nvstreammux code is open source for DeepStream 6.3, you can also refer to the source code.

okay will check it.

if I change the FrameMeta->source_id at src pad of streammux, should it work? even if all the frames are coming on the same sink pad of the streammux?

Yes. It should work. You can try that.

okay thanks. will try it.

I’m closing this topic due to there is no update from you for a period, assuming this issue was resolved.
If still need the support, please open a new topic. Thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.