mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
onvif: tests: check for T flag on all packets
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6294>
This commit is contained in:
parent
8830b03ec1
commit
6f21f90747
1 changed files with 18 additions and 20 deletions
|
@ -861,6 +861,14 @@ test_play_response_200_and_check_data (GstRTSPClient * client,
|
||||||
gst_event_unref (outevent);
|
gst_event_unref (outevent);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
fail_unless (gst_rtp_buffer_get_extension_data (&rtp, &bits,
|
||||||
|
(gpointer) & data, &wordlen));
|
||||||
|
|
||||||
|
fail_unless (bits == EXTENSION_ID && wordlen == EXTENSION_SIZE);
|
||||||
|
|
||||||
|
flags = GST_READ_UINT8 (data + 8);
|
||||||
|
|
||||||
if (expected_interval) {
|
if (expected_interval) {
|
||||||
if (check->previous_ts) {
|
if (check->previous_ts) {
|
||||||
fail_unless_equals_int (gst_rtp_buffer_get_timestamp (&rtp) -
|
fail_unless_equals_int (gst_rtp_buffer_get_timestamp (&rtp) -
|
||||||
|
@ -870,33 +878,23 @@ test_play_response_200_and_check_data (GstRTSPClient * client,
|
||||||
check->previous_ts = gst_rtp_buffer_get_timestamp (&rtp);
|
check->previous_ts = gst_rtp_buffer_get_timestamp (&rtp);
|
||||||
check->n_buffers += 1;
|
check->n_buffers += 1;
|
||||||
|
|
||||||
fail_unless (gst_rtp_buffer_get_extension_data (&rtp, &bits,
|
|
||||||
(gpointer) & data, &wordlen));
|
|
||||||
|
|
||||||
fail_unless (bits == EXTENSION_ID && wordlen == EXTENSION_SIZE);
|
|
||||||
|
|
||||||
flags = GST_READ_UINT8 (data + 8);
|
|
||||||
|
|
||||||
if (flags & (1 << 7)) {
|
if (flags & (1 << 7)) {
|
||||||
check->n_clean_points += 1;
|
check->n_clean_points += 1;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* T flag is set, we are done */
|
/* T flag is set, we are done */
|
||||||
if (flags & (1 << 4)) {
|
if (flags & (1 << 4)) {
|
||||||
fail_unless_equals_int (check->expected_n_buffers, check->n_buffers);
|
fail_unless_equals_int (check->expected_n_buffers, check->n_buffers);
|
||||||
fail_unless_equals_int (check->expected_n_i_frames,
|
fail_unless_equals_int (check->expected_n_i_frames, check->n_i_frames);
|
||||||
check->n_i_frames);
|
fail_unless_equals_int (check->expected_n_p_frames, check->n_p_frames);
|
||||||
fail_unless_equals_int (check->expected_n_p_frames,
|
fail_unless_equals_int (check->expected_n_b_frames, check->n_b_frames);
|
||||||
check->n_p_frames);
|
|
||||||
fail_unless_equals_int (check->expected_n_b_frames,
|
|
||||||
check->n_b_frames);
|
|
||||||
fail_unless_equals_int (check->expected_n_clean_points,
|
fail_unless_equals_int (check->expected_n_clean_points,
|
||||||
check->n_clean_points);
|
check->n_clean_points);
|
||||||
|
|
||||||
terminal_frame = TRUE;
|
terminal_frame = TRUE;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
gst_rtp_buffer_unmap (&rtp);
|
gst_rtp_buffer_unmap (&rtp);
|
||||||
gst_buffer_unref (buf);
|
gst_buffer_unref (buf);
|
||||||
|
|
Loading…
Reference in a new issue