Timestamp in second case (4 cams and 8 cams 's result are same) in the below. milli seconds are same but seconds are different.
nvstreammux plugin’s attach-sys-ts option turn off, and call configure_source_for_ntp_sync function in each sources.
[ FRAME_NUM]
CAM_NUM: NTP_TIMESTAMP
…
I used same camera for test.
In first case multi camera syncing is working, but in second case not working.
I can’t upgrade JetPack Version on Jetson Xavier, because I’m using now.
In this case, what is the problem?
Xavier NX or DeepStream 5.0?
NTP can not be supported with your “gst-launch-1.0” pipelines, how do you implement the NTP functions? What have you modified and how do you get NTP timestamp from the pipeline?
DeepStream 4.0 does not support NTP while DeepStream 5.0 has implemented the function of attaching system timestamp to the batched buffer with streammux.
As I said, it happens when I use Jetson Xavier NX with DeepStream 5.0.
The pipeline above is just a sample. I use C code for implementation.
The code below is part of the code.
GstCaps* caps_filter_src = gst_caps_from_string("video/x-raw(memory:NVMM), format=RGBA");
for (int i = 0; i < CAM_NUM; ++i) {
sources[i] = gst_element_factory_make("uridecodebin", ("camera-source-" + to_string(i)).c_str());
g_object_set(G_OBJECT(sources[i]),
"uri",
rtsp_sources[i],
nullptr);
configure_source_for_ntp_sync(sources[i]); // this is function to set ntp option.
nvvidconv_srcs[i] = gst_element_factory_make("nvvideoconvert", ("nvvidconv_src" + to_string(i)).c_str());
filter_srcs[i] = gst_element_factory_make("capsfilter", ("filter_src" + to_string(i)).c_str());
g_object_set(G_OBJECT(filter_srcs[i]), "caps", caps_filter_src, nullptr);
g_signal_connect(sources[i], "pad-added", G_CALLBACK(newPad), nvvidconv_srcs[i]);
gst_bin_add_many(GST_BIN(pipeline), sources[i],
nvvidconv_srcs[i],
filter_srcs[i],
nullptr);
gst_element_link_many(nvvidconv_srcs[i],
filter_srcs[i],
nullptr);
}
gst_caps_unref(caps_filter_src);
video_full_processing_bin = gst_bin_new("video-process-bin");
streammux = gst_element_factory_make("nvstreammux", "stream-muxer");
g_object_set(G_OBJECT(streammux),
"width", 1920,
"height", 1080,
"batch-size", CAM_NUM,
"live-source", 1, // this is option to set live-source
"attach-sys-ts", 0, // this is option to use rtsp camera ntp
nullptr);
We do have configure_source_for_ntp_sync() in DeepStream 5.0. But how could you get NTP timestamp with DeepStream 4.0? You have mentioned case 1 is tested with DS 4.0.
In case 1, multi-camera syncing worked. (I mean there are no ntp timestamp, I just set option “live-option” true.)
When I looked at each frame one by one in my eyes, it worked.
But In case 2, when I looked at each frame one by one in my eyes, it didn’t work.
So I print out ntp timestamp. (in only DeepStream 5.0)
And there are different timestamps.
In conclusion, in DeepStream 4.0 “live-source” option worked very well as I intended.
But in DeepStream 5.0, it doesn’t work.
So I want to know what the problem is.
So there is no NTP timestamp print with case 1, right?
Do you think “live-source” property with nvstreammux will make the multiple camera videos sync?
Yes. There is no NTP timestamp print with case 1.
In case 1, “live-source” property with “nvstreammux” makes the multiple camera videos sync.
In case 2, it doesn’t.