mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-07 16:49:52 +00:00
dvb: Adapt for latest mpegts lib changes
This commit is contained in:
parent
d6b55b8a66
commit
c3e4fe4edc
2 changed files with 11 additions and 13 deletions
|
@ -171,34 +171,32 @@ cam_read_length_field (guint8 * buff, guint * length)
|
|||
*/
|
||||
|
||||
static guint
|
||||
get_ca_descriptors_length (GArray * descriptors)
|
||||
get_ca_descriptors_length (GPtrArray * descriptors)
|
||||
{
|
||||
guint i;
|
||||
guint nb_desc = descriptors->len;
|
||||
guint len = 0;
|
||||
|
||||
for (i = 0; i < nb_desc; i++) {
|
||||
GstMpegTsDescriptor *desc =
|
||||
&g_array_index (descriptors, GstMpegTsDescriptor, i);
|
||||
if (desc->descriptor_tag == 0x09)
|
||||
len += desc->descriptor_length;
|
||||
GstMpegTsDescriptor *desc = g_ptr_array_index (descriptors, i);
|
||||
if (desc->tag == 0x09)
|
||||
len += desc->length;
|
||||
}
|
||||
|
||||
return len;
|
||||
}
|
||||
|
||||
static guint8 *
|
||||
write_ca_descriptors (guint8 * body, GArray * descriptors)
|
||||
write_ca_descriptors (guint8 * body, GPtrArray * descriptors)
|
||||
{
|
||||
guint i, nb_desc;
|
||||
|
||||
nb_desc = descriptors->len;
|
||||
for (i = 0; i < nb_desc; i++) {
|
||||
GstMpegTsDescriptor *desc =
|
||||
&g_array_index (descriptors, GstMpegTsDescriptor, i);
|
||||
if (desc->descriptor_tag == 0x09) {
|
||||
memcpy (body, desc->descriptor_data, desc->descriptor_length);
|
||||
body += desc->descriptor_length;
|
||||
GstMpegTsDescriptor *desc = g_ptr_array_index (descriptors, i);
|
||||
if (desc->tag == 0x09) {
|
||||
memcpy (body, desc->data, desc->length);
|
||||
body += desc->length;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -807,7 +807,7 @@ dvb_base_bin_handle_message (GstBin * bin, GstMessage * message)
|
|||
static void
|
||||
dvb_base_bin_pat_info_cb (DvbBaseBin * dvbbasebin, GstMpegTsSection * section)
|
||||
{
|
||||
GArray *pat;
|
||||
GPtrArray *pat;
|
||||
DvbBaseBinProgram *program;
|
||||
DvbBaseBinStream *stream;
|
||||
guint old_pmt_pid;
|
||||
|
@ -820,7 +820,7 @@ dvb_base_bin_pat_info_cb (DvbBaseBin * dvbbasebin, GstMpegTsSection * section)
|
|||
}
|
||||
|
||||
for (i = 0; i < pat->len; i++) {
|
||||
GstMpegTsPatProgram *patp = &g_array_index (pat, GstMpegTsPatProgram, i);
|
||||
GstMpegTsPatProgram *patp = g_ptr_array_index (pat, i);
|
||||
|
||||
program = dvb_base_bin_get_program (dvbbasebin, patp->program_number);
|
||||
if (program == NULL)
|
||||
|
|
Loading…
Reference in a new issue