Browse Source

Descriptor 0x62: Support for different deliveries

root 6 years ago
parent
commit
d0e2dfe394
2 changed files with 12 additions and 0 deletions
  1. 9
    0
      nit_desc.c
  2. 3
    0
      tsfuncs.h

+ 9
- 0
nit_desc.c View File

@@ -143,9 +143,18 @@ static int ts_nit_add_frequency_list_descriptor(struct ts_nit *nit, uint16_t ts_
143 143
 }
144 144
 
145 145
 
146
+int ts_nit_add_frequency_list_descriptor_neutral(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs) {
147
+	return ts_nit_add_frequency_list_descriptor(nit, ts_id, org_net_id, 0, freqs, num_freqs);
148
+}
149
+int ts_nit_add_frequency_list_descriptor_satellite(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs) {
150
+	return ts_nit_add_frequency_list_descriptor(nit, ts_id, org_net_id, 1, freqs, num_freqs);
151
+}
146 152
 int ts_nit_add_frequency_list_descriptor_cable(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs) {
147 153
 	return ts_nit_add_frequency_list_descriptor(nit, ts_id, org_net_id, 2, freqs, num_freqs);
148 154
 }
155
+int ts_nit_add_frequency_list_descriptor_terrestrial(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs) {
156
+	return ts_nit_add_frequency_list_descriptor(nit, ts_id, org_net_id, 3, freqs, num_freqs);
157
+}
149 158
 
150 159
 int ts_nit_add_cable_delivery_descriptor(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t freq, uint8_t modulation, uint32_t symbol_rate) {
151 160
 	int desc_size = 13;

+ 3
- 0
tsfuncs.h View File

@@ -202,7 +202,10 @@ void			ts_nit_dump			(struct ts_nit *nit);
202 202
 void			ts_nit_generate		(struct ts_nit *nit, uint8_t **ts_packets, int *num_packets);
203 203
 
204 204
 int				ts_nit_add_network_name_descriptor			(struct ts_nit *nit, char *network_name);
205
+int				ts_nit_add_frequency_list_descriptor_neutral	(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs);
206
+int				ts_nit_add_frequency_list_descriptor_satellite	(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs);
205 207
 int				ts_nit_add_frequency_list_descriptor_cable	(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs);
208
+int				ts_nit_add_frequency_list_descriptor_terrestrial(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *freqs, uint8_t num_freqs);
206 209
 int				ts_nit_add_cable_delivery_descriptor		(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t freq, uint8_t modulation, uint32_t symbol_rate);
207 210
 int				ts_nit_add_service_list_descriptor			(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id, uint32_t *services, uint8_t num_services);
208 211
 int				ts_nit_add_nordig_specifier_descriptor		(struct ts_nit *nit, uint16_t ts_id, uint16_t org_net_id);

Loading…
Cancel
Save