TDA4VE-Q1: J721S2 SDK 9.02

Part Number: TDA4VE-Q1

Tool/software:

We are trying to create two pipelines that each utilize an instance of the v4l2h264enc element. For our purposes, we would like the output to be composed of entirely IDR frames. However, no matter what/how the extra-controls property is set to, we are only getting 1 IDR frame at the very beginning and the rest are P frames. For the extra-controls, we are setting video_gop_size = 1 and h264_i_frame_period = 1. The property is set in the pipeline that is created and run first. We also tried setting the property for both pipelines, with no change. For the method of setting the pipeline and property, we have tried 2 ways.

The first way we used gst_element_factory_make to construct the pipeline and linked each element. To set the extra-control property for the encoder here, we created a GstStructure populated with the proper key/value pairs. The GstStructure was then set using g_object_set. This did not seem to affect the output stream at all.

The second way we used the example from the multi_cam_codec demo application. The entire pipeline was written as a string and and launched using gst_parse_launch. Again, the output stream did not change no matter what we changed the properties to.

In the application, we are saving the stream to file by pulling a sample when the "new-sample" signal is sent. We then retrieve the buffer using gst_sample_get_buffer. The buffer is then mapped using gst_buffer_map. The mapped buffer data member is then written to a file using the mapped buffer's size member. We found using the V4L2 API to perform the encoding does result in every frame being an IDR frame, but Gstreamer is not able to. We would like to use Gstreamer for the simplicity, and would appreciate help with this issue. We would like to continue using SDK 9.2 and avoid upgrading to SDK 10.0.