Hi
I change JetPack Version form 4.2.1 to 4.4.
And then nvv4l2decoder doesn’t seem to work.
Has anything changed?
$ GST_DEBUG=3 ./main
- ViVA Server starting…
rtsp://admin:visionin123@192.168.1.80:554/onvif/profile10/media.smp
start()
thread start - m_uniqueId 0
Opening in BLOCKING MODE
0:00:00.210808773 30658 0x7f782d6440 WARN v4l2 gstv4l2object.c:4435:gst_v4l2_object_probe_caps:nvv4l2decoder0:src Failed to probe pixel aspect ratio with VIDIOC_CROPCAP: Unknown error -1
0:00:00.210927718 30658 0x7f782d6440 WARN v4l2 gstv4l2object.c:2372:gst_v4l2_object_add_interlace_mode:0x7f782b12d0 Failed to determine interlace mode
Pipeline ready, Now Running
0:00:00.458822657 30658 0x7f7003d770 FIXME default gstutils.c:3981:gst_pad_create_stream_id_internal:fakesrc0:src Creating random stream-id, consider implementing a deterministic way of creating a stream-id
0:00:00.462739948 30658 0x7f7003de30 FIXME default gstutils.c:3981:gst_pad_create_stream_id_internal:fakesrc1:src Creating random stream-id, consider implementing a deterministic way of creating a stream-id
0:00:00.480185291 30658 0x7f400034a0 FIXME basesink gstbasesink.c:3145:gst_base_sink_default_event: stream-start event without group-id. Consider implementing group-id handling in the upstream elements
NvMMLiteOpen : Block : BlockType = 261
NVMEDIA: Reading vendor.tegra.display-size : status: 6
0:00:00.506134983 30658 0x7f7003dca0 WARN basesrc gstbasesrc.c:3055:gst_base_src_loop: error: Internal data stream error.
0:00:00.506455947 30658 0x7f7003dca0 WARN basesrc gstbasesrc.c:3055:gst_base_src_loop: error: streaming stopped, reason not-linked (-1)
NvMMLiteBlockCreate : Block : BlockType = 261
(main:30658): GStreamer-CRITICAL **: 11:50:42.992: gst_mini_object_unref: assertion ‘mini_object != NULL’ failed
This is part of my code.
GstElement *source, *depay, *parse, *decode, *sink, *fps_sink, *conv, *filter1, *filter2;
gst_init(NULL,NULL);
// 파이프라인과 구성 요소들을 생성한다.
g_pipeline[m_uniqueId] = gst_pipeline_new (name_pipeline[m_uniqueId].c_str());
if (!g_pipeline[m_uniqueId]) {
std::cout << "pipeline could not be created\n" << std::endl;
return;
}
source = gst_element_factory_make ("rtspsrc", name_source[m_uniqueId].c_str());
if (!source) {
std::cout << "rtspsrc could not be created\n" << std::endl;
return;
}
depay = gst_element_factory_make ("rtph264depay", name_depay[m_uniqueId].c_str());
if (!depay) {
std::cout << "rtph264depay could not be created\n" << std::endl;
return;
}
parse = gst_element_factory_make ("h264parse", NULL);
if (!parse) {
std::cout << "h264parse could not be created\n" << std::endl;
return;
}
decode = gst_element_factory_make ("nvv4l2decoder", NULL);
if (!decode) {
std::cout << "nvv4l2decoder could not be created\n" << std::endl;
return;
}
sink = gst_element_factory_make ("appsink", NULL);
if (!sink) {
std::cout << "appsink could not be created\n" << std::endl;
return;
}
fps_sink = gst_element_factory_make ("fpsdisplaysink", name_fpssink[m_uniqueId].c_str());
if (!fps_sink){
std::cout << "fpsdisplaysink could not be created\n" << std::endl;
return;
}
filter1 = gst_element_factory_make ("capsfilter", NULL);
if (!filter1){
std::cout << "filter1 could not be created\n" << std::endl;
return;
}
filter2 = gst_element_factory_make ("capsfilter", NULL);
if (!filter2){
std::cout << "filter2 could not be created\n" << std::endl;
return;
}
conv = gst_element_factory_make ("nvvidconv", NULL);
if (!conv){
std::cout << "nvvidconv could not be created\n" << std::endl;
return;
}
GstCaps *caps1, *caps2;
caps1 = gst_caps_from_string ("video/x-raw(memory:NVMM)");
caps2 = gst_caps_from_string ("video/x-raw");
g_object_set (G_OBJECT (filter1), "caps", caps1, NULL);
g_object_set (G_OBJECT (filter2), "caps", caps2, NULL);
gst_caps_unref (caps1);
gst_caps_unref (caps2);
g_object_set (G_OBJECT(source), "location", m_strSrcAddr.c_str(), NULL);
g_object_set(G_OBJECT(sink), "emit-signals", true, NULL);
g_object_set(G_OBJECT(sink), "async", false, "sync", false, "max-lateness", 0, NULL);
g_object_set(G_OBJECT(sink), "max-buffers", 1, NULL);
g_object_set(G_OBJECT(sink), "drop", true, NULL);
g_object_set(G_OBJECT (source), "latency", 0, NULL);
g_object_set (G_OBJECT (fps_sink), "text-overlay", false, "video-sink", sink, NULL);
g_object_set (G_OBJECT (fps_sink), "sync", false, NULL);
gst_bin_add_many(GST_BIN(g_pipeline[m_uniqueId]), source, depay, parse, decode, filter1, conv, filter2, fps_sink, NULL);
if (gst_element_link_many (depay, parse, decode, filter1, conv, filter2, fps_sink, NULL) == FALSE)
{
std::cout << "Unable to link element" << std::endl;
return;
}
if ( g_signal_connect(source, "pad-added", G_CALLBACK(new_pad_call_back0), NULL) <= 0)
{
std::cout << "Connects a GCallback function to a signal pad-added" << std::endl;
return;
}
if ( g_signal_connect(sink, "new-sample", G_CALLBACK(new_sample0), NULL) <= 0 )
{
std::cout << "Connects a GCallback function to a signal new-sample" << std::endl;
return;
}
break;
printf("Pipeline ready, Now Running\n");