},
"properties": {
"aggregate-mode": {
- "blurb": "Bundle suitable SPS/PPS NAL units into STAP-A aggregate packets. ",
+ "blurb": "Bundle suitable SPS/PPS NAL units into STAP-A aggregate packets",
"conditionally-available": false,
"construct": false,
"construct-only": false,
"controllable": false,
- "default": "zero-latency (1)",
+ "default": "none (0)",
"mutable": "null",
"readable": true,
"type": "GstRtpH264AggregateMode",
"construct": false,
"construct-only": false,
"controllable": false,
- "default": "zero-latency (1)",
+ "default": "none (0)",
"mutable": "null",
"readable": true,
"type": "GstRtpH265AggregateMode",
#define DEFAULT_SPROP_PARAMETER_SETS NULL
#define DEFAULT_CONFIG_INTERVAL 0
-#define DEFAULT_AGGREGATE_MODE GST_RTP_H264_AGGREGATE_ZERO_LATENCY
+#define DEFAULT_AGGREGATE_MODE GST_RTP_H264_AGGREGATE_NONE
enum
{
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)
);
+ /**
+ * GstRtpH264Pay:aggregate-mode
+ *
+ * Bundle suitable SPS/PPS NAL units into STAP-A aggregate packets.
+ *
+ * This can potentially reduce RTP packetization overhead but not all
+ * RTP implementations handle it correctly.
+ *
+ * For best compatibility, it is recommended to set this to "none" (the
+ * default) for RTSP and for WebRTC to "zero-latency".
+ *
+ * Since: 1.18
+ */
g_object_class_install_property (G_OBJECT_CLASS (klass),
PROP_AGGREGATE_MODE,
g_param_spec_enum ("aggregate-mode",
"Attempt to use aggregate packets",
"Bundle suitable SPS/PPS NAL units into STAP-A "
- "aggregate packets. ",
+ "aggregate packets",
GST_TYPE_RTP_H264_AGGREGATE_MODE,
DEFAULT_AGGREGATE_MODE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)
);
);
#define DEFAULT_CONFIG_INTERVAL 0
-#define DEFAULT_AGGREGATE_MODE GST_RTP_H265_AGGREGATE_ZERO_LATENCY
+#define DEFAULT_AGGREGATE_MODE GST_RTP_H265_AGGREGATE_NONE
enum
{
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)
);
+ /**
+ * GstRtpH265Pay:aggregate-mode
+ *
+ * Bundle suitable SPS/PPS NAL units into STAP-A aggregate packets.
+ *
+ * This can potentially reduce RTP packetization overhead but not all
+ * RTP implementations handle it correctly.
+ *
+ * For best compatibility, it is recommended to set this to "none" (the
+ * default) for RTSP and for WebRTC to "zero-latency".
+ *
+ * Since: 1.18
+ */
g_object_class_install_property (G_OBJECT_CLASS (klass),
PROP_AGGREGATE_MODE,
g_param_spec_enum ("aggregate-mode",
p->pipeline = gst_pipeline_new (pipeline_name);
g_free (pipeline_name);
p->appsrc = gst_element_factory_make ("appsrc", NULL);
- p->rtppay = gst_element_factory_make (pay, NULL);
- p->rtpdepay = gst_element_factory_make (depay, NULL);
+ p->rtppay =
+ gst_parse_bin_from_description_full (pay, TRUE, NULL,
+ GST_PARSE_FLAG_NO_SINGLE_ELEMENT_BINS, NULL);
+ p->rtpdepay =
+ gst_parse_bin_from_description_full (depay, TRUE, NULL,
+ GST_PARSE_FLAG_NO_SINGLE_ELEMENT_BINS, NULL);
p->fakesink = gst_element_factory_make ("fakesink", NULL);
/* One or more elements are not created successfully or failed to create p? */
rtp_pipeline_test (rtp_h264_list_lt_mtu_frame_data,
rtp_h264_list_lt_mtu_frame_data_size, rtp_h264_list_lt_mtu_frame_count,
"video/x-h264,stream-format=(string)byte-stream,alignment=(string)nal",
- "rtph264pay", "rtph264depay",
+ "rtph264pay aggregate-mode=zero-latency", "rtph264depay",
rtp_h264_list_lt_mtu_bytes_sent, rtp_h264_list_lt_mtu_mtu_size, TRUE);
}
rtp_h264_list_lt_mtu_frame_data_size, rtp_h264_list_lt_mtu_frame_count,
"video/x-h264,stream-format=(string)avc,alignment=(string)au,"
"codec_data=(buffer)01640014ffe1001867640014acd94141fb0110000003001773594000f142996001000568ebecb22c",
- "rtph264pay", "rtph264depay",
+ "rtph264pay aggregate-mode=zero-latency", "rtph264depay",
rtp_h264_list_lt_mtu_bytes_sent_avc, rtp_h264_list_lt_mtu_mtu_size, TRUE);
}
"01840010c01ffff01c000000300800000030000030099ac0900a10001003042010101c00"
"0000300800000030000030099a00a080f1fe36bbb5377725d602dc040404100000300010"
"00003000a0800a2000100074401c172b02240",
- "rtph265pay", "rtph265depay", rtp_h265_list_lt_mtu_bytes_sent_hvc1,
- rtp_h265_list_lt_mtu_mtu_size, TRUE);
+ "rtph265pay aggregate-mode=zero-latency", "rtph265depay",
+ rtp_h265_list_lt_mtu_bytes_sent_hvc1, rtp_h265_list_lt_mtu_mtu_size,
+ TRUE);
}
GST_END_TEST;
GST_START_TEST (test_rtph264pay_two_slices_timestamp)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph264pay_marker_for_flag)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph264pay_marker_for_fragmented_au)
{
GstHarness *h =
- gst_harness_new_parse ("rtph264pay timestamp-offset=123 mtu=40");
+ gst_harness_new_parse ("rtph264pay timestamp-offset=123 mtu=40"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *slice1, *slice2, *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
gst_harness_set_src_caps_str (h,
"video/x-h264,alignment=nal,stream-format=byte-stream");
- /* No aggregation latency mode */
-
+ /* No aggregation mode */
g_object_set (e, "aggregate-mode", 0, NULL);
buffer = wrap_static_buffer_with_pts (h264_idr_slice_1,
GST_START_TEST (test_rtph264pay_aggregate_with_aud)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph264pay_aggregate_with_discont)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph264pay_aggregate_until_vcl)
{
GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
- " name=p");
+ " name=p aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph264pay_avc)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
static void
test_rtph264pay_avc_two_slices (gsize memory1_len, guint num_slices)
{
- GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph264pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *slice1;
GstBuffer *slice2;
GST_START_TEST (test_rtph265pay_two_slices_timestamp)
{
- GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_marker_for_flag)
{
- GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_marker_for_fragmented_au)
{
GstHarness *h =
- gst_harness_new_parse ("rtph265pay timestamp-offset=123 mtu=40");
+ gst_harness_new_parse ("rtph265pay timestamp-offset=123 mtu=40"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *slice1, *slice2, *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_aggregate_with_aud)
{
- GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_aggregate_with_discont)
{
- GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123");
+ GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
+ " aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_aggregate_until_vcl)
{
GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
- " name=p");
+ " name=p aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;
GST_START_TEST (test_rtph265pay_aggregate_verify_nalu_hdr)
{
GstHarness *h = gst_harness_new_parse ("rtph265pay timestamp-offset=123"
- " name=p");
+ " name=p aggregate-mode=zero-latency");
GstFlowReturn ret;
GstBuffer *buffer;
GstRTPBuffer rtp = GST_RTP_BUFFER_INIT;