Need help for gstreamer c API

Hi Folks.

I am trying to stream raw data to fakesink using gstreamer API.Facing below error while running on NVIDIA jetson nano device.

**video_main_pipeline’ state changed from NULL to READY.
‘video_main_pipeline’ state changed from READY to PAUSED.
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected…
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3840 x 2160 FR = 16.670000 fps Duration = 59988004 ; Analog Gain range min 0.000000, max 72.000000; Exposure Range min 111000, max 44663000;

Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadExecute:243 Stream failed to connect.
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadFunction:177 (propagating)
(Argus) Error InvalidState: (propagating from src/eglstream/FrameConsumerImpl.cpp, function streamEventThread(), line 135)
(Argus) Error InvalidState: (propagating from src/eglstream/FrameConsumerImpl.cpp, function streamEventThreadStatic(), line 177)
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:654 Frame Rate specified is greater than supported
‘video_main_pipeline’ state changed from PAUSED to PLAYING.
**

Full code below, any help greatly appreciated. Is there anything i m missing

Data.source = gst_element_factory_make("nvarguscamerasrc", "video_source");
Data.videorate_filter = gst_element_factory_make("capsfilter", "framerate-filter");
Data.fakesink = gst_element_factory_make("fakesink", "shm-sink");

if(!Data.source || !Data.videorate_filter || !Data.shmsink) {
	g_critical("gst_element_factory_make error");
	return -1;
}

g_object_set(Data.fakesink, NULL, NULL, NULL);
gst_bin_add_many(GST_BIN(Data.pipeline), Data.source, Data.videorate_filter, Data.fakesink, NULL);

if (!gst_element_link_many(Data.source, Data.videorate_filter, Data.fakesink, NULL)) {
	g_critical("Unable to link source with tee\n");
	return -1;
}

Data.caps_g2d_scale = gst_caps_from_string("video/x-raw, width=1920, height=1080");
g_object_set(Data.videorate_filter, "caps", Data.caps_g2d_scale, NULL);

gst_element_set_state(GST_ELEMENT(Data.pipeline), GST_STATE_PLAYING);

g_main_loop_run(Data.loop);
g_printf("\npipeline end");
return 0;}

Hi,
Please check if you can run this sample:

If it works, you can consider to call gst_parse_launch() to launch a pipeline.

Thanks , working.