/third_party/gstreamer/gstplugins_bad/gst/mpegpsmux/ |
D | mpegpsmux_h264.c | 159 guint32 nal_size = 0; in mpegpsmux_prepare_h264() local 163 nal_size = GST_READ_UINT8 (map.data + in_offset); in mpegpsmux_prepare_h264() 166 nal_size = GST_READ_UINT16_BE (map.data + in_offset); in mpegpsmux_prepare_h264() 169 nal_size = GST_READ_UINT32_BE (map.data + in_offset); in mpegpsmux_prepare_h264() 181 MIN (nal_size, map.size - in_offset)); in mpegpsmux_prepare_h264() 182 in_offset += nal_size; in mpegpsmux_prepare_h264()
|
/third_party/ffmpeg/libavformat/ |
D | rtpdec_h264.c | 222 uint16_t nal_size = AV_RB16(src); in ff_h264_handle_aggregated_packet() local 228 if (nal_size <= src_len) { in ff_h264_handle_aggregated_packet() 231 total_length += sizeof(start_sequence) + nal_size; in ff_h264_handle_aggregated_packet() 236 memcpy(dst, src, nal_size); in ff_h264_handle_aggregated_packet() 239 dst += nal_size; in ff_h264_handle_aggregated_packet() 243 "nal size exceeds length: %d %d\n", nal_size, src_len); in ff_h264_handle_aggregated_packet() 248 src += nal_size + skip_between; in ff_h264_handle_aggregated_packet() 249 src_len -= nal_size + skip_between; in ff_h264_handle_aggregated_packet()
|
D | hevc.c | 660 static int hvcc_array_add_nal_unit(uint8_t *nal_buf, uint32_t nal_size, in hvcc_array_add_nal_unit() argument 697 array->nalUnitLength[numNalus] = nal_size; in hvcc_array_add_nal_unit() 713 static int hvcc_add_nal_unit(uint8_t *nal_buf, uint32_t nal_size, in hvcc_add_nal_unit() argument 723 rbsp_buf = ff_nal_unit_extract_rbsp(nal_buf, nal_size, &rbsp_size, 2); in hvcc_add_nal_unit() 746 ret = hvcc_array_add_nal_unit(nal_buf, nal_size, nal_type, in hvcc_add_nal_unit()
|
/third_party/ffmpeg/libavcodec/ |
D | h264_mp4toannexb_bsf.c | 204 uint32_t nal_size = 0; in h264_mp4toannexb_filter() local 208 nal_size = (nal_size << 8) | buf[i]; in h264_mp4toannexb_filter() 214 if ((int64_t)nal_size > buf_end - buf) { in h264_mp4toannexb_filter() 219 if (!nal_size) in h264_mp4toannexb_filter() 260 count_or_copy(&out, &out_size, buf, nal_size, in h264_mp4toannexb_filter() 268 buf += nal_size; in h264_mp4toannexb_filter()
|
D | hevc_ps.c | 463 ptrdiff_t nal_size; in ff_hevc_decode_nal_vps() local 473 nal_size = gb->buffer_end - gb->buffer; in ff_hevc_decode_nal_vps() 474 if (nal_size > sizeof(vps->data)) { in ff_hevc_decode_nal_vps() 477 nal_size, sizeof(vps->data)); in ff_hevc_decode_nal_vps() 480 vps->data_size = nal_size; in ff_hevc_decode_nal_vps() 1257 ptrdiff_t nal_size; in ff_hevc_decode_nal_sps() local 1265 nal_size = gb->buffer_end - gb->buffer; in ff_hevc_decode_nal_sps() 1266 if (nal_size > sizeof(sps->data)) { in ff_hevc_decode_nal_sps() 1269 nal_size, sizeof(sps->data)); in ff_hevc_decode_nal_sps() 1272 sps->data_size = nal_size; in ff_hevc_decode_nal_sps() [all …]
|
D | videotoolboxenc.c | 1563 size_t nal_size, in find_sei_end() argument 1572 if (!nal_size) in find_sei_end() 1580 nal_size--; in find_sei_end() 1582 if (nal_data[nal_size - 1] == 0x80) in find_sei_end() 1583 nal_size--; in find_sei_end() 1585 while (nal_size > 0 && *nal_data > 0) { in find_sei_end() 1589 nal_size--; in find_sei_end() 1590 } while (nal_size > 0 && *nal_data == 0xFF); in find_sei_end() 1592 if (!nal_size) { in find_sei_end() 1600 nal_size--; in find_sei_end() [all …]
|
/third_party/gstreamer/gstplugins_good/gst/rtp/ |
D | gstrtph265pay.c | 615 gint i, j, nal_size; in gst_rtp_h265_pay_setcaps() local 702 nal_size = (data[0] << 8) | data[1]; in gst_rtp_h265_pay_setcaps() 706 GST_LOG_OBJECT (rtph265pay, "VPS %d size %d", i, nal_size); in gst_rtp_h265_pay_setcaps() 708 if (size < nal_size) in gst_rtp_h265_pay_setcaps() 712 vps_buf = gst_buffer_new_and_alloc (nal_size); in gst_rtp_h265_pay_setcaps() 713 gst_buffer_fill (vps_buf, 0, data, nal_size); in gst_rtp_h265_pay_setcaps() 716 data += nal_size; in gst_rtp_h265_pay_setcaps() 717 size -= nal_size; in gst_rtp_h265_pay_setcaps() 739 nal_size = (data[0] << 8) | data[1]; in gst_rtp_h265_pay_setcaps() 743 GST_LOG_OBJECT (rtph265pay, "SPS %d size %d", i, nal_size); in gst_rtp_h265_pay_setcaps() [all …]
|
D | gstrtph265depay.c | 537 gsize nal_size = in gst_rtp_h265_set_src_caps() local 539 GST_WRITE_UINT16_BE (data, nal_size); in gst_rtp_h265_set_src_caps() 541 data + 2, nal_size); in gst_rtp_h265_set_src_caps() 542 data += 2 + nal_size; in gst_rtp_h265_set_src_caps() 544 (guint) nal_size); in gst_rtp_h265_set_src_caps() 558 gsize nal_size = in gst_rtp_h265_set_src_caps() local 560 GST_WRITE_UINT16_BE (data, nal_size); in gst_rtp_h265_set_src_caps() 562 data + 2, nal_size); in gst_rtp_h265_set_src_caps() 563 data += 2 + nal_size; in gst_rtp_h265_set_src_caps() 565 (guint) nal_size); in gst_rtp_h265_set_src_caps() [all …]
|
D | gstrtph264pay.c | 585 gint i, nal_size; in gst_rtp_h264_pay_setcaps() local 627 nal_size = (data[0] << 8) | data[1]; in gst_rtp_h264_pay_setcaps() 631 GST_LOG_OBJECT (rtph264pay, "SPS %d size %d", i, nal_size); in gst_rtp_h264_pay_setcaps() 633 if (size < nal_size) in gst_rtp_h264_pay_setcaps() 637 sps_buf = gst_buffer_new_and_alloc (nal_size); in gst_rtp_h264_pay_setcaps() 638 gst_buffer_fill (sps_buf, 0, data, nal_size); in gst_rtp_h264_pay_setcaps() 641 data += nal_size; in gst_rtp_h264_pay_setcaps() 642 size -= nal_size; in gst_rtp_h264_pay_setcaps() 659 nal_size = (data[0] << 8) | data[1]; in gst_rtp_h264_pay_setcaps() 663 GST_LOG_OBJECT (rtph264pay, "PPS %d size %d", i, nal_size); in gst_rtp_h264_pay_setcaps() [all …]
|
/third_party/gstreamer/gstplugins_bad/tests/check/libs/ |
D | h264parser.c | 238 const gsize nal_size = sizeof (slice_dpa) - 3; in GST_START_TEST() local 239 const gsize buf_size = 4 + nal_size; in GST_START_TEST() 242 memcpy (buf + 4, slice_dpa + 3, nal_size); in GST_START_TEST() 244 GST_WRITE_UINT16_BE (buf + 2, nal_size); in GST_START_TEST() 250 assert_equals_int (nalu.size, nal_size); in GST_START_TEST() 252 GST_WRITE_UINT32_BE (buf, nal_size); in GST_START_TEST() 258 assert_equals_int (nalu.size, nal_size); in GST_START_TEST() 627 gsize nal_size; in GST_START_TEST() local 656 nal_size = GST_READ_UINT32_BE (info.data); in GST_START_TEST() 657 assert_equals_int (nal_size, info.size - 4); in GST_START_TEST()
|
D | h265parser.c | 264 const gsize nal_size = sizeof (slice_eos_slice_eob) - 4; in GST_START_TEST() local 265 const gsize buf_size = 4 + nal_size; in GST_START_TEST() 268 memcpy (buf + 4, slice_eos_slice_eob + 4, nal_size); in GST_START_TEST() 270 GST_WRITE_UINT16_BE (buf + 2, nal_size); in GST_START_TEST() 276 assert_equals_int (nalu.size, nal_size); in GST_START_TEST() 278 GST_WRITE_UINT32_BE (buf, nal_size); in GST_START_TEST() 284 assert_equals_int (nalu.size, nal_size); in GST_START_TEST() 1095 gsize nal_size; in GST_START_TEST() local 1126 nal_size = GST_READ_UINT32_BE (info.data); in GST_START_TEST() 1127 assert_equals_int (nal_size, info.size - 4); in GST_START_TEST()
|
/third_party/gstreamer/gstplugins_bad/ext/libde265/ |
D | libde265-dec.c | 603 int nal_size; in gst_libde265_dec_set_format() local 610 nal_size = data[pos] << 8 | data[pos + 1]; in gst_libde265_dec_set_format() 611 if (pos + 2 + nal_size > size) { in gst_libde265_dec_set_format() 614 pos + 2 + nal_size, size), (NULL)); in gst_libde265_dec_set_format() 618 de265_push_NAL (dec->ctx, data + pos + 2, nal_size, 0, NULL); in gst_libde265_dec_set_format() 625 pos += 2 + nal_size; in gst_libde265_dec_set_format() 792 int nal_size = 0; in gst_libde265_dec_handle_frame() local 795 nal_size = (nal_size << 8) | start_data[i]; in gst_libde265_dec_handle_frame() 797 if (start_data + dec->length_size + nal_size > end_data) { in gst_libde265_dec_handle_frame() 803 de265_push_NAL (dec->ctx, start_data + dec->length_size, nal_size, in gst_libde265_dec_handle_frame() [all …]
|
/third_party/gstreamer/gstplugins_bad/ext/avtp/ |
D | gstavtpcvfpay.c | 343 gsize available, nal_size, fragment_size, remaining; in gst_avtpcvpay_fragment_nal() local 346 nal_size = gst_buffer_get_size (nal); in gst_avtpcvpay_fragment_nal() 349 if (*offset == 0 && (nal_size + AVTP_CVF_H264_HEADER_SIZE) <= avtpcvfpay->mtu) { in gst_avtpcvpay_fragment_nal() 351 *offset = nal_size; in gst_avtpcvpay_fragment_nal() 353 "Generated fragment with size %" G_GSIZE_FORMAT, nal_size); in gst_avtpcvpay_fragment_nal() 358 if (*offset == nal_size) { in gst_avtpcvpay_fragment_nal() 365 remaining = nal_size - *offset + AVTP_CVF_H264_HEADER_SIZE + FU_A_HEADER_SIZE; in gst_avtpcvpay_fragment_nal() 400 available < (nal_size - *offset) ? available : (nal_size - *offset); in gst_avtpcvpay_fragment_nal()
|
/third_party/gstreamer/gstplugins_bad/tests/check/elements/ |
D | avtpcvfdepay.c | 62 nal_size (GstBuffer * buffer) in nal_size() function 64 guint8 nal_size[4]; in nal_size() local 66 gst_buffer_extract (buffer, 0, nal_size, 4); in nal_size() 67 return GST_READ_UINT32_BE (nal_size); in nal_size() 82 gsize nal_size; in fetch_nal() local 90 nal_size = GST_READ_UINT32_BE (buf); in fetch_nal() 94 nal_size + 4); in fetch_nal() 95 *offset += nal_size + 4; in fetch_nal() 674 fail_unless_equals_uint64 (nal_size (nal), 17); in GST_START_TEST() 759 fail_unless_equals_uint64 (nal_size (nal), 4); in GST_START_TEST() [all …]
|
/third_party/gstreamer/gstplugins_bad/gst/videoparsers/ |
D | gsth265parse.c | 1538 gsize nal_size = gst_buffer_get_size (nal); in gst_h265_parse_make_codec_data() local 1539 GST_WRITE_UINT16_BE (data, nal_size); in gst_h265_parse_make_codec_data() 1540 gst_buffer_extract (nal, 0, data + 2, nal_size); in gst_h265_parse_make_codec_data() 1541 data += 2 + nal_size; in gst_h265_parse_make_codec_data() 1557 gsize nal_size = gst_buffer_get_size (nal); in gst_h265_parse_make_codec_data() local 1558 GST_WRITE_UINT16_BE (data, nal_size); in gst_h265_parse_make_codec_data() 1559 gst_buffer_extract (nal, 0, data + 2, nal_size); in gst_h265_parse_make_codec_data() 1560 data += 2 + nal_size; in gst_h265_parse_make_codec_data() 1576 gsize nal_size = gst_buffer_get_size (nal); in gst_h265_parse_make_codec_data() local 1577 GST_WRITE_UINT16_BE (data, nal_size); in gst_h265_parse_make_codec_data() [all …]
|
D | gsth264parse.c | 1679 gsize nal_size = gst_buffer_get_size (nal); in gst_h264_parse_make_codec_data() local 1680 GST_WRITE_UINT16_BE (data, nal_size); in gst_h264_parse_make_codec_data() 1681 gst_buffer_extract (nal, 0, data + 2, nal_size); in gst_h264_parse_make_codec_data() 1682 data += 2 + nal_size; in gst_h264_parse_make_codec_data() 1692 gsize nal_size = gst_buffer_get_size (nal); in gst_h264_parse_make_codec_data() local 1693 GST_WRITE_UINT16_BE (data, nal_size); in gst_h264_parse_make_codec_data() 1694 gst_buffer_extract (nal, 0, data + 2, nal_size); in gst_h264_parse_make_codec_data() 1695 data += 2 + nal_size; in gst_h264_parse_make_codec_data() 2886 gsize nal_size = gst_buffer_get_size (codec_nal); in gst_h264_parse_handle_sps_pps_nals() local 2891 ok &= gst_byte_writer_put_uint32_be (&bw, (nal_size << (nls * 8))); in gst_h264_parse_handle_sps_pps_nals() [all …]
|
/third_party/gstreamer/gstplugins_bad/sys/v4l2codecs/ |
D | gstv4l2codech264dec.c | 1248 gsize nal_size; in gst_v4l2_codec_h264_dec_decode_slice() local 1271 nal_size = sc_off + slice->nalu.size; in gst_v4l2_codec_h264_dec_decode_slice() 1273 if (self->bitstream_map.size + nal_size > self->bitstream_map.maxsize) { in gst_v4l2_codec_h264_dec_decode_slice() 1287 self->bitstream_map.size += nal_size; in gst_v4l2_codec_h264_dec_decode_slice()
|