1 /* packet-mpeg-descriptor.c
2 * Routines for MPEG2 (ISO/ISO 13818-1 and co) descriptors
3 * Copyright 2012, Guy Martin <gmsoft@tuxicoman.be>
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License along
20 * with this program; if not, write to the Free Software Foundation, Inc.,
21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
26 #include <epan/packet.h>
27 #include <epan/dvb_chartbl.h>
28 #include "packet-mpeg-sect.h"
29 #include "packet-mpeg-descriptor.h"
31 void proto_register_mpeg_descriptor(void);
33 static int proto_mpeg_descriptor = -1;
34 static int hf_mpeg_descriptor_tag = -1;
35 static int hf_mpeg_descriptor_length = -1;
36 static int hf_mpeg_descriptor_data = -1;
38 static gint ett_mpeg_descriptor = -1;
40 static const value_string mpeg_descriptor_tag_vals[] = {
41 /* From ISO/IEC 13818-1 */
44 { 0x02, "Video Stream Descriptor" },
45 { 0x03, "Audio Stream Descriptor" },
46 { 0x04, "Hierarchy Descriptor" },
47 { 0x05, "Registration Descriptor" },
48 { 0x06, "Data Stream Alignment Descriptor" },
49 { 0x07, "Target Background Grid Descriptor" },
50 { 0x08, "Video Window Descriptor" },
51 { 0x09, "CA Descriptor" },
52 { 0x0A, "ISO 639 Language Descriptor" },
53 { 0x0B, "System Clock Descriptor" },
54 { 0x0C, "Multiplex Buffer Utilization Descriptor" },
55 { 0x0D, "Copyright Descriptor" },
56 { 0x0E, "Maximum Bitrate Descriptor" },
57 { 0x0F, "Private Data Indicator Descriptor" },
58 { 0x10, "Smoothing Buffer Descriptor" },
59 { 0x11, "STD Descriptor" },
60 { 0x12, "IBP Descriptor" },
62 /* From ETSI TR 101 202 */
63 { 0x13, "Carousel Identifier Descriptor" },
64 { 0x14, "Association Tag Descriptor" },
65 { 0x15, "Deferred Association Tag Descriptor" },
67 /* From ISO/IEC 13818-1 */
68 { 0x1B, "MPEG 4 Video Descriptor" },
69 { 0x1C, "MPEG 4 Audio Descriptor" },
70 { 0x1D, "IOD Descriptor" },
71 { 0x1E, "SL Descriptor" },
72 { 0x1F, "FMC Descriptor" },
73 { 0x20, "External ES ID Descriptor" },
74 { 0x21, "MuxCode Descriptor" },
75 { 0x22, "FmxBufferSize Descriptor" },
76 { 0x23, "MultiplexBuffer Descriptor" },
77 { 0x24, "Content Labeling Descriptor" },
78 { 0x25, "Metadata Pointer Descriptor" },
79 { 0x26, "Metadata Descriptor" },
80 { 0x27, "Metadata STD Descriptor" },
81 { 0x28, "AVC Video Descriptor" },
82 { 0x29, "IPMP Descriptor" },
83 { 0x2A, "AVC Timing and HRD Descriptor" },
84 { 0x2B, "MPEG2 AAC Descriptor" },
85 { 0x2C, "FlexMuxTiming Descriptor" },
87 /* From ETSI EN 300 468 */
88 { 0x40, "Network Name Descriptor" },
89 { 0x41, "Service List Descriptor" },
90 { 0x42, "Stuffing Descriptor" },
91 { 0x43, "Satellite Delivery System Descriptor" },
92 { 0x44, "Cable Delivery System Descriptor" },
93 { 0x45, "VBI Data Descriptor" },
94 { 0x46, "VBI Teletext Descriptor" },
95 { 0x47, "Bouquet Name Descriptor" },
96 { 0x48, "Service Descriptor" },
97 { 0x49, "Country Availability Descriptor" },
98 { 0x4A, "Linkage Descriptor" },
99 { 0x4B, "NVOD Reference Descriptor" },
100 { 0x4C, "Time Shifted Service Descriptor" },
101 { 0x4D, "Short Event Descriptor" },
102 { 0x4E, "Extended Event Descriptor" },
103 { 0x4F, "Time Shifted Event Descriptor" },
104 { 0x50, "Component Descriptor" },
105 { 0x51, "Mosaic Descriptor" },
106 { 0x52, "Stream Identifier Descriptor" },
107 { 0x53, "CA Identifier Descriptor" },
108 { 0x54, "Content Descriptor" },
109 { 0x55, "Parent Rating Descriptor" },
110 { 0x56, "Teletext Descriptor" },
111 { 0x57, "Telephone Descriptor" },
112 { 0x58, "Local Time Offset Descriptor" },
113 { 0x59, "Subtitling Descriptor" },
114 { 0x5A, "Terrestrial Delivery System Descriptor" },
115 { 0x5B, "Multilingual Network Name Descriptor" },
116 { 0x5C, "Multilingual Bouquet Name Descriptor" },
117 { 0x5D, "Multilingual Service Name Descriptor" },
118 { 0x5E, "Multilingual Component Descriptor" },
119 { 0x5F, "Private Data Specifier Descriptor" },
120 { 0x60, "Service Move Descriptor" },
121 { 0x61, "Short Smoothing Buffer Descriptor" },
122 { 0x62, "Frequency List Descriptor" },
123 { 0x63, "Partial Transport Stream Descriptor" },
124 { 0x64, "Data Broadcast Descriptor" },
125 { 0x65, "Scrambling Descriptor" },
126 { 0x66, "Data Broadcast ID Descriptor" },
127 { 0x67, "Transport Stream Descriptor" },
128 { 0x68, "DSNG Descriptor" },
129 { 0x69, "PDC Descriptor" },
130 { 0x6A, "AC-3 Descriptor" },
131 { 0x6B, "Ancillary Data Descriptor" },
132 { 0x6C, "Cell List Descriptor" },
133 { 0x6D, "Cell Frequency Link Descriptor" },
134 { 0x6E, "Announcement Support Descriptor" },
135 { 0x6F, "Application Signalling Descriptor" },
136 { 0x70, "Adaptation Field Data Descriptor" },
137 { 0x71, "Service Identifier Descriptor" },
138 { 0x72, "Service Availability Descriptor" },
139 { 0x73, "Default Authority Descriptor" },
140 { 0x74, "Related Content Descriptor" },
141 { 0x75, "TVA ID Descriptor" },
142 { 0x76, "Content Identifier Descriptor" },
143 { 0x77, "Time Slice FEC Identifier Descriptor" },
144 { 0x78, "ECM Repetition Rate Descriptor" },
145 { 0x79, "S2 Satellite Delivery System Descriptor" },
146 { 0x7A, "Enhanced AC-3 Descriptor" },
147 { 0x7B, "DTS Descriptor" },
148 { 0x7C, "AAC Descriptor" },
149 { 0x7D, "XAIT Content Location Descriptor" },
150 { 0x7E, "FTA Content Management Descriptor" },
151 { 0x7F, "Extension Descriptor" },
154 { 0x81, "ATSC A/52 AC-3 Audio Descriptor" },
156 /* From ETSI EN 301 790 */
157 { 0xA0, "Network Layer Info Descriptor" },
158 { 0xA1, "Correction Message Descriptor" },
159 { 0xA2, "Logon Initialize Descriptor" },
160 { 0xA3, "ACQ Assign Descriptor" },
161 { 0xA4, "SYNC Assign Descriptor" },
162 { 0xA5, "Encrypted Logon ID Descriptor" },
163 { 0xA6, "Echo Value Descriptor" },
164 { 0xA7, "RCS Content Descriptor" },
165 { 0xA8, "Satellite Forward Link Descriptor" },
166 { 0xA9, "Satellite Return Link Descriptor" },
167 { 0xAA, "Table Update Descriptor" },
168 { 0xAB, "Contention Control Descriptor" },
169 { 0xAC, "Correction Control Descriptor" },
170 { 0xAD, "Forward Interaction Path Descriptor" },
171 { 0xAE, "Return Interaction Path Descriptor" },
172 { 0xAf, "Connection Control Descriptor" },
173 { 0xB0, "Mobility Control Descriptor" },
174 { 0xB1, "Correction Message Extension Descriptor" },
175 { 0xB2, "Return Transmission Modes Descriptor" },
176 { 0xB3, "Mesh Logon Initialize Descriptor" },
177 { 0xB5, "Implementation Type Descriptor" },
178 { 0xB6, "LL FEC Identifier Descriptor" },
182 static value_string_ext mpeg_descriptor_tag_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descriptor_tag_vals);
184 /* 0x02 Video Stream Descriptor */
185 static int hf_mpeg_descr_video_stream_multiple_frame_rate_flag = -1;
186 static int hf_mpeg_descr_video_stream_frame_rate_code = -1;
187 static int hf_mpeg_descr_video_stream_mpeg1_only_flag = -1;
188 static int hf_mpeg_descr_video_stream_constrained_parameter_flag = -1;
189 static int hf_mpeg_descr_video_stream_still_picture_flag = -1;
190 static int hf_mpeg_descr_video_stream_profile_and_level_indication = -1;
191 static int hf_mpeg_descr_video_stream_chroma_format = -1;
192 static int hf_mpeg_descr_video_stream_frame_rate_extension_flag = -1;
193 static int hf_mpeg_descr_video_stream_reserved = -1;
195 #define MPEG_DESCR_VIDEO_STREAM_MULTIPLE_FRAME_RATE_FLAG_MASK 0x80
196 #define MPEG_DESCR_VIDEO_STREAM_FRAME_RATE_CODE_MASK 0x78
197 #define MPEG_DESCR_VIDEO_STREAM_MPEG1_ONLY_FLAG_MASK 0x04
198 #define MPEG_DESCR_VIDEO_STREAM_CONSTRAINED_PARAMETER_FLAG_MASK 0x02
199 #define MPEG_DESCR_VIDEO_STREAM_STILL_PICTURE_FLAG_MASK 0x01
200 #define MPEG_DESCR_VIDEO_STREAM_CHROMA_FORMAT_MASK 0xC0
201 #define MPEG_DESCR_VIDEO_STREAM_FRAME_RATE_EXTENSION_FLAG_MASK 0x20
202 #define MPEG_DESCR_VIDEO_STREAM_RESERVED_MASK 0x1F
204 static const value_string mpeg_descr_video_stream_multiple_frame_rate_flag_vals[] = {
205 { 0x00, "Single frame rate present" },
206 { 0x01, "Multiple frame rate present" },
212 proto_mpeg_descriptor_dissect_video_stream(tvbuff_t *tvb, guint offset, proto_tree *tree)
215 guint8 mpeg1_only_flag;
217 mpeg1_only_flag = tvb_get_guint8(tvb, offset) & MPEG_DESCR_VIDEO_STREAM_MPEG1_ONLY_FLAG_MASK;
218 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_multiple_frame_rate_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
219 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_frame_rate_code, tvb, offset, 1, ENC_BIG_ENDIAN);
220 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_mpeg1_only_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
221 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_constrained_parameter_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
222 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_still_picture_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
226 if (mpeg1_only_flag == 0) {
228 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_profile_and_level_indication, tvb, offset, 1, ENC_BIG_ENDIAN);
231 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_chroma_format, tvb, offset, 1, ENC_BIG_ENDIAN);
232 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_frame_rate_extension_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
233 proto_tree_add_item(tree, hf_mpeg_descr_video_stream_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
237 /* 0x03 Audio Stream Descriptor */
238 static int hf_mpeg_descr_audio_stream_free_format_flag = -1;
239 static int hf_mpeg_descr_audio_stream_id = -1;
240 static int hf_mpeg_descr_audio_stream_layer = -1;
241 static int hf_mpeg_descr_audio_stream_variable_rate_audio_indicator = -1;
242 static int hf_mpeg_descr_audio_stream_reserved = -1;
244 #define MPEG_DESCR_AUDIO_STREAM_FREE_FORMAT_FLAG_MASK 0x80
245 #define MPEG_DESCR_AUDIO_STREAM_ID_MASK 0x40
246 #define MPEG_DESCR_AUDIO_STREAM_LAYER_MASK 0x30
247 #define MPEG_DESCR_AUDIO_STREAM_VARIABLE_RATE_AUDIO_INDICATOR_MASK 0x08
248 #define MPEG_DESCR_AUDIO_STREAM_RESERVED_MASK 0x07
250 static const value_string mpeg_descr_audio_stream_free_format_flag_vals[] = {
251 { 0x00, "bitrate_index is not 0" },
252 { 0x01, "One more more audio frame has bitrate_index = 0" },
257 static const value_string mpeg_descr_audio_stream_id_vals[] = {
258 { 0x00, "ID not set to 1 in all the frames" },
259 { 0x01, "ID set to 1 in all the frames" },
264 static const value_string mpeg_descr_audio_stream_variable_rate_audio_indicator_vals[] = {
265 { 0x00, "Constant bitrate" },
266 { 0x01, "Variable bitrate" },
273 proto_mpeg_descriptor_dissect_audio_stream(tvbuff_t *tvb, guint offset, proto_tree *tree)
275 proto_tree_add_item(tree, hf_mpeg_descr_audio_stream_free_format_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
276 proto_tree_add_item(tree, hf_mpeg_descr_audio_stream_id, tvb, offset, 1, ENC_BIG_ENDIAN);
277 proto_tree_add_item(tree, hf_mpeg_descr_audio_stream_layer, tvb, offset, 1, ENC_BIG_ENDIAN);
278 proto_tree_add_item(tree, hf_mpeg_descr_audio_stream_variable_rate_audio_indicator, tvb, offset, 1, ENC_BIG_ENDIAN);
279 proto_tree_add_item(tree, hf_mpeg_descr_audio_stream_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
282 /* 0x05 Registration Descriptor */
283 static int hf_mpeg_descr_reg_form_id = -1;
284 static int hf_mpeg_descr_reg_add_id_inf = -1;
287 proto_mpeg_descriptor_dissect_registration(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
291 offset_start = offset;
292 proto_tree_add_item(tree, hf_mpeg_descr_reg_form_id, tvb, offset, 4, ENC_BIG_ENDIAN);
295 while (offset-offset_start<len) {
296 proto_tree_add_item(tree, hf_mpeg_descr_reg_add_id_inf, tvb, offset, 1, ENC_BIG_ENDIAN);
301 /* 0x06 Data Stream Alignment Descriptor */
302 static int hf_mpeg_descr_data_stream_alignment = -1;
304 static const value_string mpeg_descr_data_stream_alignment_vals[] = {
305 { 0x00, "Reserved" },
306 { 0x01, "Slice, or video access unit" },
307 { 0x02, "Video access unit" },
308 { 0x03, "GOP, or SEQ" },
315 proto_mpeg_descriptor_dissect_data_stream_alignment(tvbuff_t *tvb, guint offset, proto_tree *tree)
317 proto_tree_add_item(tree, hf_mpeg_descr_data_stream_alignment, tvb, offset, 1, ENC_BIG_ENDIAN);
320 /* 0x09 CA Descriptor */
321 static int hf_mpeg_descr_ca_system_id = -1;
322 static int hf_mpeg_descr_ca_reserved = -1;
323 static int hf_mpeg_descr_ca_pid = -1;
324 static int hf_mpeg_descr_ca_private = -1;
326 #define MPEG_DESCR_CA_RESERVED_MASK 0xE000
327 #define MPEG_DESCR_CA_PID_MASK 0x1FFF
330 proto_mpeg_descriptor_dissect_ca(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
332 proto_tree_add_item(tree, hf_mpeg_descr_ca_system_id, tvb, offset, 2, ENC_BIG_ENDIAN);
335 proto_tree_add_item(tree, hf_mpeg_descr_ca_reserved, tvb, offset, 2, ENC_BIG_ENDIAN);
336 proto_tree_add_item(tree, hf_mpeg_descr_ca_pid, tvb, offset, 2, ENC_BIG_ENDIAN);
340 proto_tree_add_item(tree, hf_mpeg_descr_ca_private, tvb, offset, len - 4, ENC_NA);
344 /* 0x0A ISO 639 Language Descriptor */
345 static int hf_mpeg_descr_iso639_lang = -1;
346 static int hf_mpeg_descr_iso639_type = -1;
348 static const value_string mpeg_descr_iso639_type_vals[] = {
349 { 0x00, "Undefined" },
350 { 0x01, "Clean Effects" },
351 { 0x02, "Hearing Impaired" },
352 { 0x03, "Visual Impaired Commentary" },
358 proto_mpeg_descriptor_dissect_iso639(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
361 proto_tree_add_item(tree, hf_mpeg_descr_iso639_lang, tvb, offset, len - 1, ENC_ASCII|ENC_NA);
363 proto_tree_add_item(tree, hf_mpeg_descr_iso639_type, tvb, offset, 1, ENC_BIG_ENDIAN);
366 /* 0x0B System Clock Descriptor */
367 static int hf_mpeg_descr_system_clock_external_clock_reference_indicator = -1;
368 static int hf_mpeg_descr_system_clock_reserved1 = -1;
369 static int hf_mpeg_descr_system_clock_accuracy_integer = -1;
370 static int hf_mpeg_descr_system_clock_accuracy_exponent = -1;
371 static int hf_mpeg_descr_system_clock_reserved2 = -1;
373 #define MPEG_DESCR_SYSTEM_CLOCK_EXTERNAL_CLOCK_REFERENCE_INDICATOR_MASK 0x80
374 #define MPEG_DESCR_SYSTEM_CLOCK_RESERVED1_MASK 0x40
375 #define MPEG_DESCR_SYSTEM_CLOCK_ACCURACY_INTEGER_MASK 0x3F
376 #define MPEG_DESCR_SYSTEM_CLOCK_ACCURACY_EXPONENT_MASK 0xE0
377 #define MPEG_DESCR_SYSTEM_CLOCK_RESERVED2_MASK 0x1F
380 proto_mpeg_descriptor_dissect_system_clock(tvbuff_t *tvb, guint offset, proto_tree *tree)
382 proto_tree_add_item(tree, hf_mpeg_descr_system_clock_external_clock_reference_indicator, tvb, offset, 1, ENC_BIG_ENDIAN);
383 proto_tree_add_item(tree, hf_mpeg_descr_system_clock_reserved1, tvb, offset, 1, ENC_BIG_ENDIAN);
384 proto_tree_add_item(tree, hf_mpeg_descr_system_clock_accuracy_integer, tvb, offset, 1, ENC_BIG_ENDIAN);
387 proto_tree_add_item(tree, hf_mpeg_descr_system_clock_accuracy_exponent, tvb, offset, 1, ENC_BIG_ENDIAN);
388 proto_tree_add_item(tree, hf_mpeg_descr_system_clock_reserved2, tvb, offset, 1, ENC_BIG_ENDIAN);
391 /* 0x0E Maximum Bitrate Descriptor */
392 static int hf_mpeg_descr_max_bitrate_reserved = -1;
393 static int hf_mpeg_descr_max_bitrate = -1;
395 #define MPEG_DESCR_MAX_BITRATE_RESERVED_MASK 0xC00000
396 #define MPEG_DESCR_MAX_BITRATE_MASK 0x3FFFFF
399 proto_mpeg_descriptor_dissect_max_bitrate(tvbuff_t *tvb, guint offset, proto_tree *tree)
401 proto_item *rate_item;
405 proto_tree_add_item(tree, hf_mpeg_descr_max_bitrate_reserved, tvb, offset, 3, ENC_BIG_ENDIAN);
406 rate = tvb_get_ntoh24(tvb, offset) & MPEG_DESCR_MAX_BITRATE_MASK;
407 rate_item = proto_tree_add_item(tree, hf_mpeg_descr_max_bitrate, tvb, offset, 3, ENC_BIG_ENDIAN);
408 proto_item_append_text(rate_item, " (%u bytes/sec)", rate * 50);
411 /* 0x10 Smoothing Buffer Descriptor */
412 static int hf_mpeg_descr_smoothing_buffer_reserved1 = -1;
413 static int hf_mpeg_descr_smoothing_buffer_leak_rate = -1;
414 static int hf_mpeg_descr_smoothing_buffer_reserved2 = -1;
415 static int hf_mpeg_descr_smoothing_buffer_size = -1;
417 #define MPEG_DESCR_SMOOTHING_BUFFER_RESERVED1_MASK 0xC00000
418 #define MPEG_DESCR_SMOOTHING_BUFFER_LEAK_RATE_MASK 0x3FFFFF
419 #define MPEG_DESCR_SMOOTHING_BUFFER_RESERVED2_MASK 0xC00000
420 #define MPEG_DESCR_SMOOTHING_BUFFER_SIZE_MASK 0x3FFFFF
423 proto_mpeg_descriptor_dissect_smoothing_buffer(tvbuff_t *tvb, guint offset, proto_tree *tree)
425 proto_item *leak_rate_item;
429 proto_tree_add_item(tree, hf_mpeg_descr_smoothing_buffer_reserved1, tvb, offset, 3, ENC_BIG_ENDIAN);
430 leak_rate = tvb_get_ntoh24(tvb, offset) & MPEG_DESCR_SMOOTHING_BUFFER_LEAK_RATE_MASK;
431 leak_rate_item = proto_tree_add_item(tree, hf_mpeg_descr_smoothing_buffer_leak_rate, tvb, offset, 3, ENC_BIG_ENDIAN);
432 proto_item_append_text(leak_rate_item, " (%u bytes/sec)", leak_rate * 400 / 8);
435 proto_tree_add_item(tree, hf_mpeg_descr_smoothing_buffer_reserved2, tvb, offset, 3, ENC_BIG_ENDIAN);
436 proto_tree_add_item(tree, hf_mpeg_descr_smoothing_buffer_size, tvb, offset, 3, ENC_BIG_ENDIAN);
440 /* 0x11 STD Descriptor */
441 static int hf_mpeg_descr_std_reserved = -1;
442 static int hf_mpeg_descr_std_leak_valid = -1;
444 #define MPEG_DESCR_STD_RESERVED_MASK 0xFE
445 #define MPEG_DESCR_STD_LEAK_VALID_MASK 0x01
448 proto_mpeg_descriptor_dissect_std(tvbuff_t *tvb, guint offset, proto_tree *tree)
450 proto_tree_add_item(tree, hf_mpeg_descr_std_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
451 proto_tree_add_item(tree, hf_mpeg_descr_std_leak_valid, tvb, offset, 1, ENC_BIG_ENDIAN);
454 /* 0x13 Carousel Identifier Descriptor */
455 static int hf_mpeg_descr_carousel_identifier_id = -1;
456 static int hf_mpeg_descr_carousel_identifier_format_id = -1;
457 static int hf_mpeg_descr_carousel_identifier_module_version = -1;
458 static int hf_mpeg_descr_carousel_identifier_module_id = -1;
459 static int hf_mpeg_descr_carousel_identifier_block_size = -1;
460 static int hf_mpeg_descr_carousel_identifier_module_size = -1;
461 static int hf_mpeg_descr_carousel_identifier_compression_method = -1;
462 static int hf_mpeg_descr_carousel_identifier_original_size = -1;
463 static int hf_mpeg_descr_carousel_identifier_timeout = -1;
464 static int hf_mpeg_descr_carousel_identifier_object_key_len = -1;
465 static int hf_mpeg_descr_carousel_identifier_object_key_data = -1;
466 static int hf_mpeg_descr_carousel_identifier_private = -1;
468 static const value_string mpeg_descr_carousel_identifier_format_id_vals[] = {
469 { 0x00, "No Format Specifier" },
470 { 0x01, "Format Specifier" },
476 proto_mpeg_descriptor_dissect_carousel_identifier(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
480 guint private_len = 0;
482 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_id, tvb, offset, 4, ENC_BIG_ENDIAN);
485 format_id = tvb_get_guint8(tvb, offset);
486 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_format_id, tvb, offset, 1, ENC_BIG_ENDIAN);
489 if (format_id == 0x01) {
490 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_module_version, tvb, offset, 1, ENC_BIG_ENDIAN);
493 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_module_id, tvb, offset, 2, ENC_BIG_ENDIAN);
496 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_block_size, tvb, offset, 2, ENC_BIG_ENDIAN);
499 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_module_size, tvb, offset, 4, ENC_BIG_ENDIAN);
502 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_compression_method, tvb, offset, 1, ENC_BIG_ENDIAN);
505 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_original_size, tvb, offset, 4, ENC_BIG_ENDIAN);
508 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_timeout, tvb, offset, 1, ENC_BIG_ENDIAN);
511 key_len = tvb_get_guint8(tvb, offset);
512 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_object_key_len, tvb, offset, 1, ENC_BIG_ENDIAN);
515 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_object_key_data, tvb, offset, key_len, ENC_NA);
518 if (len > (key_len + 20))
519 private_len = len - 20 - key_len;
523 private_len = len - 5;
527 proto_tree_add_item(tree, hf_mpeg_descr_carousel_identifier_private, tvb, offset, private_len, ENC_NA);
531 /* 0x14 Association Tag Descriptor */
532 static int hf_mpeg_descr_association_tag = -1;
533 static int hf_mpeg_descr_association_tag_use = -1;
534 static int hf_mpeg_descr_association_tag_selector_len = -1;
535 static int hf_mpeg_descr_association_tag_transaction_id = -1;
536 static int hf_mpeg_descr_association_tag_timeout = -1;
537 static int hf_mpeg_descr_association_tag_selector_bytes = -1;
538 static int hf_mpeg_descr_association_tag_private_bytes = -1;
541 proto_mpeg_descriptor_dissect_association_tag(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
543 guint end = offset + len;
547 proto_tree_add_item(tree, hf_mpeg_descr_association_tag, tvb, offset, 2, ENC_BIG_ENDIAN);
550 use = tvb_get_ntohs(tvb, offset);
551 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_use, tvb, offset, 2, ENC_BIG_ENDIAN);
554 selector_len = tvb_get_guint8(tvb, offset);
555 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_selector_len, tvb, offset, 1, ENC_BIG_ENDIAN);
559 if (selector_len != 8)
561 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_transaction_id, tvb, offset, 4, ENC_BIG_ENDIAN);
564 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_timeout, tvb, offset, 4, ENC_BIG_ENDIAN);
568 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_selector_bytes, tvb, offset, selector_len, ENC_NA);
569 offset += selector_len;
573 proto_tree_add_item(tree, hf_mpeg_descr_association_tag_private_bytes, tvb, offset, end - offset, ENC_NA);
576 /* 0x28 AVC Video Descriptor */
577 static int hf_mpeg_descr_avc_vid_profile_idc = -1;
578 static int hf_mpeg_descr_avc_vid_constraint_set0_flag = -1;
579 static int hf_mpeg_descr_avc_vid_constraint_set1_flag = -1;
580 static int hf_mpeg_descr_avc_vid_constraint_set2_flag = -1;
581 static int hf_mpeg_descr_avc_vid_compatible_flags = -1;
582 static int hf_mpeg_descr_avc_vid_level_idc = -1;
583 static int hf_mpeg_descr_avc_vid_still_present = -1;
584 static int hf_mpeg_descr_avc_vid_24h_picture_flag = -1;
585 static int hf_mpeg_descr_avc_vid_reserved = -1;
587 #define MPEG_DESCR_AVC_VID_CONSTRAINT_SET0_FLAG_MASK 0x80
588 #define MPEG_DESCR_AVC_VID_CONSTRAINT_SET1_FLAG_MASK 0x40
589 #define MPEG_DESCR_AVC_VID_CONSTRAINT_SET2_FLAG_MASK 0x20
590 #define MPEG_DESCR_AVC_VID_COMPATIBLE_FLAGS_MASK 0x1F
591 #define MPEG_DESCR_AVC_VID_STILL_PRESENT_MASK 0x80
592 #define MPEG_DESCR_AVC_VID_24H_PICTURE_FLAG_MASK 0x40
593 #define MPEG_DESCR_AVC_VID_RESERVED_MASK 0x3F
596 proto_mpeg_descriptor_dissect_avc_vid(tvbuff_t *tvb, guint offset, proto_tree *tree)
598 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_profile_idc, tvb, offset, 1, ENC_BIG_ENDIAN);
601 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_constraint_set0_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
602 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_constraint_set1_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
603 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_constraint_set2_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
604 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_compatible_flags, tvb, offset, 1, ENC_BIG_ENDIAN);
607 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_level_idc, tvb, offset, 1, ENC_BIG_ENDIAN);
610 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_still_present, tvb, offset, 1, ENC_BIG_ENDIAN);
611 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_24h_picture_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
612 proto_tree_add_item(tree, hf_mpeg_descr_avc_vid_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
615 /* 0x40 Network Name Descriptor */
616 static int hf_mpeg_descr_network_name_descriptor = -1;
619 proto_mpeg_descriptor_dissect_network_name(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
621 proto_tree_add_item(tree, hf_mpeg_descr_network_name_descriptor, tvb, offset, len, ENC_ASCII|ENC_NA);
624 /* 0x41 Service List Descriptor */
625 static int hf_mpeg_descr_service_list_id = -1;
626 static int hf_mpeg_descr_service_list_type = -1;
628 static gint ett_mpeg_descriptor_service_list = -1;
631 proto_mpeg_descriptor_dissect_service_list(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
633 guint end = offset + len;
636 proto_tree *svc_tree;
639 while (offset < end) {
640 svc_id = tvb_get_ntohs(tvb, offset);
642 svc_tree = proto_tree_add_subtree_format(tree, tvb, offset, 3,
643 ett_mpeg_descriptor_service_list, NULL, "Service 0x%02x", svc_id);
645 proto_tree_add_item(svc_tree, hf_mpeg_descr_service_list_id, tvb, offset, 2, ENC_BIG_ENDIAN);
648 proto_tree_add_item(svc_tree, hf_mpeg_descr_service_list_type, tvb, offset, 1, ENC_BIG_ENDIAN);
653 /* 0x42 Stuffing Descriptor */
654 static int hf_mpeg_descr_stuffing = -1;
657 proto_mpeg_descriptor_stuffing(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
659 proto_tree_add_item(tree, hf_mpeg_descr_stuffing, tvb, offset, len, ENC_NA);
662 /* 0x43 Satellite Delivery System Descriptor */
663 static int hf_mpeg_descr_satellite_delivery_frequency = -1;
664 static int hf_mpeg_descr_satellite_delivery_orbital_position = -1;
665 static int hf_mpeg_descr_satellite_delivery_west_east_flag = -1;
666 static int hf_mpeg_descr_satellite_delivery_polarization = -1;
667 static int hf_mpeg_descr_satellite_delivery_roll_off = -1;
668 static int hf_mpeg_descr_satellite_delivery_zero = -1;
669 static int hf_mpeg_descr_satellite_delivery_modulation_system = -1;
670 static int hf_mpeg_descr_satellite_delivery_modulation_type = -1;
671 static int hf_mpeg_descr_satellite_delivery_symbol_rate = -1;
672 static int hf_mpeg_descr_satellite_delivery_fec_inner = -1;
674 #define MPEG_DESCR_SATELLITE_DELIVERY_WEST_EAST_FLAG_MASK 0x80
675 #define MPEG_DESCR_SATELLITE_DELIVERY_POLARIZATION_MASK 0x60
676 #define MPEG_DESCR_SATELLITE_DELIVERY_ROLL_OFF_MASK 0x18
677 #define MPEG_DESCR_SATELLITE_DELIVERY_ZERO_MASK 0x18
678 #define MPEG_DESCR_SATELLITE_DELIVERY_MODULATION_SYSTEM_MASK 0x04
679 #define MPEG_DESCR_SATELLITE_DELIVERY_MODULATION_TYPE_MASK 0x03
680 #define MPEG_DESCR_SATELLITE_DELIVERY_FEC_INNER_MASK 0x0F
682 static const value_string mpeg_descr_satellite_delivery_west_east_flag_vals[] = {
689 static const value_string mpeg_descr_satellite_delivery_polarization_vals[] = {
690 { 0x0, "Linear - Horizontal" },
691 { 0x1, "Linear - Vertical" },
692 { 0x2, "Circular - Left" },
693 { 0x3, "Circular - Right" },
698 static const value_string mpeg_descr_satellite_delivery_roll_off_vals[] = {
699 { 0x0, "alpha = 0,35" },
700 { 0x1, "alpha = 0,25" },
701 { 0x2, "alpha = 0,20" },
706 static const value_string mpeg_descr_satellite_delivery_modulation_system_vals[] = {
713 static const value_string mpeg_descr_satellite_delivery_modulation_type_vals[] = {
717 { 0x3, "16-QAM (n/a for DVB-S2)" },
722 static const value_string mpeg_descr_satellite_delivery_fec_inner_vals[] = {
723 { 0x0, "Not defined" },
724 { 0x1, "1/2 convolutional code rate" },
725 { 0x2, "2/3 convolutional code rate" },
726 { 0x3, "3/4 convolutional code rate" },
727 { 0x4, "5/6 convolutional code rate" },
728 { 0x5, "7/8 convolutional code rate" },
729 { 0x6, "8/9 convolutional code rate" },
730 { 0x7, "3/5 convolutional code rate" },
731 { 0x8, "4/5 convolutional code rate" },
732 { 0x9, "9/10 convolutional code rate" },
733 { 0xF, "No convolutional coding" },
737 static value_string_ext mpeg_descr_satellite_delivery_fec_inner_vals_ext =
738 VALUE_STRING_EXT_INIT(mpeg_descr_satellite_delivery_fec_inner_vals);
741 proto_mpeg_descriptor_dissect_satellite_delivery(tvbuff_t *tvb, guint offset, proto_tree *tree)
744 double frequency, symbol_rate;
745 float orbital_position;
746 guint8 modulation_system;
748 frequency = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset)) * 10.0 +
749 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1)) / 10.0 +
750 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+2)) / 1000.0 +
751 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+3)) / 100000.0;
752 proto_tree_add_double(tree, hf_mpeg_descr_satellite_delivery_frequency,
753 tvb, offset, 4, frequency);
756 orbital_position = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset)) * 10.0f +
757 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1)) / 10.0f;
758 proto_tree_add_float(tree, hf_mpeg_descr_satellite_delivery_orbital_position,
759 tvb, offset, 2, orbital_position);
762 modulation_system = tvb_get_guint8(tvb, offset) & MPEG_DESCR_SATELLITE_DELIVERY_MODULATION_SYSTEM_MASK;
764 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_west_east_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
765 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_polarization, tvb, offset, 1, ENC_BIG_ENDIAN);
766 if (modulation_system)
767 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_roll_off, tvb, offset, 1, ENC_BIG_ENDIAN);
769 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_zero, tvb, offset, 1, ENC_BIG_ENDIAN);
770 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_modulation_system, tvb, offset, 1, ENC_BIG_ENDIAN);
771 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_modulation_type, tvb, offset, 1, ENC_BIG_ENDIAN);
774 symbol_rate = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset)) * 10.0 +
775 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1)) / 10.0 +
776 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+2)) / 1000.0 +
777 /* symbol rate is 28 bits, only the upper 4 bits of this byte are used */
778 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+3)>>4) / 10000.0;
779 proto_tree_add_double_format_value(tree, hf_mpeg_descr_satellite_delivery_symbol_rate,
780 tvb, offset, 4, symbol_rate, "%3.4f MSym/s", symbol_rate);
783 proto_tree_add_item(tree, hf_mpeg_descr_satellite_delivery_fec_inner, tvb, offset, 1, ENC_BIG_ENDIAN);
787 /* 0x44 Cable Delivery System Descriptor */
788 static int hf_mpeg_descr_cable_delivery_frequency = -1;
789 static int hf_mpeg_descr_cable_delivery_reserved = -1;
790 static int hf_mpeg_descr_cable_delivery_fec_outer = -1;
791 static int hf_mpeg_descr_cable_delivery_modulation = -1;
792 static int hf_mpeg_descr_cable_delivery_symbol_rate = -1;
793 static int hf_mpeg_descr_cable_delivery_fec_inner = -1;
795 #define MPEG_DESCR_CABLE_DELIVERY_RESERVED_MASK 0xFFF0
796 #define MPEG_DESCR_CABLE_DELIVERY_FEC_OUTER_MASK 0x000F
797 #define MPEG_DESCR_CABLE_DELIVERY_FEC_INNER_MASK 0x0F
799 static const value_string mpeg_descr_cable_delivery_fec_outer_vals[] = {
800 { 0x0, "Not defined" },
801 { 0x1, "No outer FEC coding" },
802 { 0x2, "RS(204/188)" },
807 static const value_string mpeg_descr_cable_delivery_modulation_vals[] = {
808 { 0x00, "Not defined" },
818 static const value_string mpeg_descr_cable_delivery_fec_inner_vals[] = {
819 { 0x0, "Not defined" },
820 { 0x1, "1/2 convolutional code rate" },
821 { 0x2, "2/3 convolutional code rate" },
822 { 0x3, "3/4 convolutional code rate" },
823 { 0x4, "5/6 convolutional code rate" },
824 { 0x5, "7/8 convolutional code rate" },
825 { 0x6, "8/9 convolutional code rate" },
826 { 0x7, "3/5 convolutional code rate" },
827 { 0x8, "4/5 convolutional code rate" },
828 { 0x9, "9/10 convolutional code rate" },
829 { 0xF, "No convolutional coding" },
833 static value_string_ext mpeg_descr_cable_delivery_fec_inner_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_cable_delivery_fec_inner_vals);
836 proto_mpeg_descriptor_dissect_cable_delivery(tvbuff_t *tvb, guint offset, proto_tree *tree) {
838 double frequency, symbol_rate;
840 frequency = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset)) * 100.0 +
841 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1)) +
842 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+2)) / 100.0 +
843 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+3)) / 10000.0;
844 proto_tree_add_double_format_value(tree, hf_mpeg_descr_cable_delivery_frequency,
845 tvb, offset, 4, frequency, "%4.4f MHz", frequency);
848 proto_tree_add_item(tree, hf_mpeg_descr_cable_delivery_reserved, tvb, offset, 2, ENC_BIG_ENDIAN);
849 proto_tree_add_item(tree, hf_mpeg_descr_cable_delivery_fec_outer, tvb, offset, 2, ENC_BIG_ENDIAN);
852 proto_tree_add_item(tree, hf_mpeg_descr_cable_delivery_modulation, tvb, offset, 1, ENC_BIG_ENDIAN);
855 symbol_rate = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset)) * 10.0 +
856 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1)) / 10.0 +
857 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+2)) / 1000.0 +
858 /* symbol rate is 28 bits, only the upper 4 bits of this byte are used */
859 MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+3)>>4) / 10000.0;
860 proto_tree_add_double_format_value(tree, hf_mpeg_descr_cable_delivery_symbol_rate,
861 tvb, offset, 4, symbol_rate, "%3.4f MSymbol/s", symbol_rate);
863 proto_tree_add_item(tree, hf_mpeg_descr_cable_delivery_fec_inner, tvb, offset, 1, ENC_BIG_ENDIAN);
868 /* 0x45 VBI Data Descriptor */
869 static int hf_mpeg_descr_vbi_data_service_id = -1;
870 static int hf_mpeg_descr_vbi_data_descr_len = -1;
871 static int hf_mpeg_descr_vbi_data_reserved1 = -1;
872 static int hf_mpeg_descr_vbi_data_field_parity = -1;
873 static int hf_mpeg_descr_vbi_data_line_offset = -1;
874 static int hf_mpeg_descr_vbi_data_reserved2 = -1;
876 #define MPEG_DESCR_VBI_DATA_RESERVED1_MASK 0xC0
877 #define MPEG_DESCR_VBI_DATA_FIELD_PARITY_MASK 0x20
878 #define MPEG_DESCR_VBI_DATA_LINE_OFFSET_MASK 0x1F
880 static gint ett_mpeg_descriptor_vbi_data_service = -1;
882 static const value_string mpeg_descr_vbi_data_service_id_vals[] = {
884 { 0x00, "Reserved" },
885 { 0x01, "EBU Teletext" },
886 { 0x02, "Inverted Teletext" },
887 { 0x03, "Reserved" },
890 { 0x06, "Closed Captioning" },
891 { 0x07, "Monochrome 4:2:2 samples" },
896 static const value_string mpeg_descr_vbi_data_field_parity_vals[] = {
897 { 0x00, "Second (even) field of frame" },
898 { 0x01, "First (odd) field of frame" },
904 proto_mpeg_descriptor_dissect_vbi_data(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
907 guint8 svc_id, svc_len;
908 guint end = offset + len, svc_end;
910 proto_tree *svc_tree;
912 while (offset < end) {
913 svc_id = tvb_get_guint8(tvb, offset);
914 svc_len = tvb_get_guint8(tvb, offset + 1);
915 svc_tree = proto_tree_add_subtree_format(tree, tvb, offset, svc_len + 2,
916 ett_mpeg_descriptor_vbi_data_service, NULL, "Service 0x%02x", svc_id);
918 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_service_id, tvb, offset, 1, ENC_BIG_ENDIAN);
921 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_descr_len, tvb, offset, 1, ENC_BIG_ENDIAN);
931 svc_end = offset + svc_len;
932 while (offset < svc_end) {
933 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_reserved1, tvb, offset, 1, ENC_BIG_ENDIAN);
934 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_field_parity, tvb, offset, 1, ENC_BIG_ENDIAN);
935 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_line_offset, tvb, offset, 1, ENC_BIG_ENDIAN);
940 proto_tree_add_item(svc_tree, hf_mpeg_descr_vbi_data_reserved2, tvb, offset, svc_len, ENC_NA);
948 /* 0x47 Bouquet Name Descriptor */
949 static int hf_mpeg_descr_bouquet_name = -1;
952 proto_mpeg_descriptor_dissect_bouquet_name(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
954 proto_tree_add_item(tree, hf_mpeg_descr_bouquet_name, tvb, offset, len, ENC_ASCII|ENC_NA);
957 /* 0x48 Service Descriptor */
958 static int hf_mpeg_descr_service_type = -1;
959 static int hf_mpeg_descr_service_provider_name_length = -1;
960 static int hf_mpeg_descr_service_provider_name_encoding = -1;
961 static int hf_mpeg_descr_service_provider = -1;
962 static int hf_mpeg_descr_service_name_length = -1;
963 static int hf_mpeg_descr_service_name_encoding = -1;
964 static int hf_mpeg_descr_service_name = -1;
966 static const value_string mpeg_descr_service_type_vals[] = {
968 { 0x00, "reserved" },
969 { 0x01, "digital television service" },
970 { 0x02, "digital radio sound service" },
971 { 0x03, "Teletext service" },
972 { 0x04, "NVOD reference service" },
973 { 0x05, "NVOD time-shifted service" },
974 { 0x06, "mosaic service" },
975 { 0x07, "FM radio service" },
976 { 0x08, "DVB SRM service" },
977 { 0x09, "reserved" },
978 { 0x0A, "advanced codec digital radio sound service" },
979 { 0x0B, "advanced codec mosaic service" },
980 { 0x0C, "data broadcast service" },
981 { 0x0D, "reserved for Common Interface Usage (EN 50221)" },
982 { 0x0E, "RCS Map (see EN 301 790)" },
983 { 0x0F, "RCS FLS (see EN 301 790)" },
984 { 0x10, "DVB MHP service" },
985 { 0x11, "MPEG-2 HD digital television service" },
986 { 0x16, "advanced codec SD digital television service" },
987 { 0x17, "advanced codec SD NVOD time-shifted service" },
988 { 0x18, "advanced codec SD NVOD reference service" },
989 { 0x19, "advanced codec HD digital television service" },
990 { 0x1A, "advanced codec HD NVOD time-shifted service" },
991 { 0x1F, "HEVC digital television service" },
995 /* global variable that's shared e.g. with DVB-CI */
996 value_string_ext mpeg_descr_service_type_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_service_type_vals);
999 proto_mpeg_descriptor_dissect_service(tvbuff_t *tvb, guint offset, proto_tree *tree)
1001 guint8 prov_len, name_len;
1003 dvb_encoding_e encoding;
1005 proto_tree_add_item(tree, hf_mpeg_descr_service_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1008 prov_len = tvb_get_guint8(tvb, offset);
1009 proto_tree_add_item(tree, hf_mpeg_descr_service_provider_name_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1013 enc_len = dvb_analyze_string_charset(tvb, offset, prov_len, &encoding);
1014 dvb_add_chartbl(tree, hf_mpeg_descr_service_provider_name_encoding, tvb, offset, enc_len, encoding);
1016 proto_tree_add_item(tree, hf_mpeg_descr_service_provider,
1017 tvb, offset+enc_len, prov_len-enc_len, dvb_enc_to_item_enc(encoding));
1021 name_len = tvb_get_guint8(tvb, offset);
1022 proto_tree_add_item(tree, hf_mpeg_descr_service_name_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1026 enc_len = dvb_analyze_string_charset(tvb, offset, name_len, &encoding);
1027 dvb_add_chartbl(tree, hf_mpeg_descr_service_name_encoding, tvb, offset, enc_len, encoding);
1029 proto_tree_add_item(tree, hf_mpeg_descr_service_name,
1030 tvb, offset+enc_len, name_len-enc_len, dvb_enc_to_item_enc(encoding));
1035 /* 0x4A Linkage Descriptor */
1036 static int hf_mpeg_descr_linkage_transport_stream_id = -1;
1037 static int hf_mpeg_descr_linkage_original_network_id = -1;
1038 static int hf_mpeg_descr_linkage_service_id = -1;
1039 static int hf_mpeg_descr_linkage_linkage_type = -1;
1041 static int hf_mpeg_descr_linkage_hand_over_type = -1;
1042 static int hf_mpeg_descr_linkage_reserved1 = -1;
1043 static int hf_mpeg_descr_linkage_origin_type = -1;
1044 static int hf_mpeg_descr_linkage_network_id = -1;
1045 static int hf_mpeg_descr_linkage_initial_service_id = -1;
1047 static int hf_mpeg_descr_linkage_target_event_id = -1;
1048 static int hf_mpeg_descr_linkage_target_listed = -1;
1049 static int hf_mpeg_descr_linkage_event_simulcast = -1;
1050 static int hf_mpeg_descr_linkage_reserved2 = -1;
1052 static int hf_mpeg_descr_linkage_interactive_network_id = -1;
1053 static int hf_mpeg_descr_linkage_population_id_loop_count = -1;
1054 static int hf_mpeg_descr_linkage_population_id = -1;
1055 static int hf_mpeg_descr_linkage_population_id_base = -1;
1056 static int hf_mpeg_descr_linkage_population_id_mask = -1;
1058 static int hf_mpeg_descr_linkage_private_data_byte = -1;
1060 static gint ett_mpeg_descriptor_linkage_population_id = -1;
1062 #define MPEG_DESCR_LINKAGE_HAND_OVER_TYPE_MASK 0xF0
1063 #define MPEG_DESCR_LINKAGE_HAND_OVER_TYPE_SHIFT 0x04
1064 #define MPEG_DESCR_LINKAGE_RESERVED1_MASK 0x0E
1065 #define MPEG_DESCR_LINKAGE_ORIGIN_TYPE_MASK 0x01
1067 #define MPEG_DESCR_LINKAGE_TARGET_LISTED_MASK 0x80
1068 #define MPEG_DESCR_LINKAGE_EVENT_SIMULCAST_MASK 0x40
1069 #define MPEG_DESCR_LINKAGE_RESERVED2_MASK 0x3F
1071 static const value_string mpeg_descr_linkage_linkage_type_vals[] = {
1072 { 0x01, "Information service" },
1073 { 0x02, "EPG service" },
1074 { 0x03, "CA replacement service" },
1075 { 0x04, "TS containing complete Network/Bouquet SI" },
1076 { 0x05, "Service replacement service" },
1077 { 0x06, "Data broadcast service" },
1078 { 0x07, "RCS Map" },
1079 { 0x08, "Mobile hand-over" },
1080 { 0x09, "System Software Update Service" },
1081 { 0x0A, "TS containing SSU BAT or NIT" },
1082 { 0x0B, "IP/MAC Notification Service" },
1083 { 0x0C, "TS containing INT BAT or NIT" },
1084 { 0x0D, "Event linkage" },
1085 { 0x81, "RCS FLS" },
1089 static value_string_ext mpeg_descr_linkage_linkage_type_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_linkage_linkage_type_vals);
1092 static const value_string mpeg_descr_linkage_hand_over_type_vals[] = {
1093 { 0x01, "DVB hand-over to an identical service in a neighbouring country" },
1094 { 0x02, "DVB hand-over to a local variation of the same service" },
1095 { 0x03, "DVB hand-over to an associated service" },
1101 static const value_string mpeg_descr_linkage_origin_type_vals[] = {
1108 static const value_string mpeg_descr_linkage_target_listed_vals[] = {
1109 { 0x0, "Service may not be included in SDT" },
1110 { 0x1, "Service should be included in SDT" },
1115 static const value_string mpeg_descr_linkage_event_simulcast_vals[] = {
1116 { 0x0, "Events are offset in time" },
1117 { 0x1, "Target and source events are being simulcast" },
1123 proto_mpeg_descriptor_dissect_linkage(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1126 guint8 linkage_type, hand_over_type, origin_type;
1127 guint end = offset + len;
1128 guint population_id_loop_count;
1129 guint16 population_id_base, population_id_mask;
1132 proto_tree *population_tree;
1134 proto_tree_add_item(tree, hf_mpeg_descr_linkage_transport_stream_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1137 proto_tree_add_item(tree, hf_mpeg_descr_linkage_original_network_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1140 proto_tree_add_item(tree, hf_mpeg_descr_linkage_service_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1143 proto_tree_add_item(tree, hf_mpeg_descr_linkage_linkage_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1144 linkage_type = tvb_get_guint8(tvb, offset);
1147 if (linkage_type == 0x08) {
1148 proto_tree_add_item(tree, hf_mpeg_descr_linkage_hand_over_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1149 proto_tree_add_item(tree, hf_mpeg_descr_linkage_reserved1, tvb, offset, 1, ENC_BIG_ENDIAN);
1150 proto_tree_add_item(tree, hf_mpeg_descr_linkage_origin_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1151 hand_over_type = (tvb_get_guint8(tvb, offset) & MPEG_DESCR_LINKAGE_HAND_OVER_TYPE_MASK) >> MPEG_DESCR_LINKAGE_HAND_OVER_TYPE_SHIFT;
1152 origin_type = tvb_get_guint8(tvb, offset) & MPEG_DESCR_LINKAGE_ORIGIN_TYPE_MASK;
1155 if ((hand_over_type == 1) || (hand_over_type == 2) || (hand_over_type == 3)) {
1156 proto_tree_add_item(tree, hf_mpeg_descr_linkage_network_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1161 proto_tree_add_item(tree, hf_mpeg_descr_linkage_initial_service_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1165 } else if (linkage_type == 0x0D) {
1166 proto_tree_add_item(tree, hf_mpeg_descr_linkage_target_event_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1169 proto_tree_add_item(tree, hf_mpeg_descr_linkage_target_listed, tvb, offset, 1, ENC_BIG_ENDIAN);
1170 proto_tree_add_item(tree, hf_mpeg_descr_linkage_event_simulcast, tvb, offset, 1, ENC_BIG_ENDIAN);
1171 proto_tree_add_item(tree, hf_mpeg_descr_linkage_reserved2, tvb, offset, 1, ENC_BIG_ENDIAN);
1172 } else if (linkage_type == 0x81) {
1173 /* linkage type 0x81 is "user defined" in the DVB-SI spec (EN 300468)
1174 it is defined in the interaction channel spec (EN 301790)
1175 it seems that in practice, 0x81 is also used for other purposes than interaction channel
1176 if the following data really belongs to interaction channel, we need at least another 7 bytes */
1180 proto_tree_add_item(tree, hf_mpeg_descr_linkage_interactive_network_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1183 population_id_loop_count = tvb_get_guint8(tvb, offset) + 1;
1184 proto_tree_add_item(tree, hf_mpeg_descr_linkage_population_id_loop_count, tvb, offset, 1, ENC_BIG_ENDIAN);
1187 while (population_id_loop_count--) {
1188 population_id_base = tvb_get_ntohs(tvb, offset);
1189 population_id_mask = tvb_get_ntohs(tvb, offset + 2);
1190 pi = proto_tree_add_uint_format_value(tree, hf_mpeg_descr_linkage_population_id, tvb, offset, 4,
1191 population_id_base<<16|population_id_mask,
1192 "0x%04x / 0x%04x", population_id_base, population_id_mask);
1193 population_tree = proto_item_add_subtree(pi, ett_mpeg_descriptor_linkage_population_id);
1195 proto_tree_add_item(population_tree, hf_mpeg_descr_linkage_population_id_base, tvb, offset, 2, ENC_BIG_ENDIAN);
1198 proto_tree_add_item(population_tree, hf_mpeg_descr_linkage_population_id_mask, tvb, offset, 2, ENC_BIG_ENDIAN);
1204 if (end - offset > 0)
1205 proto_tree_add_item(tree, hf_mpeg_descr_linkage_private_data_byte, tvb, offset, end - offset, ENC_NA);
1208 /* 0x4D Short Event Descriptor */
1209 static int hf_mpeg_descr_short_event_lang_code = -1;
1210 static int hf_mpeg_descr_short_event_name_length = -1;
1211 static int hf_mpeg_descr_short_event_name_encoding = -1;
1212 static int hf_mpeg_descr_short_event_name = -1;
1213 static int hf_mpeg_descr_short_event_text_length = -1;
1214 static int hf_mpeg_descr_short_event_text_encoding = -1;
1215 static int hf_mpeg_descr_short_event_text = -1;
1218 proto_mpeg_descriptor_dissect_short_event(tvbuff_t *tvb, guint offset, proto_tree *tree)
1220 guint8 name_len, text_len;
1222 dvb_encoding_e encoding;
1224 proto_tree_add_item(tree, hf_mpeg_descr_short_event_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1227 name_len = tvb_get_guint8(tvb, offset);
1228 proto_tree_add_item(tree, hf_mpeg_descr_short_event_name_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1232 enc_len = dvb_analyze_string_charset(tvb, offset, name_len, &encoding);
1233 dvb_add_chartbl(tree, hf_mpeg_descr_short_event_name_encoding, tvb, offset, enc_len, encoding);
1234 proto_tree_add_item(tree, hf_mpeg_descr_short_event_name,
1235 tvb, offset+enc_len, name_len-enc_len, dvb_enc_to_item_enc(encoding));
1239 text_len = tvb_get_guint8(tvb, offset);
1240 proto_tree_add_item(tree, hf_mpeg_descr_short_event_text_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1244 enc_len = dvb_analyze_string_charset(tvb, offset, text_len, &encoding);
1245 dvb_add_chartbl(tree, hf_mpeg_descr_short_event_text_encoding, tvb, offset, enc_len, encoding);
1246 proto_tree_add_item(tree, hf_mpeg_descr_short_event_text,
1247 tvb, offset+enc_len, text_len-enc_len, dvb_enc_to_item_enc(encoding));
1251 /* 0x4E Extended Event Descriptor */
1252 static int hf_mpeg_descr_extended_event_descriptor_number = -1;
1253 static int hf_mpeg_descr_extended_event_last_descriptor_number = -1;
1254 static int hf_mpeg_descr_extended_event_lang_code = -1;
1255 static int hf_mpeg_descr_extended_event_length_of_items = -1;
1256 static int hf_mpeg_descr_extended_event_item_description_length = -1;
1257 static int hf_mpeg_descr_extended_event_item_description_char = -1;
1258 static int hf_mpeg_descr_extended_event_item_length = -1;
1259 static int hf_mpeg_descr_extended_event_item_char = -1;
1260 static int hf_mpeg_descr_extended_event_text_length = -1;
1261 static int hf_mpeg_descr_extended_event_text_encoding = -1;
1262 static int hf_mpeg_descr_extended_event_text = -1;
1264 #define MPEG_DESCR_EXTENDED_EVENT_DESCRIPTOR_NUMBER_MASK 0xF0
1265 #define MPEG_DESCR_EXTENDED_EVENT_LAST_DESCRIPTOR_NUMBER_MASK 0x0F
1267 static gint ett_mpeg_descriptor_extended_event_item = -1;
1270 proto_mpeg_descriptor_dissect_extended_event(tvbuff_t *tvb, guint offset, proto_tree *tree)
1273 guint8 items_len, item_descr_len, item_len, text_len;
1275 proto_tree *item_tree;
1277 dvb_encoding_e encoding;
1279 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_descriptor_number, tvb, offset, 1, ENC_BIG_ENDIAN);
1280 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_last_descriptor_number, tvb, offset, 1, ENC_BIG_ENDIAN);
1283 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1286 items_len = tvb_get_guint8(tvb, offset);
1287 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_length_of_items, tvb, offset, 1, ENC_BIG_ENDIAN);
1290 items_end = offset + items_len;
1292 while (offset < items_end) {
1293 item_tree = proto_tree_add_subtree(tree, tvb, offset, 0, ett_mpeg_descriptor_extended_event_item, NULL, "Item");
1295 item_descr_len = tvb_get_guint8(tvb, offset);
1296 proto_tree_add_item(item_tree, hf_mpeg_descr_extended_event_item_description_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1299 proto_tree_add_item(item_tree, hf_mpeg_descr_extended_event_item_description_char, tvb, offset, item_descr_len, ENC_ASCII|ENC_NA);
1300 offset += item_descr_len;
1302 item_len = tvb_get_guint8(tvb, offset);
1303 proto_tree_add_item(item_tree, hf_mpeg_descr_extended_event_item_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1306 proto_tree_add_item(item_tree, hf_mpeg_descr_extended_event_item_char, tvb, offset, item_len, ENC_ASCII|ENC_NA);
1310 text_len = tvb_get_guint8(tvb, offset);
1311 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_text_length, tvb, offset, 1, ENC_BIG_ENDIAN);
1315 enc_len = dvb_analyze_string_charset(tvb, offset, text_len, &encoding);
1316 dvb_add_chartbl(tree, hf_mpeg_descr_extended_event_text_encoding, tvb, offset, enc_len, encoding);
1317 proto_tree_add_item(tree, hf_mpeg_descr_extended_event_text,
1318 tvb, offset+enc_len, text_len-enc_len, dvb_enc_to_item_enc(encoding));
1323 /* 0x50 Component Descriptor */
1324 static int hf_mpeg_descr_component_reserved = -1;
1325 static int hf_mpeg_descr_component_stream_content = -1;
1326 static int hf_mpeg_descr_component_type = -1;
1327 static int hf_mpeg_descr_component_content_type = -1;
1328 static int hf_mpeg_descr_component_tag = -1;
1329 static int hf_mpeg_descr_component_lang_code = -1;
1330 static int hf_mpeg_descr_component_text = -1;
1332 #define MPEG_DESCR_COMPONENT_RESERVED_MASK 0xF0
1333 #define MPEG_DESCR_COMPONENT_STREAM_CONTENT_MASK 0x0F
1334 #define MPEG_DESCR_COMPONENT_CONTENT_TYPE_MASK 0x0FFF
1336 static gint ett_mpeg_descriptor_component_content_type = -1;
1338 static const value_string mpeg_descr_component_stream_content_vals[] = {
1340 { 0x01, "Video (MPEG-2)" },
1341 { 0x02, "Audio (MPEG-1 Layer 2)" },
1342 { 0x03, "EBU Data (Teletext, Subtitle, ...)" },
1343 { 0x04, "Audio (AC-3)" },
1344 { 0x05, "Video (H.264/AVC)" },
1345 { 0x06, "Audio (HE-AAC)" },
1346 { 0x07, "Audio (DTS)" },
1352 static const value_string mpeg_descr_component_content_type_vals[] = {
1354 { 0x0101, "MPEG-2 video, 4:3 aspect ratio, 25 Hz" },
1355 { 0x0102, "MPEG-2 video, 16:9 aspect ratio with pan vectors, 25 Hz" },
1356 { 0x0103, "MPEG-2 video, 16:9 aspect ratio without pan vectors, 25 Hz" },
1357 { 0x0104, "MPEG-2 video, > 16:9 aspect ratio, 25 Hz" },
1358 { 0x0105, "MPEG-2 video, 4:3 aspect ratio, 30 Hz" },
1359 { 0x0106, "MPEG-2 video, 16:9 aspect ratio with pan vectors, 30 Hz" },
1360 { 0x0107, "MPEG-2 video, 16:9 aspect ratio without pan vectors, 30 Hz" },
1361 { 0x0108, "MPEG-2 video, > 16:9 aspect ratio, 30 Hz" },
1362 { 0x0109, "MPEG-2 high definition video, 4:3 aspect ratio, 25 Hz" },
1363 { 0x010A, "MPEG-2 high definition video, 16:9 aspect ratio with pan vectors, 25 Hz" },
1364 { 0x010B, "MPEG-2 high definition video, 16:9 aspect ratio without pan vectors, 25 Hz" },
1365 { 0x010C, "MPEG-2 high definition video, > 16:9 aspect ratio, 25 Hz" },
1366 { 0x010D, "MPEG-2 high definition video, 4:3 aspect ratio, 30 Hz" },
1367 { 0x010E, "MPEG-2 high definition video, 16:9 aspect ratio with pan vectors, 30 Hz" },
1368 { 0x010F, "MPEG-2 high definition video, 16:9 aspect ratio without pan vectors, 30 Hz" },
1369 { 0x0110, "MPEG-2 high definition video, > 16:9 aspect ratio, 30 Hz" },
1370 { 0x0201, "MPEG-1 Layer 2 audio, single mono channel" },
1371 { 0x0202, "MPEG-1 Layer 2 audio, dual mono channel" },
1372 { 0x0203, "MPEG-1 Layer 2 audio, stereo" },
1373 { 0x0204, "MPEG-1 Layer 2 audio, multi-lingual, multi-channel" },
1374 { 0x0205, "MPEG-1 Layer 2 audio, surround sound" },
1375 { 0x0240, "MPEG-1 Layer 2 audio description for the visually impaired" },
1376 { 0x0241, "MPEG-1 Layer 2 audio for the hard of hearing" },
1377 { 0x0242, "receiver-mixed supplementary audio as per annex E of TS 101 154 [9]" },
1378 { 0x0247, "MPEG-1 Layer 2 audio, receiver mix audio description as per annex E of TS 101 154 [9]" },
1379 { 0x0248, "MPEG-1 Layer 2 audio, broadcaster mix audio description" },
1380 { 0x0301, "EBU Teletext subtitles" },
1381 { 0x0302, "associated EBU Teletext" },
1382 { 0x0303, "VBI data" },
1383 { 0x0310, "DVB subtitles (normal) with no monitor aspect ratio criticality" },
1384 { 0x0311, "DVB subtitles (normal) for display on 4:3 aspect ratio monitor" },
1385 { 0x0312, "DVB subtitles (normal) for display on 16:9 aspect ratio monitor" },
1386 { 0x0313, "DVB subtitles (normal) for display on 2.21:1 aspect ratio monitor" },
1387 { 0x0314, "DVB subtitles (normal) for display on a high definition monitor" },
1388 { 0x0320, "DVB subtitles (for the hard of hearing) with no monitor aspect ratio criticality" },
1389 { 0x0321, "DVB subtitles (for the hard of hearing) for display on 4:3 aspect ratio monitor" },
1390 { 0x0322, "DVB subtitles (for the hard of hearing) for display on 16:9 aspect ratio monitor" },
1391 { 0x0323, "DVB subtitles (for the hard of hearing) for display on 2.21:1 aspect ratio monitor" },
1392 { 0x0324, "DVB subtitles (for the hard of hearing) for display on a high definition monitor" },
1393 { 0x0330, "Open (in-vision) sign language interpretation for the deaf" },
1394 { 0x0331, "Closed sign language interpretation for the deaf" },
1395 { 0x0340, "video up-sampled from standard definition source material" },
1396 { 0x0501, "H.264/AVC standard definition video, 4:3 aspect ratio, 25 Hz" },
1397 { 0x0503, "H.264/AVC standard definition video, 16:9 aspect ratio, 25 Hz" },
1398 { 0x0504, "H.264/AVC standard definition video, > 16:9 aspect ratio, 25 Hz" },
1399 { 0x0505, "H.264/AVC standard definition video, 4:3 aspect ratio, 30 Hz" },
1400 { 0x0507, "H.264/AVC standard definition video, 16:9 aspect ratio, 30 Hz" },
1401 { 0x0508, "H.264/AVC standard definition video, > 16:9 aspect ratio, 30 Hz" },
1402 { 0x050B, "H.264/AVC high definition video, 16:9 aspect ratio, 25 Hz" },
1403 { 0x050C, "H.264/AVC high definition video, > 16:9 aspect ratio, 25 Hz" },
1404 { 0x050F, "H.264/AVC high definition video, 16:9 aspect ratio, 30 Hz" },
1405 { 0x0510, "H.264/AVC high definition video, > 16:9 aspect ratio, 30 Hz" },
1406 { 0x0601, "HE-AAC audio, single mono channel" },
1407 { 0x0603, "HE-AAC audio, stereo" },
1408 { 0x0605, "HE-AAC audio, surround sound" },
1409 { 0x0640, "HE-AAC audio description for the visually impaired" },
1410 { 0x0641, "HE-AAC audio for the hard of hearing" },
1411 { 0x0642, "HE-AAC receiver-mixed supplementary audio as per annex E of TS 101 154 [9]" },
1412 { 0x0643, "HE-AAC v2 audio, stereo" },
1413 { 0x0644, "HE-AAC v2 audio description for the visually impaired" },
1414 { 0x0645, "HE-AAC v2 audio for the hard of hearing" },
1415 { 0x0646, "HE-AAC v2 receiver-mixed supplementary audio as per annex E of TS 101 154 [9]" },
1416 { 0x0647, "HE-AAC receiver mix audio description for the visually impaired" },
1417 { 0x0648, "HE-AAC broadcaster mix audio description for the visually impaired" },
1418 { 0x0649, "HE-AAC v2 receiver mix audio description for the visually impaired" },
1419 { 0x064A, "HE-AAC v2 broadcaster mix audio description for the visually impaired" },
1420 { 0x0801, "DVB SRM data" },
1421 { 0x0900, "HEVC Main Profile high definition video, 50 Hz" },
1422 { 0x0901, "HEVC Main 10 Profile high definition video, 50 Hz" },
1423 { 0x0902, "HEVC Main Profile high definition video, 60 Hz" },
1424 { 0x0903, "HEVC Main 10 Profile high definition video, 60 Hz" },
1425 { 0x0904, "HEVC ultra high definition video" },
1429 static value_string_ext mpeg_descr_component_content_type_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_component_content_type_vals);
1432 proto_mpeg_descriptor_dissect_component(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1436 proto_tree *content_type_tree;
1438 proto_tree_add_item(tree, hf_mpeg_descr_component_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
1440 cti = proto_tree_add_item(tree, hf_mpeg_descr_component_content_type, tvb, offset, 2, ENC_BIG_ENDIAN);
1441 content_type_tree = proto_item_add_subtree(cti, ett_mpeg_descriptor_component_content_type);
1443 proto_tree_add_item(content_type_tree, hf_mpeg_descr_component_stream_content, tvb, offset, 1, ENC_BIG_ENDIAN);
1446 proto_tree_add_item(content_type_tree, hf_mpeg_descr_component_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1449 proto_tree_add_item(tree, hf_mpeg_descr_component_tag, tvb, offset, 1, ENC_BIG_ENDIAN);
1452 proto_tree_add_item(tree, hf_mpeg_descr_component_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1456 proto_tree_add_item(tree, hf_mpeg_descr_component_text, tvb, offset, len - offset, ENC_ASCII|ENC_NA);
1459 /* 0x52 Stream Identifier Descriptor */
1460 static int hf_mpeg_descr_stream_identifier_component_tag = -1;
1463 proto_mpeg_descriptor_dissect_stream_identifier(tvbuff_t *tvb, guint offset, proto_tree *tree)
1465 proto_tree_add_item(tree, hf_mpeg_descr_stream_identifier_component_tag, tvb, offset, 1, ENC_BIG_ENDIAN);
1468 /* 0x53 CA Identifier Descriptor */
1469 static int hf_mpeg_descr_ca_identifier_system_id = -1;
1472 proto_mpeg_descriptor_dissect_ca_identifier(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1474 guint end = offset + len;
1476 while (offset < end) {
1477 proto_tree_add_item(tree, hf_mpeg_descr_ca_identifier_system_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1483 /* 0x54 Content Descriptor */
1484 static int hf_mpeg_descr_content_nibble = -1;
1485 static int hf_mpeg_descr_content_nibble_level_1 = -1;
1486 static int hf_mpeg_descr_content_nibble_level_2 = -1;
1487 static int hf_mpeg_descr_content_user_byte = -1;
1489 #define MPEG_DESCR_CONTENT_NIBBLE_LEVEL_1_MASK 0xF0
1490 #define MPEG_DESCR_CONTENT_NIBBLE_LEVEL_2_MASK 0x0F
1492 static gint ett_mpeg_descriptor_content_nibble = -1;
1494 static const value_string mpeg_descr_content_nibble_vals[] = {
1496 { 0x10, "movie/drama (general)" },
1497 { 0x11, "detective/thriller" },
1498 { 0x12, "adventure/western/war" },
1499 { 0x13, "science fiction/fantasy/horror" },
1501 { 0x15, "soap/melodrama/folkloric" },
1502 { 0x16, "romance" },
1503 { 0x17, "serious/classical/religious/historical movie/drama" },
1504 { 0x18, "adult movie/drama" },
1505 { 0x1F, "user defined (movie/drama)" },
1507 { 0x20, "news/current affairs (general)" },
1508 { 0x21, "news/weather report" },
1509 { 0x22, "news magazine" },
1510 { 0x23, "documentary" },
1511 { 0x24, "discussion/interview/debate" },
1512 { 0x2F, "user defined (news/current affairs)" },
1514 { 0x30, "show/game show (general)" },
1515 { 0x31, "game show/quiz/contest" },
1516 { 0x32, "variety show" },
1517 { 0x33, "talk show" },
1518 { 0x3F, "user defined (show/game show)" },
1520 { 0x40, "sports (general)" },
1521 { 0x41, "special events (Olympic Games, World Cup, etc.)" },
1522 { 0x42, "sports magazines" },
1523 { 0x43, "football/soccer" },
1524 { 0x44, "tennis/squash" },
1525 { 0x45, "team sports (excluding football)" },
1526 { 0x46, "athletics" },
1527 { 0x47, "motor sport" },
1528 { 0x48, "water sport" },
1529 { 0x49, "winter sports" },
1530 { 0x4A, "equestrian" },
1531 { 0x4B, "martial sports" },
1532 { 0x4F, "user defined (sports)" },
1534 { 0x50, "children's/youth programmes (general)" },
1535 { 0x51, "pre-school children's programmes" },
1536 { 0x52, "entertainment programmes for 6 to14" },
1537 { 0x53, "entertainment programmes for 10 to 16" },
1538 { 0x54, "informational/educational/school programmes" },
1539 { 0x55, "cartoons/puppets" },
1540 { 0x5F, "user defined (children's/youth programmes)" },
1542 { 0x60, "music/ballet/dance (general)" },
1543 { 0x61, "rock/pop" },
1544 { 0x62, "serious music/classical music" },
1545 { 0x63, "folk/traditional music" },
1547 { 0x65, "musical/opera" },
1549 { 0x6F, "user defined (music/ballet/dance)" },
1551 { 0x70, "arts/culture (without music, general)" },
1552 { 0x71, "performing arts" },
1553 { 0x72, "fine arts" },
1554 { 0x73, "religion" },
1555 { 0x74, "popular culture/traditional arts" },
1556 { 0x75, "literature" },
1557 { 0x76, "film/cinema" },
1558 { 0x77, "experimental film/video" },
1559 { 0x78, "broadcasting/press" },
1560 { 0x79, "new media" },
1561 { 0x7A, "arts/culture magazines" },
1562 { 0x7B, "fashion" },
1563 { 0x7F, "user defined (arts/culture)" },
1565 { 0x80, "social/political issues/economics (general)" },
1566 { 0x81, "magazines/reports/documentary" },
1567 { 0x82, "economics/social advisory" },
1568 { 0x83, "remarkable people" },
1569 { 0x8F, "user defined (social/political issues/economics)" },
1571 { 0x90, "education/science/factual topics (general)" },
1572 { 0x91, "nature/animals/environment" },
1573 { 0x92, "technology/natural sciences" },
1574 { 0x93, "medicine/physiology/psychology" },
1575 { 0x94, "foreign countries/expeditions" },
1576 { 0x95, "social/spiritual sciences" },
1577 { 0x96, "further education" },
1578 { 0x97, "languages" },
1579 { 0x9F, "user defined (education/science/factual topics)" },
1581 { 0xA0, "leisure hobbies (general)" },
1582 { 0xA1, "tourism/travel" },
1583 { 0xA2, "handicraft" },
1584 { 0xA3, "motoring" },
1585 { 0xA4, "fitness and health" },
1586 { 0xA5, "cooking" },
1587 { 0xA6, "advertisement/shopping" },
1588 { 0xA7, "gardening" },
1589 { 0xAF, "user defined (leisure hobbies)" },
1591 { 0xB0, "original language" },
1592 { 0xB1, "black and white" },
1593 { 0xB2, "unpublished" },
1594 { 0xB3, "live broadcast" },
1595 { 0xBF, "user defined (special characteristics)" },
1599 static value_string_ext mpeg_descr_content_nibble_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_content_nibble_vals);
1601 static const value_string mpeg_descr_content_nibble_level_1_vals[] = {
1603 { 0x1, "Movie/Drama" },
1604 { 0x2, "News/Current affairs" },
1605 { 0x3, "Show/Game show" },
1607 { 0x5, "Children's/Youth programmes" },
1608 { 0x6, "Music/Ballet/Dance" },
1609 { 0x7, "Arts/Culture (without music)" },
1610 { 0x8, "Social/Political issues/Economics" },
1611 { 0x9, "Education/Science/Factual topics" },
1612 { 0xA, "Leisure hobbies" },
1613 { 0xB, "Special characteristics" },
1617 static value_string_ext mpeg_descr_content_nibble_level_1_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_content_nibble_level_1_vals);
1620 proto_mpeg_descriptor_dissect_content(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1623 proto_tree *nibble_tree;
1625 guint end = offset + len;
1627 while (offset < end) {
1628 ni = proto_tree_add_item(tree, hf_mpeg_descr_content_nibble, tvb, offset, 1, ENC_BIG_ENDIAN);
1629 nibble_tree = proto_item_add_subtree(ni, ett_mpeg_descriptor_content_nibble);
1631 proto_tree_add_item(nibble_tree, hf_mpeg_descr_content_nibble_level_1, tvb, offset, 1, ENC_BIG_ENDIAN);
1632 proto_tree_add_item(nibble_tree, hf_mpeg_descr_content_nibble_level_2, tvb, offset, 1, ENC_BIG_ENDIAN);
1635 proto_tree_add_item(tree, hf_mpeg_descr_content_user_byte, tvb, offset, 1, ENC_BIG_ENDIAN);
1641 /* 0x55 Parental Rating Descriptor */
1642 static int hf_mpeg_descr_parental_rating_country_code = -1;
1643 static int hf_mpeg_descr_parental_rating_rating = -1;
1645 static const value_string mpeg_descr_parental_rating_vals[] = {
1646 { 0x00, "Undefined" },
1647 { 0x01, "Minimum 4 year old" },
1648 { 0x02, "Minimum 5 year old" },
1649 { 0x03, "Minimum 6 year old" },
1650 { 0x04, "Minimum 7 year old" },
1651 { 0x05, "Minimum 8 year old" },
1652 { 0x06, "Minimum 9 year old" },
1653 { 0x07, "Minimum 10 year old" },
1654 { 0x08, "Minimum 11 year old" },
1655 { 0x09, "Minimum 12 year old" },
1656 { 0x0A, "Minimum 13 year old" },
1657 { 0x0B, "Minimum 14 year old" },
1658 { 0x0C, "Minimum 15 year old" },
1659 { 0x0D, "Minimum 16 year old" },
1660 { 0x0E, "Minimum 17 year old" },
1661 { 0x0F, "Minimum 18 year old" },
1665 static value_string_ext mpeg_descr_parental_rating_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_parental_rating_vals);
1669 proto_mpeg_descriptor_dissect_parental_rating(tvbuff_t *tvb, guint offset, proto_tree *tree)
1671 proto_tree_add_item(tree, hf_mpeg_descr_parental_rating_country_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1674 proto_tree_add_item(tree, hf_mpeg_descr_parental_rating_rating, tvb, offset, 1, ENC_BIG_ENDIAN);
1677 /* 0x56 Teletext Descriptor */
1678 static int hf_mpeg_descr_teletext_lang_code = -1;
1679 static int hf_mpeg_descr_teletext_type = -1;
1680 static int hf_mpeg_descr_teletext_magazine_number = -1;
1681 static int hf_mpeg_descr_teletext_page_number = -1;
1683 #define MPEG_DESCR_TELETEXT_TYPE_MASK 0xF8
1684 #define MPEG_DESCR_TELETEXT_MAGAZINE_NUMBER_MASK 0x07
1686 static const value_string mpeg_descr_teletext_type_vals[] = {
1687 { 0x00, "Reserved" },
1688 { 0x01, "Initial Teletext Page" },
1689 { 0x02, "Teletext Subtitle Page" },
1690 { 0x03, "Additional Information Page" },
1691 { 0x04, "Programme Schedule Page" },
1692 { 0x05, "Teletext Subtitle Page for hearing impaired people" },
1699 proto_mpeg_descriptor_dissect_teletext(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1701 guint end = offset + len;
1703 while (offset < end) {
1704 proto_tree_add_item(tree, hf_mpeg_descr_teletext_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1707 proto_tree_add_item(tree, hf_mpeg_descr_teletext_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1708 proto_tree_add_item(tree, hf_mpeg_descr_teletext_magazine_number, tvb, offset, 1, ENC_BIG_ENDIAN);
1711 proto_tree_add_item(tree, hf_mpeg_descr_teletext_page_number, tvb, offset, 1, ENC_BIG_ENDIAN);
1716 /* 0x58 Local Time Offset Descriptor */
1717 static int hf_mpeg_descr_local_time_offset_country_code = -1;
1718 static int hf_mpeg_descr_local_time_offset_region_id = -1;
1719 static int hf_mpeg_descr_local_time_offset_reserved = -1;
1720 static int hf_mpeg_descr_local_time_offset_polarity = -1;
1721 static int hf_mpeg_descr_local_time_offset_offset = -1;
1722 static int hf_mpeg_descr_local_time_offset_time_of_change = -1;
1723 static int hf_mpeg_descr_local_time_offset_next_time_offset = -1;
1725 #define MPEG_DESCR_LOCAL_TIME_OFFSET_COUNTRY_REGION_ID_MASK 0xFC
1726 #define MPEG_DESCR_LOCAL_TIME_OFFSET_RESERVED_MASK 0x02
1727 #define MPEG_DESCR_LOCAL_TIME_OFFSET_POLARITY 0x01
1729 static const value_string mpeg_descr_local_time_offset_polarity_vals[] = {
1730 { 0x0, "Positive (local time ahead of UTC)" },
1731 { 0x1, "Negative (local time behind UTC)" },
1737 proto_mpeg_descriptor_dissect_local_time_offset(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1739 guint end = offset + len;
1741 nstime_t local_time_offset, time_of_change, next_time_offset;
1743 while (offset < end) {
1744 proto_tree_add_item(tree, hf_mpeg_descr_local_time_offset_country_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1747 proto_tree_add_item(tree, hf_mpeg_descr_local_time_offset_region_id, tvb, offset, 1, ENC_BIG_ENDIAN);
1748 proto_tree_add_item(tree, hf_mpeg_descr_local_time_offset_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
1749 proto_tree_add_item(tree, hf_mpeg_descr_local_time_offset_polarity, tvb, offset, 1, ENC_BIG_ENDIAN);
1752 hour = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset));
1753 min = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1));
1754 nstime_set_zero(&local_time_offset);
1755 local_time_offset.secs = hour*60*60 + min*60;
1756 proto_tree_add_time_format_value(tree, hf_mpeg_descr_local_time_offset_offset,
1757 tvb, offset, 2, &local_time_offset, "%02d:%02d", hour, min);
1761 if (packet_mpeg_sect_mjd_to_utc_time(tvb, offset, &time_of_change) < 0) {
1762 proto_tree_add_time_format_value(tree, hf_mpeg_descr_local_time_offset_time_of_change, tvb, offset, 5, &time_of_change, "Unparseable time");
1764 proto_tree_add_time(tree, hf_mpeg_descr_local_time_offset_time_of_change, tvb, offset, 5, &time_of_change);
1768 hour = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset));
1769 min = MPEG_SECT_BCD44_TO_DEC(tvb_get_guint8(tvb, offset+1));
1770 nstime_set_zero(&next_time_offset);
1771 next_time_offset.secs = hour*60*60 + min*60;
1772 proto_tree_add_time_format_value(tree, hf_mpeg_descr_local_time_offset_next_time_offset,
1773 tvb, offset, 2, &next_time_offset, "%02d:%02d", hour, min);
1778 /* 0x59 Subtitling Descriptor */
1779 static int hf_mpeg_descr_subtitling_lang_code = -1;
1780 static int hf_mpeg_descr_subtitling_type = -1;
1781 static int hf_mpeg_descr_subtitling_composition_page_id = -1;
1782 static int hf_mpeg_descr_subtitling_ancillary_page_id = -1;
1785 static const value_string mpeg_descr_subtitling_type_vals[] = {
1786 { 0x01, "EBU Teletext subtitles" },
1787 { 0x02, "associated EBU Teletext" },
1788 { 0x03, "VBI data" },
1789 { 0x10, "DVB subtitles (normal) with no monitor aspect ratio criticality" },
1790 { 0x11, "DVB subtitles (normal) for display on 4:3 aspect ratio monitor" },
1791 { 0x12, "DVB subtitles (normal) for display on 16:9 aspect ratio monitor" },
1792 { 0x13, "DVB subtitles (normal) for display on 2.21:1 aspect ratio monitor" },
1793 { 0x14, "DVB subtitles (normal) for display on a high definition monitor" },
1794 { 0x20, "DVB subtitles (for the hard of hearing) with no monitor aspect ratio criticality" },
1795 { 0x21, "DVB subtitles (for the hard of hearing) for display on 4:3 aspect ratio monitor" },
1796 { 0x22, "DVB subtitles (for the hard of hearing) for display on 16:9 aspect ratio monitor" },
1797 { 0x23, "DVB subtitles (for the hard of hearing) for display on 2.21:1 aspect ratio monitor" },
1798 { 0x24, "DVB subtitles (for the hard of hearing) for display on a high definition monitor" },
1799 { 0x30, "Open (in-vision) sign language interpretation for the deaf" },
1800 { 0x31, "Closed sign language interpretation for the deaf" },
1801 { 0x40, "video up-sampled from standard definition source material" },
1805 static value_string_ext mpeg_descr_subtitling_type_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_subtitling_type_vals);
1808 proto_mpeg_descriptor_dissect_subtitling(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
1810 guint end = offset + len;
1812 while (offset < end) {
1813 proto_tree_add_item(tree, hf_mpeg_descr_subtitling_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
1816 proto_tree_add_item(tree, hf_mpeg_descr_subtitling_type, tvb, offset, 1, ENC_BIG_ENDIAN);
1819 proto_tree_add_item(tree, hf_mpeg_descr_subtitling_composition_page_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1822 proto_tree_add_item(tree, hf_mpeg_descr_subtitling_ancillary_page_id, tvb, offset, 2, ENC_BIG_ENDIAN);
1828 /* 0x5A Terrestrial Delivery System Descriptor */
1829 static int hf_mpeg_descr_terrestrial_delivery_centre_frequency = -1;
1830 static int hf_mpeg_descr_terrestrial_delivery_bandwidth = -1;
1831 static int hf_mpeg_descr_terrestrial_delivery_priority = -1;
1832 static int hf_mpeg_descr_terrestrial_delivery_time_slicing_indicator = -1;
1833 static int hf_mpeg_descr_terrestrial_delivery_mpe_fec_indicator = -1;
1834 static int hf_mpeg_descr_terrestrial_delivery_reserved1 = -1;
1835 static int hf_mpeg_descr_terrestrial_delivery_constellation = -1;
1836 static int hf_mpeg_descr_terrestrial_delivery_hierarchy_information = -1;
1837 static int hf_mpeg_descr_terrestrial_delivery_code_rate_hp_stream = -1;
1838 static int hf_mpeg_descr_terrestrial_delivery_code_rate_lp_stream = -1;
1839 static int hf_mpeg_descr_terrestrial_delivery_guard_interval = -1;
1840 static int hf_mpeg_descr_terrestrial_delivery_transmission_mode = -1;
1841 static int hf_mpeg_descr_terrestrial_delivery_other_frequency_flag = -1;
1842 static int hf_mpeg_descr_terrestrial_delivery_reserved2 = -1;
1844 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_BANDWIDTH_MASK 0xE0
1845 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_PRIORITY_MASK 0x10
1846 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_TIME_SLICING_INDICATOR_MASK 0x08
1847 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_MPE_FEC_INDICATOR_MASK 0x04
1848 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_RESERVED1_MASK 0x03
1849 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_CONSTELLATION_MASK 0xC0
1850 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_HIERARCHY_INFORMATION_MASK 0x38
1851 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_CODE_RATE_HP_STREAM_MASK 0x07
1852 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_CODE_RATE_LP_STREAM_MASK 0xE0
1853 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_GUARD_INTERVAL_MASK 0x18
1854 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_TRANSMISSION_MODE_MASK 0x06
1855 #define MPEG_DESCR_TERRESTRIAL_DELIVERY_OTHER_FREQUENCY_FLAG_MASK 0x01
1857 static const value_string mpeg_descr_terrestrial_delivery_bandwidth_vals[] = {
1866 static const value_string mpeg_descr_terrestrial_delivery_priority_vals[] = {
1867 { 0x0, "Low Priority" },
1868 { 0x1, "High Priority (or N/A if not hierarchical stream)" },
1873 static const value_string mpeg_descr_terrestrial_delivery_time_slicing_indicator_vals[] = {
1874 { 0x0, "At least one elementary stream uses Time Slicing" },
1875 { 0x1, "Time Slicing not used" },
1880 static const value_string mpeg_descr_terrestrial_delivery_mpe_fec_indicator_vals[] = {
1881 { 0x0, "At least one elementary stream uses MPE-FEC" },
1882 { 0x1, "MPE-FEC not used" },
1887 static const value_string mpeg_descr_terrestrial_delivery_constellation_vals[] = {
1895 static const value_string mpeg_descr_terrestrial_delivery_hierarchy_information_vals[] = {
1896 { 0x0, "Non-hierarchical, native interleaver" },
1897 { 0x1, "alpha = 1, native interleaver" },
1898 { 0x2, "alpha = 2, native interleaver" },
1899 { 0x3, "alpha = 4, native interleaver" },
1900 { 0x4, "Non-hierarchical, in-depth interleaver" },
1901 { 0x5, "alpha = 1, in-depth interleaver" },
1902 { 0x6, "alpha = 2, in-depth interleaver" },
1903 { 0x7, "alpha = 4, in-depth interleaver" },
1908 static const value_string mpeg_descr_terrestrial_delivery_code_rate_vals[] = {
1909 { 0x0, "1/2 convolutional code rate" },
1910 { 0x1, "2/3 convolutional code rate" },
1911 { 0x2, "3/4 convolutional code rate" },
1912 { 0x3, "5/6 convolutional code rate" },
1913 { 0x4, "7/8 convolutional code rate" },
1918 static const value_string mpeg_descr_terrestrial_delivery_guard_interval_vals[] = {
1927 static const value_string mpeg_descr_terrestrial_delivery_other_frequency_flag_vals[] = {
1928 { 0x0, "No other frequency is in use" },
1929 { 0x1, "One or more frequencies are in use" },
1934 static const value_string mpeg_descr_terrestrial_delivery_transmission_mode_vals[] = {
1943 proto_mpeg_descriptor_dissect_terrestrial_delivery(tvbuff_t *tvb, guint offset, proto_tree *tree)
1945 guint64 centre_freq;
1947 /* the descriptor stores the centre frequency in units of 10Hz (so
1948 that they can get away with 32bits), we're using Hz here */
1949 centre_freq = tvb_get_ntohl(tvb, offset) * 10;
1951 proto_tree_add_uint64_format_value(tree, hf_mpeg_descr_terrestrial_delivery_centre_frequency, tvb, offset, 4,
1952 centre_freq, "%d.%06d MHz", (guint)centre_freq/(1000*1000), (guint)centre_freq%(1000*1000));
1955 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_bandwidth, tvb, offset, 1, ENC_BIG_ENDIAN);
1956 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_priority, tvb, offset, 1, ENC_BIG_ENDIAN);
1957 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_time_slicing_indicator, tvb, offset, 1, ENC_BIG_ENDIAN);
1958 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_mpe_fec_indicator, tvb, offset, 1, ENC_BIG_ENDIAN);
1959 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_reserved1, tvb, offset, 1, ENC_BIG_ENDIAN);
1962 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_constellation, tvb, offset, 1, ENC_BIG_ENDIAN);
1963 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_hierarchy_information, tvb, offset, 1, ENC_BIG_ENDIAN);
1964 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_code_rate_hp_stream, tvb, offset, 1, ENC_BIG_ENDIAN);
1967 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_code_rate_lp_stream, tvb, offset, 1, ENC_BIG_ENDIAN);
1968 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_guard_interval, tvb, offset, 1, ENC_BIG_ENDIAN);
1969 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_transmission_mode, tvb, offset, 1, ENC_BIG_ENDIAN);
1970 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_other_frequency_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
1973 proto_tree_add_item(tree, hf_mpeg_descr_terrestrial_delivery_reserved2, tvb, offset, 4, ENC_BIG_ENDIAN);
1978 /* 0x5F Private Data Specifier */
1979 static int hf_mpeg_descr_private_data_specifier_id = -1;
1981 #define PRIVATE_DATA_SPECIFIER_RESERVED 0x00000000
1982 #define PRIVATE_DATA_SPECIFIER_NORDIG 0x00000029
1983 #define PRIVATE_DATA_SPECIFIER_CIPLUS_LLP 0x00000040
1984 #define PRIVATE_DATA_SPECIFIER_EUTELSAT_SA 0x0000055F
1986 static const value_string mpeg_descr_data_specifier_id_vals[] = {
1987 { PRIVATE_DATA_SPECIFIER_RESERVED, "reserved" },
1988 { PRIVATE_DATA_SPECIFIER_NORDIG, "NorDig" },
1989 { PRIVATE_DATA_SPECIFIER_CIPLUS_LLP, "CI+ LLP" },
1990 { PRIVATE_DATA_SPECIFIER_EUTELSAT_SA, "Eutelsat S.A." },
1991 /* See dvbservices.com for complete and current list */
1997 proto_mpeg_descriptor_dissect_private_data_specifier(tvbuff_t *tvb, guint offset, proto_tree *tree)
1999 proto_tree_add_item(tree, hf_mpeg_descr_private_data_specifier_id, tvb, offset, 4, ENC_BIG_ENDIAN);
2002 /* 0x64 Data Broadcast Descriptor */
2003 static int hf_mpeg_descr_data_bcast_bcast_id = -1;
2004 static int hf_mpeg_descr_data_bcast_component_tag = -1;
2005 static int hf_mpeg_descr_data_bcast_selector_len = -1;
2006 static int hf_mpeg_descr_data_bcast_selector_bytes = -1;
2007 static int hf_mpeg_descr_data_bcast_lang_code = -1;
2008 static int hf_mpeg_descr_data_bcast_text_len = -1;
2009 static int hf_mpeg_descr_data_bcast_text = -1;
2011 static const value_string mpeg_descr_data_bcast_id_vals[] = {
2013 { 0x0001, "Data pipe" },
2014 { 0x0002, "Asynchronous data stream" },
2015 { 0x0003, "Synchronous data stream" },
2016 { 0x0004, "Synchronised data stream" },
2017 { 0x0005, "Multi protocol encapsulation" },
2018 { 0x0006, "Data Carousel" },
2019 { 0x0007, "Object Carousel" },
2020 { 0x0008, "DVB ATM streams" },
2021 { 0x0009, "Higher Protocols based on asynchronous data streams" },
2022 { 0x000A, "System Software Update service" },
2023 { 0x000B, "IP/MAC Notification service" },
2024 { 0x00F0, "MHP Object Carousel" },
2025 { 0x00F1, "MHP Multiprotocol Encapsulation" },
2026 { 0x0122, "CI+ Data Carousel" },
2027 { 0x0123, "HbbTV Carousel" },
2028 /* See dvbservices.com for complete and current list */
2032 /* global variable that's shared e.g. with DVB-CI */
2033 value_string_ext mpeg_descr_data_bcast_id_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_data_bcast_id_vals);
2036 proto_mpeg_descriptor_dissect_data_bcast(tvbuff_t *tvb, guint offset, proto_tree *tree)
2039 guint8 selector_len, text_len;
2041 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_bcast_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2044 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_component_tag, tvb, offset, 1, ENC_BIG_ENDIAN);
2047 selector_len = tvb_get_guint8(tvb, offset);
2048 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_selector_len, tvb, offset, 1, ENC_BIG_ENDIAN);
2051 if (selector_len > 0) {
2052 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_selector_bytes, tvb, offset, selector_len, ENC_NA);
2053 offset += selector_len;
2056 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
2059 text_len = tvb_get_guint8(tvb, offset);
2060 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_text_len, tvb, offset, 1, ENC_BIG_ENDIAN);
2064 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_text, tvb, offset, text_len, ENC_ASCII|ENC_NA);
2067 /* 0x66 Data Broadcast ID Descriptor */
2068 static int hf_mpeg_descr_data_bcast_id_bcast_id = -1;
2069 static int hf_mpeg_descr_data_bcast_id_id_selector_bytes = -1;
2072 proto_mpeg_descriptor_dissect_data_bcast_id(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2074 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_id_bcast_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2078 proto_tree_add_item(tree, hf_mpeg_descr_data_bcast_id_id_selector_bytes, tvb, offset, len - 2, ENC_NA);
2081 /* 0x6A AC-3 Descriptor */
2082 static int hf_mpeg_descr_ac3_component_type_flag = -1;
2083 static int hf_mpeg_descr_ac3_bsid_flag = -1;
2084 static int hf_mpeg_descr_ac3_mainid_flag = -1;
2085 static int hf_mpeg_descr_ac3_asvc_flag = -1;
2086 static int hf_mpeg_descr_ac3_reserved = -1;
2087 static int hf_mpeg_descr_ac3_component_type_reserved_flag = -1;
2088 static int hf_mpeg_descr_ac3_component_type_full_service_flag = -1;
2089 static int hf_mpeg_descr_ac3_component_type_service_type_flags = -1;
2090 static int hf_mpeg_descr_ac3_component_type_number_of_channels_flags = -1;
2091 static int hf_mpeg_descr_ac3_bsid = -1;
2092 static int hf_mpeg_descr_ac3_mainid = -1;
2093 static int hf_mpeg_descr_ac3_asvc = -1;
2094 static int hf_mpeg_descr_ac3_additional_info = -1;
2096 static gint ett_mpeg_descriptor_ac3_component_type = -1;
2098 #define MPEG_DESCR_AC3_COMPONENT_TYPE_FLAG_MASK 0x80
2099 #define MPEG_DESCR_AC3_BSID_FLAG_MASK 0x40
2100 #define MPEG_DESCR_AC3_MAINID_FLAG_MASK 0x20
2101 #define MPEG_DESCR_AC3_ASVC_FLAG_MASK 0x10
2102 #define MPEG_DESCR_AC3_RESERVED_MASK 0x0F
2104 #define MPEG_DESCR_AC3_COMPONENT_TYPE_RESERVED_FLAG_MASK 0x80
2105 #define MPEG_DESCR_AC3_COMPONENT_TYPE_FULL_SERVICE_FLAG_MASK 0x40
2106 #define MPEG_DESCR_AC3_COMPONENT_TYPE_SERVICE_TYPE_FLAGS_MASK 0x38
2107 #define MPEG_DESCR_AC3_COMPONENT_TYPE_NUMBER_OF_CHANNELS_FLAGS 0x07
2109 static const value_string mpeg_descr_ac3_component_type_flag_vals[] = {
2110 { 0x0, "Component type field not included" },
2111 { 0x1, "Component type field included" },
2116 static const value_string mpeg_descr_ac3_bsid_flag_vals[] = {
2117 { 0x0, "BSID field not included" },
2118 { 0x1, "BSID field included" },
2123 static const value_string mpeg_descr_ac3_mainid_flag_vals[] = {
2124 { 0x0, "Main ID field not included" },
2125 { 0x1, "Main ID field included" },
2130 static const value_string mpeg_descr_ac3_asvc_flag_vals[] = {
2131 { 0x0, "ASVC field not included" },
2132 { 0x1, "ASVC field included" },
2137 static const value_string mpeg_descr_ac3_component_type_full_service_flag_vals[] = {
2138 { 0x0, "Decoded audio stream is intended to be combined with another decoded audio stream" },
2139 { 0x1, "Decoded audio stream is a full service" },
2144 static const value_string mpeg_descr_ac3_component_type_service_type_flags_vals[] = {
2145 { 0x0, "Complete Main (CM)" },
2146 { 0x1, "Music and effects (ME)" },
2147 { 0x2, "Visually impaired (VI)" },
2148 { 0x3, "Hearing impaired (HI)" },
2149 { 0x4, "Dialogue (D)" },
2150 { 0x5, "Commentary (C)" },
2151 { 0x6, "Emergency (E)" },
2152 { 0x7, "Voiceover (VO) if Full Service Flag is 0, else Karaoke" },
2157 static const value_string mpeg_descr_ac3_component_type_number_of_channels_flags_vals[] = {
2159 { 0x1, "1+1 Mode" },
2160 { 0x2, "2 Channel (stereo)" },
2161 { 0x3, "2 Channel Dolby surround encoded (stereo)" },
2162 { 0x4, "Multichannel audio (> 2 channels)" },
2168 proto_mpeg_descriptor_dissect_ac3(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2170 guint end = offset + len;
2171 guint8 flags, component_type;
2173 proto_tree *component_type_tree;
2175 flags = tvb_get_guint8(tvb, offset);
2176 proto_tree_add_item(tree, hf_mpeg_descr_ac3_component_type_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2177 proto_tree_add_item(tree, hf_mpeg_descr_ac3_bsid_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2178 proto_tree_add_item(tree, hf_mpeg_descr_ac3_mainid_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2179 proto_tree_add_item(tree, hf_mpeg_descr_ac3_asvc_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2180 proto_tree_add_item(tree, hf_mpeg_descr_ac3_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2183 if (flags & MPEG_DESCR_AC3_COMPONENT_TYPE_FLAG_MASK) {
2184 component_type = tvb_get_guint8(tvb, offset);
2185 component_type_tree = proto_tree_add_subtree_format(tree, tvb, offset, 3,
2186 ett_mpeg_descriptor_ac3_component_type, NULL, "Component Type 0x%02x", component_type);
2187 proto_tree_add_item(component_type_tree, hf_mpeg_descr_ac3_component_type_reserved_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2188 proto_tree_add_item(component_type_tree, hf_mpeg_descr_ac3_component_type_full_service_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2189 proto_tree_add_item(component_type_tree, hf_mpeg_descr_ac3_component_type_service_type_flags, tvb, offset, 1, ENC_BIG_ENDIAN);
2190 proto_tree_add_item(component_type_tree, hf_mpeg_descr_ac3_component_type_number_of_channels_flags, tvb, offset, 1, ENC_BIG_ENDIAN);
2194 if (flags & MPEG_DESCR_AC3_BSID_FLAG_MASK) {
2195 proto_tree_add_item(tree, hf_mpeg_descr_ac3_bsid, tvb, offset, 1, ENC_BIG_ENDIAN);
2199 if (flags & MPEG_DESCR_AC3_MAINID_FLAG_MASK) {
2200 proto_tree_add_item(tree, hf_mpeg_descr_ac3_mainid, tvb, offset, 1, ENC_BIG_ENDIAN);
2204 if (flags & MPEG_DESCR_AC3_ASVC_FLAG_MASK) {
2205 proto_tree_add_item(tree, hf_mpeg_descr_ac3_asvc, tvb, offset, 1, ENC_BIG_ENDIAN);
2210 proto_tree_add_item(tree, hf_mpeg_descr_ac3_additional_info, tvb, offset, end - offset, ENC_NA);
2213 /* 0x6F Application Signalling Descriptor */
2214 static int hf_mpeg_descr_app_sig_app_type = -1;
2215 static int hf_mpeg_descr_app_sig_ait_ver = -1;
2218 proto_mpeg_descriptor_dissect_app_sig(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2222 offset_start = offset;
2223 while ((offset - offset_start) < len) {
2224 proto_tree_add_item(tree, hf_mpeg_descr_app_sig_app_type, tvb, offset, 2, ENC_BIG_ENDIAN);
2226 proto_tree_add_item(tree, hf_mpeg_descr_app_sig_ait_ver, tvb, offset, 2, ENC_BIG_ENDIAN);
2231 /* 0x73 Default Authority Descriptor */
2232 static int hf_mpeg_descr_default_authority_name = -1;
2235 proto_mpeg_descriptor_dissect_default_authority(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2237 proto_tree_add_item(tree, hf_mpeg_descr_default_authority_name, tvb, offset, len, ENC_ASCII|ENC_NA);
2240 /* 0x76 Content Identifier Descriptor */
2241 static int hf_mpeg_descr_content_identifier_crid_type = -1;
2242 static int hf_mpeg_descr_content_identifier_crid_location = -1;
2243 static int hf_mpeg_descr_content_identifier_crid_length = -1;
2244 static int hf_mpeg_descr_content_identifier_crid_bytes = -1;
2245 static int hf_mpeg_descr_content_identifier_cird_ref = -1;
2247 #define MPEG_DESCR_CONTENT_IDENTIFIER_CRID_TYPE_MASK 0xFC
2248 #define MPEG_DESCR_CONTENT_IDENTIFIER_CRID_LOCATION_MASK 0x03
2250 static gint ett_mpeg_descriptor_content_identifier_crid = -1;
2252 static const value_string mpeg_descr_content_identifier_crid_type_vals[] = {
2253 { 0x00, "No type defined" },
2254 { 0x01, "CRID references the item of content that this event is an instance of" },
2255 { 0x02, "CRID references a series that this event belongs to" },
2256 { 0x03, "CRID references a recommendation" },
2261 static const value_string mpeg_descr_content_identifier_crid_location_vals[] = {
2262 { 0x00, "Carried explicitly within descriptor" },
2263 { 0x01, "Carried in Content Identifier Table (CIT)" },
2269 proto_mpeg_descriptor_dissect_content_identifier(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2271 guint end = offset + len, crid_len;
2272 guint8 crid, crid_location, crid_type;
2274 proto_tree *crid_tree;
2276 while (offset < end) {
2277 crid = tvb_get_guint8(tvb, offset);
2278 crid_type = (crid & MPEG_DESCR_CONTENT_IDENTIFIER_CRID_TYPE_MASK) >> 2;
2279 crid_location = crid & MPEG_DESCR_CONTENT_IDENTIFIER_CRID_LOCATION_MASK;
2281 if (crid_location == 0) {
2282 crid_len = 2 + tvb_get_guint8(tvb, offset + 1);
2283 } else if (crid_location == 1) {
2289 crid_tree = proto_tree_add_subtree_format(tree, tvb, offset, crid_len,
2290 ett_mpeg_descriptor_content_identifier_crid, NULL, "CRID type=0%02x", crid_type);
2292 proto_tree_add_item(crid_tree, hf_mpeg_descr_content_identifier_crid_type, tvb, offset, 1, ENC_BIG_ENDIAN);
2293 proto_tree_add_item(crid_tree, hf_mpeg_descr_content_identifier_crid_location, tvb, offset, 1, ENC_BIG_ENDIAN);
2296 if (crid_location == 0x00) {
2297 crid_len = tvb_get_guint8(tvb, offset);
2298 proto_tree_add_item(crid_tree, hf_mpeg_descr_content_identifier_crid_length, tvb, offset, 1, ENC_BIG_ENDIAN);
2301 proto_tree_add_item(crid_tree, hf_mpeg_descr_content_identifier_crid_bytes, tvb, offset, crid_len, ENC_NA);
2303 } else if (crid_location == 0x01) {
2304 proto_tree_add_item(crid_tree, hf_mpeg_descr_content_identifier_cird_ref, tvb, offset, 2, ENC_BIG_ENDIAN);
2312 /* 0x7F Extension Descriptor */
2313 static int hf_mpeg_descr_extension_tag_extension = -1;
2314 static int hf_mpeg_descr_extension_data = -1;
2315 /* Supplementary Audio (Sub-)Descriptor */
2316 static int hf_mpeg_descr_extension_supp_audio_mix_type = -1;
2317 static int hf_mpeg_descr_extension_supp_audio_ed_cla = -1;
2318 static int hf_mpeg_descr_extension_supp_audio_lang_code_present = -1;
2319 static int hf_mpeg_descr_extension_supp_audio_lang_code = -1;
2321 static int hf_mpeg_descr_private_data = -1;
2323 #define EXT_TAG_IMG_ICON 0x00
2324 #define EXT_TAG_CPCM_DLV 0x01
2325 #define EXT_TAG_CP 0x02
2326 #define EXT_TAG_CP_ID 0x03
2327 #define EXT_TAG_T2 0x04
2328 #define EXT_TAG_SH 0x05
2329 #define EXT_TAG_SUPP_AUDIO 0x06
2330 #define EXT_TAG_NW_CHANGE 0x07
2331 #define EXT_TAG_MSG 0x08
2332 #define EXT_TAG_TRGT_REG 0x09
2333 #define EXT_TAG_TRGT_REG_NAME 0x0A
2334 #define EXT_TAG_SVC_RELOC 0x0B
2336 static const value_string mpeg_descr_extension_tag_extension_vals[] = {
2337 { EXT_TAG_IMG_ICON, "Image Icon Descriptor" },
2338 { EXT_TAG_CPCM_DLV, "CPCM Delivery Signalling Descriptor" },
2339 { EXT_TAG_CP, "CP Descriptor" },
2340 { EXT_TAG_CP_ID, "CP Identifier Descriptor" },
2341 { EXT_TAG_T2, "T2 Delivery System Descriptor" },
2342 { EXT_TAG_SH, "SH Delivery System Descriptor" },
2343 { EXT_TAG_SUPP_AUDIO, "Supplementary Audio Descriptor" },
2344 { EXT_TAG_NW_CHANGE, "Network Change Notify Descriptor" },
2345 { EXT_TAG_MSG, "Message Descriptor" },
2346 { EXT_TAG_TRGT_REG, "Target Region Descriptor" },
2347 { EXT_TAG_TRGT_REG_NAME, "Target Region Name Descriptor" },
2348 { EXT_TAG_SVC_RELOC, "Service Relocated Descriptor" },
2351 static value_string_ext mpeg_descr_extension_tag_extension_vals_ext = VALUE_STRING_EXT_INIT(mpeg_descr_extension_tag_extension_vals);
2353 static const value_string supp_audio_mix_type_vals[] = {
2354 { 0x00, "Audio stream is a supplementary stream" },
2355 { 0x01, "Audio stream is a complete and independent stream" },
2359 /* if we wanted to distinguish between reserved and user defined,
2360 we'd have to convert this into a range string */
2361 static const value_string supp_audio_ed_cla[] = {
2362 { 0x00, "Main audio" },
2363 { 0x01, "Audio description for the visually impaired" },
2364 { 0x02, "Clean audio for the hearing impaired" },
2365 { 0x03, "Spoken subtitles for the visually impaired" },
2371 proto_mpeg_descriptor_dissect_extension(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2375 gboolean lang_code_present;
2376 guint already_dissected;
2378 offset_start = offset;
2380 tag_ext = tvb_get_guint8(tvb, offset);
2381 proto_tree_add_item(tree, hf_mpeg_descr_extension_tag_extension, tvb, offset, 1, ENC_BIG_ENDIAN);
2385 case EXT_TAG_SUPP_AUDIO:
2386 proto_tree_add_item(tree, hf_mpeg_descr_extension_supp_audio_mix_type, tvb, offset, 1, ENC_BIG_ENDIAN);
2387 proto_tree_add_item(tree, hf_mpeg_descr_extension_supp_audio_ed_cla, tvb, offset, 1, ENC_BIG_ENDIAN);
2388 lang_code_present = ((tvb_get_guint8(tvb, offset) & 0x01) == 0x01);
2389 proto_tree_add_item(tree, hf_mpeg_descr_extension_supp_audio_lang_code_present, tvb, offset, 1, ENC_BIG_ENDIAN);
2391 if (lang_code_present) {
2392 proto_tree_add_item(tree, hf_mpeg_descr_extension_supp_audio_lang_code, tvb, offset, 3, ENC_ASCII|ENC_NA);
2395 already_dissected = offset-offset_start;
2396 if (already_dissected<len)
2397 proto_tree_add_item(tree, hf_mpeg_descr_private_data, tvb, offset, len-already_dissected, ENC_NA);
2400 already_dissected = offset-offset_start;
2401 if (already_dissected<len)
2402 proto_tree_add_item(tree, hf_mpeg_descr_extension_data, tvb, offset, len-already_dissected, ENC_NA);
2408 #define MPEG_DESCR_AC3_SYSA_SRATE_MASK 0xe0
2409 #define MPEG_DESCR_AC3_SYSA_BSID_MASK 0x1f
2410 #define MPEG_DESCR_AC3_SYSA_BITRATE_CODE_LIMIT_MASK 0x80
2411 #define MPEG_DESCR_AC3_SYSA_BITRATE_CODE_MASK 0x7c
2412 #define MPEG_DESCR_AC3_SYSA_SURROUND_MODE_MASK 0x03
2413 #define MPEG_DESCR_AC3_SYSA_BSMOD_MASK 0xe0
2414 #define MPEG_DESCR_AC3_SYSA_NUM_CHANNELS_MASK 0x1e
2415 #define MPEG_DESCR_AC3_SYSA_FULL_SVC_MASK 0x01
2416 #define MPEG_DESCR_AC3_SYSA_MAINID_MASK 0xe0
2417 #define MPEG_DESCR_AC3_SYSA_PRIORITY_MASK 0x18
2418 #define MPEG_DESCR_AC3_SYSA_RESERVED_MASK 0x07
2419 #define MPEG_DESCR_AC3_SYSA_TEXTLEN_MASK 0xfe
2420 #define MPEG_DESCR_AC3_SYSA_TEXTCODE_MASK 0x01
2421 #define MPEG_DESCR_AC3_SYSA_LANG1_MASK 0x80
2422 #define MPEG_DESCR_AC3_SYSA_LANG2_MASK 0x40
2424 static int hf_mpeg_descr_ac3_sysa_srate = -1;
2425 static int hf_mpeg_descr_ac3_sysa_bsid = -1;
2426 static int hf_mpeg_descr_ac3_sysa_bitrate = -1;
2427 static int hf_mpeg_descr_ac3_sysa_bitrate_limit = -1;
2428 static int hf_mpeg_descr_ac3_sysa_surround = -1;
2429 static int hf_mpeg_descr_ac3_sysa_bsmod = -1;
2430 static int hf_mpeg_descr_ac3_sysa_num_channels = -1;
2431 static int hf_mpeg_descr_ac3_sysa_full_svc = -1;
2432 static int hf_mpeg_descr_ac3_sysa_langcode = -1;
2433 static int hf_mpeg_descr_ac3_sysa_langcode2 = -1;
2434 static int hf_mpeg_descr_ac3_sysa_mainid = -1;
2435 static int hf_mpeg_descr_ac3_sysa_priority = -1;
2436 static int hf_mpeg_descr_ac3_sysa_reserved = -1;
2437 static int hf_mpeg_descr_ac3_sysa_asvcflags = -1;
2438 static int hf_mpeg_descr_ac3_sysa_textlen = -1;
2439 static int hf_mpeg_descr_ac3_sysa_textcode = -1;
2440 static int hf_mpeg_descr_ac3_sysa_lang1 = -1;
2441 static int hf_mpeg_descr_ac3_sysa_lang2 = -1;
2442 static int hf_mpeg_descr_ac3_sysa_lang1_bytes = -1;
2443 static int hf_mpeg_descr_ac3_sysa_lang2_bytes = -1;
2445 /* ATSC A/52 Annex A Table A4.2*/
2446 static const value_string mpeg_descr_ac3_sysa_srate_flag_vals[] = {
2448 { 0x1, "44.1 KHz" },
2450 { 0x3, "Reserved" },
2451 { 0x4, "48 or 44.1 KHz" },
2452 { 0x5, "48 or 32 KHz" },
2453 { 0x6, "44.1 or 32 KHz" },
2454 { 0x7, "48, 44.1 or 32 KHz" },
2458 /* ATSC A/52 Annex A Table A4.3 */
2459 static const value_string mpeg_descr_ac3_sysa_bitrate_code_limit_vals[] = {
2460 { 0, "Exact bitrate" },
2461 { 1, "Upper limit bitrate" },
2465 static const value_string mpeg_descr_ac3_sysa_bitrate_code_vals[] = {
2488 /* ATSC A/52 Annex A Table A4.4 */
2489 static const value_string mpeg_descr_ac3_sysa_surround_mode_vals[] = {
2490 { 0x0, "Not indicated" },
2491 { 0x1, "NOT Dolby Surround Sound" },
2492 { 0x2, "Dolby Surround Sound" },
2493 { 0x3, "Reserved" },
2497 /* ATSC A/52 Annex A Table A4.5*/
2498 static const value_string mpeg_descr_ac3_sysa_num_channels_vals[] = {
2499 { 0x0, "1 + 1 channels" },
2500 { 0x1, "1/0 channels" },
2501 { 0x2, "2/0 channels" },
2502 { 0x3, "3/0 channels" },
2503 { 0x4, "2/1 channels" },
2504 { 0x5, "3/1 channels" },
2505 { 0x6, "2/2 channels" },
2506 { 0x7, "3/2 channels" },
2507 { 0x8, "1 channel" },
2508 { 0x9, "<= 2 channels" },
2509 { 0xa, "<= 3 channels" },
2510 { 0xb, "<= 4 channels" },
2511 { 0xc, "<= 5 channels" },
2512 { 0xd, "<= 6 channels" },
2513 { 0xe, "Reserved" },
2514 { 0xf, "Reserved" },
2518 /* ATSC A/52 Annex A Table A4.6 */
2519 static const value_string mpeg_descr_ac3_sysa_priority_vals[] = {
2520 { 0x0, "Reserved" },
2521 { 0x1, "Primary Audio" },
2522 { 0x2, "Other Audio" },
2523 { 0x3, "Not specified" },
2527 /* According to ATSC A/52, Annex A, there are two separate ATSC descriptors. "System A" is used
2528 by ATSC, and "System B" is used by DVB. See A/52 Sec A.4.1 for the System A definition */
2530 proto_mpeg_descriptor_dissect_ac3_system_a(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2532 guint end = offset + len;
2533 guint8 bsmod_chans_fullsvc, bsmod, num_channels, textlen, lang;
2535 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_srate, tvb, offset, 1, ENC_BIG_ENDIAN);
2536 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_bsid, tvb, offset, 1, ENC_BIG_ENDIAN);
2539 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_bitrate_limit, tvb, offset, 1, ENC_BIG_ENDIAN);
2540 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_bitrate, tvb, offset, 1, ENC_BIG_ENDIAN);
2541 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_surround, tvb, offset, 1, ENC_BIG_ENDIAN);
2544 bsmod_chans_fullsvc = tvb_get_guint8(tvb, offset);
2545 bsmod = (bsmod_chans_fullsvc & 0xe0) >> 5;
2546 num_channels = (bsmod_chans_fullsvc & 0x1e) >> 1;
2547 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_bsmod, tvb, offset, 1, ENC_BIG_ENDIAN);
2548 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_num_channels, tvb, offset, 1, ENC_BIG_ENDIAN);
2549 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_full_svc, tvb, offset, 1, ENC_BIG_ENDIAN);
2552 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_langcode, tvb, offset, 1, ENC_BIG_ENDIAN);
2555 if (num_channels == 0) {
2556 /* 1+1 mode, so there is the possibility the second mono is in a different language */
2557 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_langcode2, tvb, offset, 1, ENC_BIG_ENDIAN);
2562 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_mainid, tvb, offset, 1, ENC_BIG_ENDIAN);
2563 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_priority, tvb, offset, 1, ENC_BIG_ENDIAN);
2564 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2566 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_asvcflags, tvb, offset, 1, ENC_BIG_ENDIAN);
2570 textlen = tvb_get_guint8(tvb, offset) >> 1;
2571 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_textlen, tvb, offset, 1, ENC_BIG_ENDIAN);
2572 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_textcode, tvb, offset, 1, ENC_BIG_ENDIAN);
2576 lang = tvb_get_guint8(tvb, offset);
2577 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_lang1, tvb, offset, 1, ENC_BIG_ENDIAN);
2578 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_lang2, tvb, offset, 1, ENC_BIG_ENDIAN);
2582 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_lang1_bytes, tvb, offset, 3, ENC_ASCII|ENC_NA);
2587 proto_tree_add_item(tree, hf_mpeg_descr_ac3_sysa_lang2_bytes, tvb, offset, 3, ENC_ASCII|ENC_NA);
2592 proto_tree_add_item(tree, hf_mpeg_descr_ac3_additional_info, tvb, offset, end - offset, ENC_NA);
2595 /* 0xA2 Logon Initialize Descriptor */
2596 static int hf_mpeg_descr_logon_initialize_group_id = -1;
2597 static int hf_mpeg_descr_logon_initialize_logon_id = -1;
2598 static int hf_mpeg_descr_logon_initialize_continuous_carrier_reserved = -1;
2599 static int hf_mpeg_descr_logon_initialize_continuous_carrier = -1;
2600 static int hf_mpeg_descr_logon_initialize_security_handshake_required = -1;
2601 static int hf_mpeg_descr_logon_initialize_prefix_flag = -1;
2602 static int hf_mpeg_descr_logon_initialize_data_unit_labelling_flag = -1;
2603 static int hf_mpeg_descr_logon_initialize_mini_slot_flag = -1;
2604 static int hf_mpeg_descr_logon_initialize_contention_based_mini_slot_flag = -1;
2605 static int hf_mpeg_descr_logon_initialize_capacity_type_flag_reserved = -1;
2606 static int hf_mpeg_descr_logon_initialize_capacity_type_flag = -1;
2607 static int hf_mpeg_descr_logon_initialize_traffic_burst_type = -1;
2608 static int hf_mpeg_descr_logon_initialize_connectivity = -1;
2609 static int hf_mpeg_descr_logon_initialize_return_vpi_reserved = -1;
2610 static int hf_mpeg_descr_logon_initialize_return_vpi = -1;
2611 static int hf_mpeg_descr_logon_initialize_return_vci = -1;
2612 static int hf_mpeg_descr_logon_initialize_return_signalling_vpi_reserved = -1;
2613 static int hf_mpeg_descr_logon_initialize_return_signalling_vpi = -1;
2614 static int hf_mpeg_descr_logon_initialize_return_signalling_vci = -1;
2615 static int hf_mpeg_descr_logon_initialize_forward_signalling_vpi_reserved = -1;
2616 static int hf_mpeg_descr_logon_initialize_forward_signalling_vpi = -1;
2617 static int hf_mpeg_descr_logon_initialize_forward_signalling_vci = -1;
2619 static int hf_mpeg_descr_logon_initialize_return_trf_pid = -1;
2620 static int hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid_reserved = -1;
2621 static int hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid = -1;
2623 static int hf_mpeg_descr_logon_initialize_cra_level = -1;
2624 static int hf_mpeg_descr_logon_initialize_vbdc_max_reserved = -1;
2625 static int hf_mpeg_descr_logon_initialize_vbdc_max = -1;
2626 static int hf_mpeg_descr_logon_initialize_rbdc_max = -1;
2627 static int hf_mpeg_descr_logon_initialize_rbdc_timeout = -1;
2630 #define MPEG_DESCR_LOGON_INITIALIZE_CONTINUOUS_CARRIER_RESERVED_MASK 0xC0
2631 #define MPEG_DESCR_LOGON_INITIALIZE_CONTINUOUS_CARRIER_MASK 0x20
2632 #define MPEG_DESCR_LOGON_INITIALIZE_SECURITY_HANDSHAKE_REQUIRED_MASK 0x10
2633 #define MPEG_DESCR_LOGON_INITIALIZE_PREFIX_FLAG_MASK 0x08
2634 #define MPEG_DESCR_LOGON_INITIALIZE_DATA_UNIT_LABELLING_FLAG_MASK 0x04
2635 #define MPEG_DESCR_LOGON_INITIALIZE_MINI_SLOT_FLAG_MASK 0x02
2636 #define MPEG_DESCR_LOGON_INITIALIZE_CONTENTION_BASED_MINI_SLOT_FLAG_MASK 0x01
2638 #define MPEG_DESCR_LOGON_INITIALIZE_CAPACITY_TYPE_FLAG_RESERVED_MASK 0x80
2639 #define MPEG_DESCR_LOGON_INITIALIZE_CAPACITY_TYPE_FLAG_MASK 0x40
2640 #define MPEG_DESCR_LOGON_INITIALIZE_TRAFFIC_BURST_TYPE_MASK 0x20
2642 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_TRF_PID_MASK 0x1FFF
2643 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_CTRL_MNGM_PID_RESERVED_MASK 0xE000
2644 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_CTRL_MNGM_PID_MASK 0x1FFF
2646 #define MPEG_DESCR_LOGON_INITIALIZE_CONNECTIVITY_MASK 0x1000
2647 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_VPI_RESERVED_MASK 0x0F00
2648 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_VPI_MASK 0x00FF
2650 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_RESERVED_MASK 0x0F00
2651 #define MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_MASK 0x00FF
2652 #define MPEG_DESCR_LOGON_INITIALIZE_FORWARD_SIGNALLING_VPI_RESERVED_MASK 0xFF00
2653 #define MPEG_DESCR_LOGON_INITIALIZE_FORWARD_SIGNALLING_VPI_MASK 0x00FF
2655 #define MPEG_DESCR_LOGON_INITIALIZE_VDBC_MAX_RESERVED_MASK 0xF800
2656 #define MPEG_DESCR_LOGON_INITIALIZE_VDBC_MAX_MASK 0x0700
2660 proto_mpeg_descriptor_dissect_logon_initialize(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2663 guint end = offset + len;
2667 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_group_id, tvb, offset, 1, ENC_BIG_ENDIAN);
2670 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_logon_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2673 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_continuous_carrier_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2674 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_continuous_carrier, tvb, offset, 1, ENC_BIG_ENDIAN);
2675 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_security_handshake_required, tvb, offset, 1, ENC_BIG_ENDIAN);
2676 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_prefix_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2677 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_data_unit_labelling_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2678 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_mini_slot_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2679 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_contention_based_mini_slot_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2682 flags = tvb_get_guint8(tvb, offset);
2684 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_capacity_type_flag_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2685 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_capacity_type_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2686 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_traffic_burst_type, tvb, offset, 1, ENC_BIG_ENDIAN);
2687 if (flags & MPEG_DESCR_LOGON_INITIALIZE_TRAFFIC_BURST_TYPE_MASK) {
2688 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_connectivity, tvb, offset, 2, ENC_BIG_ENDIAN);
2689 flags2 = tvb_get_ntohs(tvb, offset);
2690 if (flags2 & MPEG_DESCR_LOGON_INITIALIZE_CONNECTIVITY_MASK) {
2691 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_signalling_vpi_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2692 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_signalling_vpi, tvb, offset, 1, ENC_BIG_ENDIAN);
2695 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_signalling_vci, tvb, offset, 2, ENC_BIG_ENDIAN);
2698 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_forward_signalling_vpi_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2699 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_forward_signalling_vpi, tvb, offset, 1, ENC_BIG_ENDIAN);
2702 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_forward_signalling_vci, tvb, offset, 2, ENC_BIG_ENDIAN);
2705 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_vpi_reserved, tvb, offset, 1, ENC_BIG_ENDIAN);
2706 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_vpi, tvb, offset, 1, ENC_BIG_ENDIAN);
2709 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_vci, tvb, offset, 2, ENC_BIG_ENDIAN);
2714 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_trf_pid, tvb, offset, 2, ENC_BIG_ENDIAN);
2717 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid_reserved, tvb, offset, 2, ENC_BIG_ENDIAN);
2718 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid, tvb, offset, 2, ENC_BIG_ENDIAN);
2722 if ((offset < end) && (flags & MPEG_DESCR_LOGON_INITIALIZE_CAPACITY_TYPE_FLAG_MASK)) {
2724 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_cra_level, tvb, offset, 3, ENC_BIG_ENDIAN);
2727 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_vbdc_max_reserved, tvb, offset, 2, ENC_BIG_ENDIAN);
2728 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_vbdc_max, tvb, offset, 2, ENC_BIG_ENDIAN);
2731 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_rbdc_max, tvb, offset, 3, ENC_BIG_ENDIAN);
2734 proto_tree_add_item(tree, hf_mpeg_descr_logon_initialize_rbdc_timeout, tvb, offset, 2, ENC_BIG_ENDIAN);
2739 /* 0xA7 RCS Content Descriptor */
2740 static int hf_mpeg_descr_rcs_content_table_id = -1;
2743 proto_mpeg_descriptor_dissect_rcs_content(tvbuff_t *tvb, guint offset, guint len, proto_tree *tree)
2745 guint end = offset + len;
2747 while (offset < end) {
2748 proto_tree_add_item(tree, hf_mpeg_descr_rcs_content_table_id, tvb, offset, 1, ENC_BIG_ENDIAN);
2753 /* Private descriptors
2754 these functions replace proto_mpeg_descriptor_dissect(), they get to see the whole descriptor */
2756 #define CIPLUS_DESC_TAG_CNT_LBL 0xCB
2757 #define CIPLUS_DESC_TAG_SVC 0xCC
2758 #define CIPLUS_DESC_TAG_PROT 0xCE
2760 static const value_string mpeg_descriptor_ciplus_tag_vals[] = {
2761 /* From CI+ 1.3.1 */
2762 { CIPLUS_DESC_TAG_CNT_LBL, "CI+ Content Label Descriptor" },
2763 { CIPLUS_DESC_TAG_SVC, "CI+ Service Descriptor" },
2764 { CIPLUS_DESC_TAG_PROT, "CI+ Protection Descriptor" },
2768 /* 0xCB CI+ Content Label Descriptor */
2769 static int hf_mpeg_descr_ciplus_cl_cb_min = -1;
2770 static int hf_mpeg_descr_ciplus_cl_cb_max = -1;
2771 static int hf_mpeg_descr_ciplus_cl_lang = -1;
2772 static int hf_mpeg_descr_ciplus_cl_label = -1;
2774 /* 0xCC CI+ Service Descriptor */
2775 static int hf_mpeg_descr_ciplus_svc_id = -1;
2776 static int hf_mpeg_descr_ciplus_svc_type = -1;
2777 static int hf_mpeg_descr_ciplus_svc_visible = -1;
2778 static int hf_mpeg_descr_ciplus_svc_selectable = -1;
2779 static int hf_mpeg_descr_ciplus_svc_lcn = -1;
2780 static int hf_mpeg_descr_ciplus_svc_prov_name = -1;
2781 static int hf_mpeg_descr_ciplus_svc_name = -1;
2783 /* 0xCE CI+ Protection Descriptor */
2784 static int hf_mpeg_descr_ciplus_prot_free_ci_mode = -1;
2785 static int hf_mpeg_descr_ciplus_prot_match_brand_flag = -1;
2786 static int hf_mpeg_descr_ciplus_prot_num_entries = -1;
2787 static int hf_mpeg_descr_ciplus_prot_brand_id = -1;
2789 static const true_false_string tfs_prot_noprot = { "CI+ protection required", "CI+ protection not required" };
2793 proto_mpeg_descriptor_dissect_private_ciplus(tvbuff_t *tvb, guint offset, proto_tree *tree)
2797 const gchar *tag_str;
2799 proto_tree *descriptor_tree;
2801 offset_start=offset;
2803 tag = tvb_get_guint8(tvb, offset);
2804 tag_str = try_val_to_str(tag, mpeg_descriptor_ciplus_tag_vals);
2808 descriptor_tree = proto_tree_add_subtree_format(tree, tvb, offset_start, -1,
2809 ett_mpeg_descriptor, &di, "CI+ private descriptor Tag=0x%02x", tag);
2811 proto_tree_add_uint_format(descriptor_tree, hf_mpeg_descriptor_tag,
2812 tvb, offset, 1, tag, "Descriptor Tag: %s (0x%02x)", tag_str, tag);
2815 len = tvb_get_guint8(tvb, offset);
2816 proto_tree_add_item(descriptor_tree, hf_mpeg_descriptor_length, tvb, offset, 1, ENC_BIG_ENDIAN);
2819 if (tag==CIPLUS_DESC_TAG_CNT_LBL) {
2820 proto_tree_add_item(tree, hf_mpeg_descr_ciplus_cl_cb_min, tvb, offset, 1, ENC_BIG_ENDIAN);
2823 proto_tree_add_item(tree, hf_mpeg_descr_ciplus_cl_cb_max, tvb, offset, 1, ENC_BIG_ENDIAN);
2826 proto_tree_add_item(tree, hf_mpeg_descr_ciplus_cl_lang, tvb, offset, 3, ENC_ASCII|ENC_NA);
2829 proto_tree_add_item(tree, hf_mpeg_descr_ciplus_cl_label, tvb, offset, len-offset, ENC_ASCII|ENC_NA);
2830 offset += len-offset;
2832 else if (tag==CIPLUS_DESC_TAG_SVC) {
2833 guint8 str_len_byte;
2835 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2838 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_type, tvb, offset, 1, ENC_BIG_ENDIAN);
2841 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_visible, tvb, offset, 2, ENC_BIG_ENDIAN);
2842 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_selectable, tvb, offset, 2, ENC_BIG_ENDIAN);
2843 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_lcn, tvb, offset, 2, ENC_BIG_ENDIAN);
2846 str_len_byte = tvb_get_guint8(tvb, offset);
2847 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_prov_name, tvb, offset, 1, ENC_ASCII|ENC_BIG_ENDIAN);
2848 offset += 1+str_len_byte;
2850 str_len_byte = tvb_get_guint8(tvb, offset);
2851 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_svc_name, tvb, offset, 1, ENC_ASCII|ENC_BIG_ENDIAN);
2852 offset += 1+str_len_byte;
2854 else if (tag==CIPLUS_DESC_TAG_PROT) {
2855 gboolean match_brand_flag;
2856 guint8 num_brands, i;
2859 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_prot_free_ci_mode, tvb, offset, 1, ENC_BIG_ENDIAN);
2860 match_brand_flag = ((tvb_get_guint8(tvb, offset) & 0x40) == 0x40);
2861 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_prot_match_brand_flag, tvb, offset, 1, ENC_BIG_ENDIAN);
2864 if (match_brand_flag) {
2865 num_brands = tvb_get_guint8(tvb, offset);
2866 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_prot_num_entries, tvb, offset, 1, ENC_BIG_ENDIAN);
2868 for (i=0; i<num_brands; i++) {
2869 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_ciplus_prot_brand_id, tvb, offset, 2, ENC_BIG_ENDIAN);
2874 remaining = offset_start+2+len - offset;
2875 if (remaining > 0) {
2876 proto_tree_add_item(descriptor_tree, hf_mpeg_descr_private_data, tvb, offset, remaining, ENC_NA);
2877 offset += remaining;
2881 proto_item_set_len(di, offset-offset_start);
2882 return offset-offset_start;
2886 /* Common dissector */
2889 proto_mpeg_descriptor_dissect(tvbuff_t *tvb, guint offset, proto_tree *tree)
2893 proto_tree *descriptor_tree;
2895 tag = tvb_get_guint8(tvb, offset);
2896 len = tvb_get_guint8(tvb, offset + 1);
2898 descriptor_tree = proto_tree_add_subtree_format(tree, tvb, offset, len + 2,
2899 ett_mpeg_descriptor, NULL, "Descriptor Tag=0x%02x", tag);
2901 proto_tree_add_item(descriptor_tree, hf_mpeg_descriptor_tag, tvb, offset, 1, ENC_BIG_ENDIAN);
2904 proto_tree_add_item(descriptor_tree, hf_mpeg_descriptor_length, tvb, offset, 1, ENC_BIG_ENDIAN);
2911 case 0x02: /* Video Stream Descriptor */
2912 proto_mpeg_descriptor_dissect_video_stream(tvb, offset, descriptor_tree);
2914 case 0x03: /* Audio Stream Descriptor */
2915 proto_mpeg_descriptor_dissect_audio_stream(tvb, offset, descriptor_tree);
2917 case 0x05: /* Registration Descriptor */
2918 proto_mpeg_descriptor_dissect_registration(tvb, offset, len, descriptor_tree);
2920 case 0x06: /* Data Stream Alignment Descriptor */
2921 proto_mpeg_descriptor_dissect_data_stream_alignment(tvb, offset, descriptor_tree);
2923 case 0x09: /* CA Descriptor */
2924 proto_mpeg_descriptor_dissect_ca(tvb, offset, len, descriptor_tree);
2926 case 0x0A: /* ISO 639 Language Descriptor */
2927 proto_mpeg_descriptor_dissect_iso639(tvb, offset, len, descriptor_tree);
2929 case 0x0B: /* System Clock Descriptor */
2930 proto_mpeg_descriptor_dissect_system_clock(tvb, offset, descriptor_tree);
2932 case 0x0E: /* Maximum Bitrate Descriptor */
2933 proto_mpeg_descriptor_dissect_max_bitrate(tvb, offset, descriptor_tree);
2935 case 0x10: /* Smoothing Buffer Descriptor */
2936 proto_mpeg_descriptor_dissect_smoothing_buffer(tvb, offset, descriptor_tree);
2938 case 0x11: /* STD Descriptor */
2939 proto_mpeg_descriptor_dissect_std(tvb, offset, descriptor_tree);
2941 case 0x13: /* Carousel Identifier Descriptor */
2942 proto_mpeg_descriptor_dissect_carousel_identifier(tvb, offset, len, descriptor_tree);
2944 case 0x14: /* Association Tag Descriptor */
2945 proto_mpeg_descriptor_dissect_association_tag(tvb, offset, len, descriptor_tree);
2947 case 0x28: /* AVC Video Descriptor */
2948 proto_mpeg_descriptor_dissect_avc_vid(tvb, offset, descriptor_tree);
2950 case 0x40: /* Network Name Descriptor */
2951 proto_mpeg_descriptor_dissect_network_name(tvb, offset, len, descriptor_tree);
2953 case 0x41: /* Service List Descriptor */
2954 proto_mpeg_descriptor_dissect_service_list(tvb, offset, len, descriptor_tree);
2956 case 0x42: /* Stuffing Descriptor */
2957 proto_mpeg_descriptor_stuffing(tvb, offset, len, descriptor_tree);
2959 case 0x43: /* Satellite Delivery System Descriptor */
2960 proto_mpeg_descriptor_dissect_satellite_delivery(tvb, offset, descriptor_tree);
2962 case 0x44: /* Cable Delivery System Descriptor */
2963 proto_mpeg_descriptor_dissect_cable_delivery(tvb, offset, descriptor_tree);
2965 case 0x45: /* VBI Data Descriptor */
2966 proto_mpeg_descriptor_dissect_vbi_data(tvb, offset, len, descriptor_tree);
2968 case 0x47: /* Bouquet Name Descriptor */
2969 proto_mpeg_descriptor_dissect_bouquet_name(tvb, offset, len, descriptor_tree);
2971 case 0x48: /* Service Descriptor */
2972 proto_mpeg_descriptor_dissect_service(tvb, offset, descriptor_tree);
2974 case 0x4A: /* Linkage Descriptor */
2975 proto_mpeg_descriptor_dissect_linkage(tvb, offset, len, descriptor_tree);
2977 case 0x4D: /* Short Event Descriptor */
2978 proto_mpeg_descriptor_dissect_short_event(tvb, offset, descriptor_tree);
2980 case 0x4E: /* Extended Event Descriptor */
2981 proto_mpeg_descriptor_dissect_extended_event(tvb, offset, descriptor_tree);
2983 case 0x50: /* Component Descriptor */
2984 proto_mpeg_descriptor_dissect_component(tvb, offset, len, descriptor_tree);
2986 case 0x52: /* Stream Identifier Descriptor */
2987 proto_mpeg_descriptor_dissect_stream_identifier(tvb, offset, descriptor_tree);
2989 case 0x53: /* CA Identifier Descriptor */
2990 proto_mpeg_descriptor_dissect_ca_identifier(tvb, offset, len, descriptor_tree);
2992 case 0x54: /* Content Descriptor */
2993 proto_mpeg_descriptor_dissect_content(tvb, offset, len, descriptor_tree);
2995 case 0x55: /* Parental Rating Descriptor */
2996 proto_mpeg_descriptor_dissect_parental_rating(tvb, offset, descriptor_tree);
2998 case 0x56: /* Teletext Descriptor */
2999 proto_mpeg_descriptor_dissect_teletext(tvb, offset, len, descriptor_tree);
3001 case 0x58: /* Local Time Offset Descriptor */
3002 proto_mpeg_descriptor_dissect_local_time_offset(tvb, offset, len, descriptor_tree);
3004 case 0x59: /* Subtitling Descriptor */
3005 proto_mpeg_descriptor_dissect_subtitling(tvb, offset, len, descriptor_tree);
3007 case 0x5A: /* Terrestrial Delivery System Descriptor */
3008 proto_mpeg_descriptor_dissect_terrestrial_delivery(tvb, offset, descriptor_tree);
3010 case 0x5F: /* Private Data Specifier Descriptor */
3011 proto_mpeg_descriptor_dissect_private_data_specifier(tvb, offset, descriptor_tree);
3013 case 0x64: /* Data Broadcast Descriptor */
3014 proto_mpeg_descriptor_dissect_data_bcast(tvb, offset, descriptor_tree);
3016 case 0x66: /* Data Broadcast ID Descriptor */
3017 proto_mpeg_descriptor_dissect_data_bcast_id(tvb, offset, len, descriptor_tree);
3019 case 0x6A: /* AC-3 Descriptor */
3020 proto_mpeg_descriptor_dissect_ac3(tvb, offset, len, descriptor_tree);
3022 case 0x6F: /* Application Signalling Descriptor */
3023 proto_mpeg_descriptor_dissect_app_sig(tvb, offset, len, descriptor_tree);
3025 case 0x73: /* Default Authority Descriptor */
3026 proto_mpeg_descriptor_dissect_default_authority(tvb, offset, len, descriptor_tree);
3028 case 0x76: /* Content Identifier Descriptor */
3029 proto_mpeg_descriptor_dissect_content_identifier(tvb, offset, len, descriptor_tree);
3031 case 0x7F: /* Extension Descriptor */
3032 proto_mpeg_descriptor_dissect_extension(tvb, offset, len, descriptor_tree);
3034 case 0x81: /* ATSC A/52 AC-3 Audio Descriptor */
3035 proto_mpeg_descriptor_dissect_ac3_system_a(tvb, offset, len, descriptor_tree);
3037 case 0xA2: /* Logon Initialize Descriptor */
3038 proto_mpeg_descriptor_dissect_logon_initialize(tvb, offset, len, descriptor_tree);
3040 case 0xA7: /* RCS Content Descriptor */
3041 proto_mpeg_descriptor_dissect_rcs_content(tvb, offset, len, descriptor_tree);
3044 proto_tree_add_item(descriptor_tree, hf_mpeg_descriptor_data, tvb, offset, len, ENC_NA);
3052 /* dissect a descriptor loop consisting of one or more descriptors
3053 take into account the contexts defined a private data specifier descriptors */
3055 proto_mpeg_descriptor_loop_dissect(tvbuff_t *tvb, guint offset, guint loop_len, proto_tree *tree)
3057 /* we use the reserved value to indicate that no private context is active */
3058 guint32 private_data_specifier = PRIVATE_DATA_SPECIFIER_RESERVED;
3063 offset_start = offset;
3065 while ((offset - offset_start) < loop_len) {
3066 /* don't increment offset in our pre-checks */
3067 tag = tvb_get_guint8(tvb, offset);
3069 /* we have a private data specifier descriptor: get the private data specifier */
3070 /* offset+1 is length byte, offset+2 is start of payload */
3071 private_data_specifier = tvb_get_ntohl(tvb, offset+2);
3074 /* the default descriptor function takes precedence
3075 however, if it does not know the current descriptor, we search for a context-specific subfunction
3076 this subfunction gets to see the entire descriptor, including tag and len */
3077 if (try_val_to_str(tag, mpeg_descriptor_tag_vals)) {
3078 desc_len = proto_mpeg_descriptor_dissect(tvb, offset, tree);
3081 switch (private_data_specifier) {
3082 case PRIVATE_DATA_SPECIFIER_CIPLUS_LLP:
3083 desc_len = proto_mpeg_descriptor_dissect_private_ciplus(tvb, offset, tree);
3089 if (desc_len == 0) {
3090 /* either there was no subfunction or it could not handle the descriptor
3091 fall back to the default (which will dissect it as unknown) */
3092 desc_len = proto_mpeg_descriptor_dissect(tvb, offset, tree);
3099 return offset-offset_start;
3104 proto_register_mpeg_descriptor(void)
3107 static hf_register_info hf[] = {
3108 { &hf_mpeg_descriptor_tag, {
3109 "Descriptor Tag", "mpeg_descr.tag",
3110 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descriptor_tag_vals_ext, 0, NULL, HFILL
3113 { &hf_mpeg_descriptor_length, {
3114 "Descriptor Length", "mpeg_descr.len",
3115 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3118 { &hf_mpeg_descriptor_data, {
3119 "Descriptor Data", "mpeg_descr.data",
3120 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3123 /* 0x02 Video Stream Descriptor */
3124 { &hf_mpeg_descr_video_stream_multiple_frame_rate_flag, {
3125 "Multiple Frame Rate Flag", "mpeg_descr.video_stream.multiple_frame_rate_flag",
3126 FT_UINT8, BASE_DEC, VALS(mpeg_descr_video_stream_multiple_frame_rate_flag_vals),
3127 MPEG_DESCR_VIDEO_STREAM_MULTIPLE_FRAME_RATE_FLAG_MASK, NULL, HFILL
3130 { &hf_mpeg_descr_video_stream_frame_rate_code, {
3131 "Frame Rate Code", "mpeg_descr.video_stream.frame_rate_code",
3132 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_VIDEO_STREAM_FRAME_RATE_CODE_MASK, NULL, HFILL
3135 { &hf_mpeg_descr_video_stream_mpeg1_only_flag, {
3136 "MPEG1 Only Flag", "mpeg_descr.video_stream.mpeg1_only_flag",
3137 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_VIDEO_STREAM_MPEG1_ONLY_FLAG_MASK, NULL, HFILL
3140 { &hf_mpeg_descr_video_stream_constrained_parameter_flag, {
3141 "Constrained Parameter Flag", "mpeg_descr.video_stream.constrained_parameter_flag",
3142 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_VIDEO_STREAM_CONSTRAINED_PARAMETER_FLAG_MASK, NULL, HFILL
3145 { &hf_mpeg_descr_video_stream_still_picture_flag, {
3146 "Still Picture Flag", "mpeg_descr.video_stream.still_picture_flag",
3147 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_VIDEO_STREAM_STILL_PICTURE_FLAG_MASK, NULL, HFILL
3150 { &hf_mpeg_descr_video_stream_profile_and_level_indication, {
3151 "Profile and Level Indication", "mpeg_descr.video_stream.profile_level_ind",
3152 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3155 { &hf_mpeg_descr_video_stream_chroma_format, {
3156 "Chroma Format", "mpeg_descr.video_stream.chroma_format",
3157 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3160 { &hf_mpeg_descr_video_stream_frame_rate_extension_flag, {
3161 "Frame Rate Extension Flag", "mpeg_descr.video_stream.frame_rate_extension_flag",
3162 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_VIDEO_STREAM_FRAME_RATE_EXTENSION_FLAG_MASK, NULL, HFILL
3165 { &hf_mpeg_descr_video_stream_reserved, {
3166 "Reserved", "mpeg_descr.video_stream.reserved",
3167 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_VIDEO_STREAM_RESERVED_MASK, NULL, HFILL
3170 /* 0x03 Audio Stream Descriptor */
3171 { &hf_mpeg_descr_audio_stream_free_format_flag, {
3172 "Free Format Flag", "mpeg_descr.audio_stream.free_format_flag",
3173 FT_UINT8, BASE_DEC, VALS(mpeg_descr_audio_stream_free_format_flag_vals), MPEG_DESCR_AUDIO_STREAM_FREE_FORMAT_FLAG_MASK, NULL, HFILL
3176 { &hf_mpeg_descr_audio_stream_id, {
3177 "ID", "mpeg_descr.audio_stream.id",
3178 FT_UINT8, BASE_DEC, VALS(mpeg_descr_audio_stream_id_vals), MPEG_DESCR_AUDIO_STREAM_ID_MASK, NULL, HFILL
3181 { &hf_mpeg_descr_audio_stream_layer, {
3182 "Layer", "mpeg_descr.audio_stream.layer",
3183 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AUDIO_STREAM_LAYER_MASK, NULL, HFILL
3186 { &hf_mpeg_descr_audio_stream_variable_rate_audio_indicator, {
3187 "Variable Rate Audio Indicator", "mpeg_descr.audio_stream.vbr_indicator",
3188 FT_UINT8, BASE_DEC, VALS(mpeg_descr_audio_stream_variable_rate_audio_indicator_vals),
3189 MPEG_DESCR_AUDIO_STREAM_VARIABLE_RATE_AUDIO_INDICATOR_MASK, NULL, HFILL
3192 { &hf_mpeg_descr_audio_stream_reserved, {
3193 "Reserved", "mpeg_descr.audio_stream.reserved",
3194 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AUDIO_STREAM_RESERVED_MASK, NULL, HFILL
3197 /* 0x05 Registration Descriptor */
3198 { &hf_mpeg_descr_reg_form_id, {
3199 "Format identifier", "mpeg_descr.registration.format_identifier",
3200 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
3203 { &hf_mpeg_descr_reg_add_id_inf, {
3204 "Additional identification info", "mpeg_descr.registration.add_id_info",
3205 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3208 /* 0x06 Data Stream Alignment Descriptor */
3209 { &hf_mpeg_descr_data_stream_alignment, {
3210 "Data Stream Alignment", "mpeg_descr.data_stream_alignment.alignment",
3211 FT_UINT8, BASE_HEX, VALS(mpeg_descr_data_stream_alignment_vals), 0, NULL, HFILL
3214 /* 0x09 CA Descriptor */
3215 { &hf_mpeg_descr_ca_system_id, {
3216 "System ID", "mpeg_descr.ca.sys_id",
3217 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3220 { &hf_mpeg_descr_ca_reserved, {
3221 "Reserved", "mpeg_descr.ca.reserved",
3222 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_CA_RESERVED_MASK, NULL, HFILL
3225 { &hf_mpeg_descr_ca_pid, {
3226 "CA PID", "mpeg_descr.ca.pid",
3227 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_CA_PID_MASK, NULL, HFILL
3230 { &hf_mpeg_descr_ca_private, {
3231 "Private bytes", "mpeg_descr.ca.private",
3232 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3235 /* 0x0A ISO 639 Language Descriptor */
3236 { &hf_mpeg_descr_iso639_lang, {
3237 "ISO 639 Language Code", "mpeg_descr.lang.code",
3238 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3241 { &hf_mpeg_descr_iso639_type, {
3242 "ISO 639 Language Type", "mpeg_descr.lang.type",
3243 FT_UINT8, BASE_HEX, VALS(mpeg_descr_iso639_type_vals), 0, NULL, HFILL
3246 /* 0x0B System Clock Descriptor */
3247 { &hf_mpeg_descr_system_clock_external_clock_reference_indicator, {
3248 "External Clock Reference Indicator", "mpeg_descr.sys_clk.external_clk_ref_ind",
3249 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_SYSTEM_CLOCK_EXTERNAL_CLOCK_REFERENCE_INDICATOR_MASK, NULL, HFILL
3252 { &hf_mpeg_descr_system_clock_reserved1, {
3253 "Reserved", "mpeg_descr.sys_clk.reserved1",
3254 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_SYSTEM_CLOCK_RESERVED1_MASK, NULL, HFILL
3257 { &hf_mpeg_descr_system_clock_accuracy_integer, {
3258 "Accuracy Integer", "mpeg_descr.sys_clk.accuracy_integer",
3259 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_SYSTEM_CLOCK_ACCURACY_INTEGER_MASK, NULL, HFILL
3262 { &hf_mpeg_descr_system_clock_accuracy_exponent, {
3263 "Accuracy Exponent", "mpeg_descr.sys_clk.accuracy_exponent",
3264 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_SYSTEM_CLOCK_ACCURACY_EXPONENT_MASK, NULL, HFILL
3267 { &hf_mpeg_descr_system_clock_reserved2, {
3268 "Reserved", "mpeg_descr.sys_clk.reserved2",
3269 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_SYSTEM_CLOCK_RESERVED2_MASK, NULL, HFILL
3272 /* 0x0E Maximum Bitrate Descriptor */
3273 { &hf_mpeg_descr_max_bitrate_reserved, {
3274 "Maximum Bitrate Reserved", "mpeg_descr.max_bitrate.reserved",
3275 FT_UINT24, BASE_HEX, NULL, MPEG_DESCR_MAX_BITRATE_RESERVED_MASK, NULL, HFILL
3278 { &hf_mpeg_descr_max_bitrate, {
3279 "Maximum Bitrate", "mpeg_descr.max_bitrate.rate",
3280 FT_UINT24, BASE_DEC, NULL, MPEG_DESCR_MAX_BITRATE_MASK, NULL, HFILL
3283 /* 0x10 Smoothing Buffer Descriptor */
3284 { &hf_mpeg_descr_smoothing_buffer_reserved1, {
3285 "Reserved", "mpeg_descr.smoothing_buf.reserved1",
3286 FT_UINT24, BASE_HEX, NULL, MPEG_DESCR_SMOOTHING_BUFFER_RESERVED1_MASK, NULL, HFILL
3289 { &hf_mpeg_descr_smoothing_buffer_leak_rate, {
3290 "Leak Rate", "mpeg_descr.smoothing_buf.leak_rate",
3291 FT_UINT24, BASE_DEC, NULL, MPEG_DESCR_SMOOTHING_BUFFER_LEAK_RATE_MASK, NULL, HFILL
3294 { &hf_mpeg_descr_smoothing_buffer_reserved2, {
3295 "Reserved", "mpeg_descr.smoothing_buf.reserved2",
3296 FT_UINT24, BASE_HEX, NULL, MPEG_DESCR_SMOOTHING_BUFFER_RESERVED2_MASK, NULL, HFILL
3299 { &hf_mpeg_descr_smoothing_buffer_size, {
3300 "Buffer Size", "mpeg_descr.smoothing_buf.size",
3301 FT_UINT24, BASE_DEC, NULL, MPEG_DESCR_SMOOTHING_BUFFER_SIZE_MASK, NULL, HFILL
3304 /* 0x11 STD Descriptor */
3305 { &hf_mpeg_descr_std_reserved, {
3306 "Reserved", "mpeg_descr.std.reserved",
3307 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_STD_RESERVED_MASK, NULL, HFILL
3310 { &hf_mpeg_descr_std_leak_valid, {
3311 "Leak Valid", "mpeg_descr.std.leak_valid",
3312 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_STD_LEAK_VALID_MASK, NULL, HFILL
3315 /* 0x13 Carousel Identifier Descriptor */
3316 { &hf_mpeg_descr_carousel_identifier_id, {
3317 "Carousel ID", "mpeg_descr.carousel_identifier.id",
3318 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
3321 { &hf_mpeg_descr_carousel_identifier_format_id, {
3322 "Format ID", "mpeg_descr.carousel_identifier.format_id",
3323 FT_UINT8, BASE_HEX, VALS(mpeg_descr_carousel_identifier_format_id_vals), 0, NULL, HFILL
3326 { &hf_mpeg_descr_carousel_identifier_module_version, {
3327 "Module Version", "mpeg_descr.carousel_identifier.module_version",
3328 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3331 { &hf_mpeg_descr_carousel_identifier_module_id, {
3332 "Module ID", "mpeg_descr.carousel_identifier.module_id",
3333 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3336 { &hf_mpeg_descr_carousel_identifier_block_size, {
3337 "Block Size", "mpeg_descr.carousel_identifier.block_size",
3338 FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL
3341 { &hf_mpeg_descr_carousel_identifier_module_size, {
3342 "Module Size", "mpeg_descr.carousel_identifier.module_size",
3343 FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL
3346 { &hf_mpeg_descr_carousel_identifier_compression_method, {
3347 "Compression Method", "mpeg_descr.carousel_identifier.comp_method",
3348 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3351 { &hf_mpeg_descr_carousel_identifier_original_size, {
3352 "Original Size", "mpeg_descr.carousel_identifier.orig_size",
3353 FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL
3356 { &hf_mpeg_descr_carousel_identifier_timeout, {
3357 "Timeout", "mpeg_descr.carousel_identifier.timeout",
3358 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3361 { &hf_mpeg_descr_carousel_identifier_object_key_len, {
3362 "Object Key Length", "mpeg_descr.carousel_identifier.key_len",
3363 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3366 { &hf_mpeg_descr_carousel_identifier_object_key_data, {
3367 "Object Key Data", "mpeg_descr.carousel_identifier.key_data",
3368 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3371 { &hf_mpeg_descr_carousel_identifier_private, {
3372 "Private Bytes", "mpeg_descr.carousel_identifier.private",
3373 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3376 /* 0x14 Association Tag Descriptor */
3377 { &hf_mpeg_descr_association_tag, {
3378 "Association Tag", "mpeg_descr.assoc_tag.tag",
3379 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3382 { &hf_mpeg_descr_association_tag_use, {
3383 "Use", "mpeg_descr.assoc_tag.use",
3384 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3387 { &hf_mpeg_descr_association_tag_selector_len, {
3388 "Selector Length", "mpeg_descr.assoc_tag.selector_len",
3389 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3392 { &hf_mpeg_descr_association_tag_transaction_id, {
3393 "Transaction ID", "mpeg_descr.assoc_tag.transaction_id",
3394 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
3397 { &hf_mpeg_descr_association_tag_timeout, {
3398 "Timeout", "mpeg_descr.assoc_tag.timeout",
3399 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
3402 { &hf_mpeg_descr_association_tag_selector_bytes, {
3403 "Selector Bytes", "mpeg_descr.assoc_tag.selector_bytes",
3404 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3407 { &hf_mpeg_descr_association_tag_private_bytes, {
3408 "Private Bytes", "mpeg_descr.assoc_tag.private_bytes",
3409 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3412 /* 0x28 AVC Video Descriptor */
3413 { &hf_mpeg_descr_avc_vid_profile_idc, {
3414 "Profile IDC", "mpeg_descr.avc_vid.profile_idc",
3415 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3418 { &hf_mpeg_descr_avc_vid_constraint_set0_flag, {
3419 "Constraint Set0 Flag", "mpeg_descr.avc_vid.contraint_set0",
3420 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AVC_VID_CONSTRAINT_SET0_FLAG_MASK, NULL, HFILL
3423 { &hf_mpeg_descr_avc_vid_constraint_set1_flag, {
3424 "Constraint Set1 Flag", "mpeg_descr.avc_vid.contraint_set1",
3425 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AVC_VID_CONSTRAINT_SET1_FLAG_MASK, NULL, HFILL
3428 { &hf_mpeg_descr_avc_vid_constraint_set2_flag, {
3429 "Constraint Set2 Flag", "mpeg_descr.avc_vid.contraint_set2",
3430 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AVC_VID_CONSTRAINT_SET2_FLAG_MASK, NULL, HFILL
3433 { &hf_mpeg_descr_avc_vid_compatible_flags, {
3434 "Constraint Compatible Flags", "mpeg_descr.avc_vid.compatible_flags",
3435 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AVC_VID_COMPATIBLE_FLAGS_MASK, NULL, HFILL
3438 { &hf_mpeg_descr_avc_vid_level_idc, {
3439 "Level IDC", "mpeg_descr.avc_vid.level_idc",
3440 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3443 { &hf_mpeg_descr_avc_vid_still_present, {
3444 "AVC Still Present", "mpeg_descr.avc_vid.still_present",
3445 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AVC_VID_STILL_PRESENT_MASK, NULL, HFILL
3448 { &hf_mpeg_descr_avc_vid_24h_picture_flag, {
3449 "AVC 24 Hour Picture Flag", "mpeg_descr.avc_vid.24h_picture_flag",
3450 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_AVC_VID_24H_PICTURE_FLAG_MASK, NULL, HFILL
3453 { &hf_mpeg_descr_avc_vid_reserved, {
3454 "Reserved", "mpeg_descr.avc_vid.reserved",
3455 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AVC_VID_RESERVED_MASK, NULL, HFILL
3458 /* 0x40 Network Name Descriptor */
3459 { &hf_mpeg_descr_network_name_descriptor, {
3460 "Network Name", "mpeg_descr.net_name.name",
3461 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3464 /* 0x41 Service List Descriptor */
3465 { &hf_mpeg_descr_service_list_id, {
3466 "Service ID", "mpeg_descr.svc_list.id",
3467 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3470 { &hf_mpeg_descr_service_list_type, {
3471 "Service Type", "mpeg_descr.svc_list.type",
3472 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_service_type_vals_ext, 0, NULL, HFILL
3475 /* 0x42 Stuffing Descriptor */
3476 { &hf_mpeg_descr_stuffing, {
3477 "Stuffing", "mpeg_descr.stuffing",
3478 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3481 /* 0x43 Satellite Delivery System Descriptor */
3482 { &hf_mpeg_descr_satellite_delivery_frequency, {
3483 "Frequency", "mpeg_descr.sat_delivery.freq",
3484 FT_DOUBLE, BASE_NONE|BASE_UNIT_STRING, &units_ghz, 0, NULL, HFILL
3487 { &hf_mpeg_descr_satellite_delivery_orbital_position, {
3488 "Orbital Position", "mpeg_descr.sat_delivery.orbital_pos",
3489 FT_FLOAT, BASE_NONE|BASE_UNIT_STRING, &units_degree_degrees, 0, NULL, HFILL
3492 { &hf_mpeg_descr_satellite_delivery_west_east_flag, {
3493 "West East Flag", "mpeg_descr.sat_delivery.west_east_flag",
3494 FT_UINT8, BASE_HEX, VALS(mpeg_descr_satellite_delivery_west_east_flag_vals),
3495 MPEG_DESCR_SATELLITE_DELIVERY_WEST_EAST_FLAG_MASK, NULL, HFILL
3498 { &hf_mpeg_descr_satellite_delivery_polarization, {
3499 "Polarization", "mpeg_descr.sat_delivery.polarization",
3500 FT_UINT8, BASE_HEX, VALS(mpeg_descr_satellite_delivery_polarization_vals),
3501 MPEG_DESCR_SATELLITE_DELIVERY_POLARIZATION_MASK, NULL, HFILL
3504 { &hf_mpeg_descr_satellite_delivery_roll_off, {
3505 "Roll Off", "mpeg_descr.sat_delivery.roll_off",
3506 FT_UINT8, BASE_HEX, VALS(mpeg_descr_satellite_delivery_roll_off_vals),
3507 MPEG_DESCR_SATELLITE_DELIVERY_ROLL_OFF_MASK, NULL, HFILL
3510 { &hf_mpeg_descr_satellite_delivery_zero, {
3511 "Zero", "mpeg_descr.sat_delivery.zero",
3512 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_SATELLITE_DELIVERY_ZERO_MASK, NULL, HFILL
3515 { &hf_mpeg_descr_satellite_delivery_modulation_system, {
3516 "Modulation System", "mpeg_descr.sat_delivery.modulation_system",
3517 FT_UINT8, BASE_HEX, VALS(mpeg_descr_satellite_delivery_modulation_system_vals),
3518 MPEG_DESCR_SATELLITE_DELIVERY_MODULATION_SYSTEM_MASK, NULL, HFILL
3521 { &hf_mpeg_descr_satellite_delivery_modulation_type, {
3522 "Modulation Type", "mpeg_descr.sat_delivery.modulation_type",
3523 FT_UINT8, BASE_HEX, VALS(mpeg_descr_satellite_delivery_modulation_type_vals),
3524 MPEG_DESCR_SATELLITE_DELIVERY_MODULATION_TYPE_MASK, NULL, HFILL
3527 { &hf_mpeg_descr_satellite_delivery_symbol_rate, {
3528 "Symbol Rate", "mpeg_descr.sat_delivery.symbol_rate",
3529 FT_DOUBLE, BASE_NONE, NULL, 0, NULL, HFILL
3532 { &hf_mpeg_descr_satellite_delivery_fec_inner, {
3533 "FEC Inner", "mpeg_descr.sat_delivery.fec_inner",
3534 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_satellite_delivery_fec_inner_vals_ext,
3535 MPEG_DESCR_SATELLITE_DELIVERY_FEC_INNER_MASK, NULL, HFILL
3538 /* 0x44 Cable Delivery System Descriptor */
3539 { &hf_mpeg_descr_cable_delivery_frequency, {
3540 "Frequency", "mpeg_descr.cable_delivery.freq",
3541 FT_DOUBLE, BASE_NONE, NULL, 0, NULL, HFILL
3544 { &hf_mpeg_descr_cable_delivery_reserved, {
3545 "Reserved", "mpeg_descr.cable_delivery.reserved",
3546 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_CABLE_DELIVERY_RESERVED_MASK, NULL, HFILL
3549 { &hf_mpeg_descr_cable_delivery_fec_outer, {
3550 "FEC Outer", "mpeg_descr.cable_delivery.fec_outer",
3551 FT_UINT16, BASE_HEX, VALS(mpeg_descr_cable_delivery_fec_outer_vals),
3552 MPEG_DESCR_CABLE_DELIVERY_FEC_OUTER_MASK, NULL, HFILL
3555 { &hf_mpeg_descr_cable_delivery_modulation, {
3556 "Modulation", "mpeg_descr.cable_delivery.modulation",
3557 FT_UINT8, BASE_HEX, VALS(mpeg_descr_cable_delivery_modulation_vals), 0, NULL, HFILL
3560 { &hf_mpeg_descr_cable_delivery_symbol_rate, {
3561 "Symbol Rate", "mpeg_descr.cable_delivery.sym_rate",
3562 FT_DOUBLE, BASE_NONE, NULL, 0, NULL, HFILL
3565 { &hf_mpeg_descr_cable_delivery_fec_inner, {
3566 "FEC Inner", "mpeg_descr.cable_delivery.fec_inner",
3567 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_cable_delivery_fec_inner_vals_ext,
3568 MPEG_DESCR_CABLE_DELIVERY_FEC_INNER_MASK, NULL, HFILL
3571 /* 0x45 VBI Data Descriptor */
3572 { &hf_mpeg_descr_vbi_data_service_id, {
3573 "Data Service ID", "mpeg_descr.vbi_data.svc_id",
3574 FT_UINT8, BASE_HEX, VALS(mpeg_descr_vbi_data_service_id_vals), 0, NULL, HFILL
3577 { &hf_mpeg_descr_vbi_data_descr_len, {
3578 "Data Descriptor Length", "mpeg_descr.vbi_data.decr_len",
3579 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3582 { &hf_mpeg_descr_vbi_data_reserved1, {
3583 "Reserved", "mpeg_descr.vbi_data.reserved1",
3584 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_VBI_DATA_RESERVED1_MASK, NULL, HFILL
3587 { &hf_mpeg_descr_vbi_data_field_parity, {
3588 "Field Parity", "mpeg_descr.vbi_data.field_parity",
3589 FT_UINT8, BASE_DEC, VALS(mpeg_descr_vbi_data_field_parity_vals),
3590 MPEG_DESCR_VBI_DATA_FIELD_PARITY_MASK, NULL, HFILL
3593 { &hf_mpeg_descr_vbi_data_line_offset, {
3594 "Line offset", "mpeg_descr.vbi_data.line_offset",
3595 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3598 { &hf_mpeg_descr_vbi_data_reserved2, {
3599 "Reserved", "mpeg_descr.vbi_data.reserved2",
3600 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3603 /* 0x47 Bouquet Name Descriptor */
3604 { &hf_mpeg_descr_bouquet_name, {
3605 "Bouquet Name Descriptor", "mpeg_descr.bouquet_name.name",
3606 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3609 /* 0x48 Service Descriptor */
3610 { &hf_mpeg_descr_service_type, {
3611 "Service Type", "mpeg_descr.svc.type",
3612 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_service_type_vals_ext, 0, NULL, HFILL
3615 { &hf_mpeg_descr_service_provider_name_length, {
3616 "Provider Name Length", "mpeg_descr.svc.provider_name_len",
3617 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3620 { &hf_mpeg_descr_service_provider_name_encoding, {
3621 "Provider Name Encoding", "mpeg_descr.svc.provider_name_enc",
3622 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3625 { &hf_mpeg_descr_service_provider, {
3626 "Service Provider Name", "mpeg_descr.svc.provider_name",
3627 FT_STRING, STR_UNICODE, NULL, 0, NULL, HFILL
3630 { &hf_mpeg_descr_service_name_length, {
3631 "Service Name Length", "mpeg_descr.svc.svc_name_len",
3632 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3635 { &hf_mpeg_descr_service_name_encoding, {
3636 "Service Name Encoding", "mpeg_descr.svc.svn_name_enc",
3637 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3640 { &hf_mpeg_descr_service_name, {
3641 "Service Name", "mpeg_descr.svc.svc_name",
3642 FT_STRING, STR_UNICODE, NULL, 0, NULL, HFILL
3645 /* 0x4A Linkage Descriptor */
3646 { &hf_mpeg_descr_linkage_transport_stream_id, {
3647 "Transport Stream ID", "mpeg_descr.linkage.tsid",
3648 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3651 { &hf_mpeg_descr_linkage_original_network_id, {
3652 "Original Network ID", "mpeg_descr.linkage.original_nid",
3653 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3656 { &hf_mpeg_descr_linkage_service_id, {
3657 "Service ID", "mpeg_descr.linkage.svc_id",
3658 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3661 { &hf_mpeg_descr_linkage_linkage_type, {
3662 "Linkage Type", "mpeg_descr.linkage.type",
3663 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_linkage_linkage_type_vals_ext, 0, NULL, HFILL
3666 { &hf_mpeg_descr_linkage_hand_over_type, {
3667 "Hand-Over Type", "mpeg_descr.linkage.hand_over_type",
3668 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LINKAGE_HAND_OVER_TYPE_MASK, NULL, HFILL
3671 { &hf_mpeg_descr_linkage_reserved1, {
3672 "Reserved", "mpeg_descr.linkage.reserved1",
3673 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LINKAGE_RESERVED1_MASK, NULL, HFILL
3676 { &hf_mpeg_descr_linkage_origin_type, {
3677 "Origin Type", "mpeg_descr.linkage.origin_type",
3678 FT_UINT8, BASE_HEX, VALS(mpeg_descr_linkage_origin_type_vals), 0, NULL, HFILL
3681 { &hf_mpeg_descr_linkage_network_id, {
3682 "Network ID", "mpeg_descr.linkage.network_id",
3683 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3686 { &hf_mpeg_descr_linkage_initial_service_id, {
3687 "Initial Service ID", "mpeg_descr.linkage.initial_svc_id",
3688 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3691 { &hf_mpeg_descr_linkage_target_event_id, {
3692 "Target Event ID", "mpeg_descr.linkage.target_evt_id",
3693 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3696 { &hf_mpeg_descr_linkage_target_listed, {
3697 "Target Listed", "mpeg_descr.linkage.target_listed",
3698 FT_UINT8, BASE_DEC, VALS(mpeg_descr_linkage_target_listed_vals),
3699 MPEG_DESCR_LINKAGE_TARGET_LISTED_MASK, NULL, HFILL
3702 { &hf_mpeg_descr_linkage_event_simulcast, {
3703 "Event Simulcast", "mpeg_descr.linkage.evt_simulcast",
3704 FT_UINT8, BASE_DEC, VALS(mpeg_descr_linkage_event_simulcast_vals),
3705 MPEG_DESCR_LINKAGE_EVENT_SIMULCAST_MASK, NULL, HFILL
3708 { &hf_mpeg_descr_linkage_reserved2, {
3709 "Reserved", "mpeg_descr.linkage.reserved2",
3710 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LINKAGE_RESERVED2_MASK, NULL, HFILL
3713 { &hf_mpeg_descr_linkage_private_data_byte, {
3714 "Private Data", "mpeg_descr.linkage.private_data",
3715 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3718 { &hf_mpeg_descr_linkage_interactive_network_id, {
3719 "Interactive Network ID", "mpeg_descr.interactive_network_id",
3720 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3723 { &hf_mpeg_descr_linkage_population_id_loop_count, {
3724 "Population ID loop count", "mpeg_descr.population_id_loop_count",
3725 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3728 { &hf_mpeg_descr_linkage_population_id, {
3729 "Population ID", "mpeg_descr.population_id",
3730 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
3733 { &hf_mpeg_descr_linkage_population_id_base, {
3734 "Population ID Base", "mpeg_descr.population_id_base",
3735 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3738 { &hf_mpeg_descr_linkage_population_id_mask, {
3739 "Population ID Mask", "mpeg_descr.population_id_mask",
3740 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3743 /* 0x4D Short Event Descriptor */
3744 { &hf_mpeg_descr_short_event_lang_code, {
3745 "Language Code", "mpeg_descr.short_evt.lang_code",
3746 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3749 { &hf_mpeg_descr_short_event_name_length, {
3750 "Event Name Length", "mpeg_descr.short_evt.name_len",
3751 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3754 { &hf_mpeg_descr_short_event_name_encoding, {
3755 "Event Name Encoding", "mpeg_descr.short_evt.name_enc",
3756 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3759 { &hf_mpeg_descr_short_event_name, {
3760 "Event Name", "mpeg_descr.short_evt.name",
3761 FT_STRING, STR_UNICODE, NULL, 0, NULL, HFILL
3764 { &hf_mpeg_descr_short_event_text_length, {
3765 "Event Text Length", "mpeg_descr.short_evt.txt_len",
3766 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3769 { &hf_mpeg_descr_short_event_text_encoding, {
3770 "Event Text Encoding", "mpeg_descr.short_evt.txt_enc",
3771 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3774 { &hf_mpeg_descr_short_event_text, {
3775 "Event Text", "mpeg_descr.short_evt.txt",
3776 FT_STRING, STR_UNICODE, NULL, 0, NULL, HFILL
3779 /* 0x4E Extended Event Descriptor */
3780 { &hf_mpeg_descr_extended_event_descriptor_number, {
3781 "Descriptor Number", "mpeg_descr.ext_evt.descr_num",
3782 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_EXTENDED_EVENT_DESCRIPTOR_NUMBER_MASK, NULL, HFILL
3785 { &hf_mpeg_descr_extended_event_last_descriptor_number, {
3786 "Last Descriptor Number", "mpeg_descr.ext_evt.last_descr_num",
3787 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_EXTENDED_EVENT_LAST_DESCRIPTOR_NUMBER_MASK, NULL, HFILL
3790 { &hf_mpeg_descr_extended_event_lang_code, {
3791 "Language Code", "mpeg_descr.ext_evt.lang_code",
3792 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3795 { &hf_mpeg_descr_extended_event_length_of_items, {
3796 "Length of items", "mpeg_descr.ext_evt.items_len",
3797 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3800 { &hf_mpeg_descr_extended_event_item_description_length, {
3801 "Item Description Length", "mpeg_descr.ext_evt.item_descr_len",
3802 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3805 { &hf_mpeg_descr_extended_event_item_description_char, {
3806 "Item Description", "mpeg_descr.ext_evt.item_descr",
3807 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3810 { &hf_mpeg_descr_extended_event_item_length, {
3811 "Item Length", "mpeg_descr.ext_evt.item_len",
3812 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3815 { &hf_mpeg_descr_extended_event_item_char, {
3816 "Item", "mpeg_descr.ext_evt.item",
3817 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3820 { &hf_mpeg_descr_extended_event_text_length, {
3821 "Text Length", "mpeg_descr.ext_evt.txt_len",
3822 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3825 { &hf_mpeg_descr_extended_event_text_encoding, {
3826 "Text Encoding", "mpeg_descr.ext_evt.txt_enc",
3827 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
3830 { &hf_mpeg_descr_extended_event_text, {
3831 "Text", "mpeg_descr.ext_evt.txt",
3832 FT_STRING, STR_UNICODE, NULL, 0, NULL, HFILL
3835 /* 0x50 Component Descriptor */
3836 { &hf_mpeg_descr_component_reserved, {
3837 "Reserved", "mpeg_descr.component.reserved",
3838 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_COMPONENT_RESERVED_MASK, NULL, HFILL
3841 { &hf_mpeg_descr_component_stream_content, {
3842 "Stream Content", "mpeg_descr.component.stream_content",
3843 FT_UINT8, BASE_HEX, VALS(mpeg_descr_component_stream_content_vals),
3844 MPEG_DESCR_COMPONENT_STREAM_CONTENT_MASK, NULL, HFILL
3847 { &hf_mpeg_descr_component_type, {
3848 "Component Type", "mpeg_descr.component.type",
3849 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3852 { &hf_mpeg_descr_component_content_type, {
3853 "Stream Content and Component Type", "mpeg_descr.component.content_type",
3854 FT_UINT16, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_component_content_type_vals_ext,
3855 MPEG_DESCR_COMPONENT_CONTENT_TYPE_MASK, NULL, HFILL
3858 { &hf_mpeg_descr_component_tag, {
3859 "Component Tag", "mpeg_descr.component.tag",
3860 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3863 { &hf_mpeg_descr_component_lang_code, {
3864 "Language Code", "mpeg_descr.component.lang_code",
3865 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3868 { &hf_mpeg_descr_component_text, {
3869 "Text", "mpeg_descr.component.text",
3870 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3873 /* 0x52 Stream Identifier Descriptor */
3874 { &hf_mpeg_descr_stream_identifier_component_tag, {
3875 "Component Tag", "mpeg_descr.stream_id.component_tag",
3876 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3879 /* 0x53 CA Identifier Descriptor */
3880 { &hf_mpeg_descr_ca_identifier_system_id, {
3881 "CA System ID", "mpeg_descr.ca_id.sys_id",
3882 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
3885 /* 0x54 Content Descriptor */
3886 { &hf_mpeg_descr_content_nibble, {
3887 "Nibble Level 1 and 2", "mpeg_descr.content.nibble_1_2",
3888 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_content_nibble_vals_ext, 0, NULL, HFILL
3891 { &hf_mpeg_descr_content_nibble_level_1, {
3892 "Nibble Level 1", "mpeg_descr.content.nibble_lvl_1",
3893 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_content_nibble_level_1_vals_ext,
3894 MPEG_DESCR_CONTENT_NIBBLE_LEVEL_1_MASK, NULL, HFILL
3897 { &hf_mpeg_descr_content_nibble_level_2, {
3898 "Nibble Level 2", "mpeg_descr.content.nibble_lvl_2",
3899 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_CONTENT_NIBBLE_LEVEL_2_MASK, NULL, HFILL
3902 { &hf_mpeg_descr_content_user_byte, {
3903 "User Byte", "mpeg_descr.content.user",
3904 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
3907 /* 0x56 Teletext Descriptor */
3908 { &hf_mpeg_descr_teletext_lang_code, {
3909 "Language Code", "mpeg_descr.teletext.lang_code",
3910 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3913 { &hf_mpeg_descr_teletext_type, {
3914 "Teletext Type", "mpeg_descr.teletext.type",
3915 FT_UINT8, BASE_HEX, VALS(mpeg_descr_teletext_type_vals),
3916 MPEG_DESCR_TELETEXT_TYPE_MASK, NULL, HFILL
3919 { &hf_mpeg_descr_teletext_magazine_number, {
3920 "Magazine Number", "mpeg_descr.teletext.magazine_num",
3921 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_TELETEXT_MAGAZINE_NUMBER_MASK, NULL, HFILL
3924 { &hf_mpeg_descr_teletext_page_number, {
3925 "Page Number", "mpeg_descr.teletext.page_num",
3926 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
3929 /* 0x55 Parental Rating Descriptor */
3930 { &hf_mpeg_descr_parental_rating_country_code, {
3931 "Country Code", "mpeg_descr.parental_rating.country_code",
3932 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3935 { &hf_mpeg_descr_parental_rating_rating, {
3936 "Rating", "mpeg_descr.parental_rating.rating",
3937 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_parental_rating_vals_ext, 0, NULL, HFILL
3940 /* 0x58 Local Time Offset Descriptor */
3941 { &hf_mpeg_descr_local_time_offset_country_code, {
3942 "Country Code", "mpeg_descr.local_time_offset.country_code",
3943 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3946 { &hf_mpeg_descr_local_time_offset_region_id, {
3947 "Region ID", "mpeg_descr.local_time_offset.region_id",
3948 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOCAL_TIME_OFFSET_COUNTRY_REGION_ID_MASK, NULL, HFILL
3951 { &hf_mpeg_descr_local_time_offset_reserved, {
3952 "Reserved", "mpeg_descr.local_time_offset.reserved",
3953 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOCAL_TIME_OFFSET_RESERVED_MASK, NULL, HFILL
3956 { &hf_mpeg_descr_local_time_offset_polarity, {
3957 "Time Offset Polarity", "mpeg_descr.local_time_offset.polarity",
3958 FT_UINT8, BASE_HEX, VALS(mpeg_descr_local_time_offset_polarity_vals),
3959 MPEG_DESCR_LOCAL_TIME_OFFSET_POLARITY, NULL, HFILL
3962 { &hf_mpeg_descr_local_time_offset_offset, {
3963 "Local Time Offset", "mpeg_descr.local_time_offset.offset",
3964 FT_RELATIVE_TIME, BASE_NONE, NULL, 0, NULL, HFILL
3967 { &hf_mpeg_descr_local_time_offset_time_of_change, {
3968 "Time of Change", "mpeg_descr.local_time_offset.time_of_change",
3969 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0, NULL, HFILL
3972 { &hf_mpeg_descr_local_time_offset_next_time_offset, {
3973 "Next Time Offset", "mpeg_descr.local_time_offset.next_time_offset",
3974 FT_RELATIVE_TIME, BASE_NONE, NULL, 0, NULL, HFILL
3977 /* 0x59 Subtitling Descriptor */
3978 { &hf_mpeg_descr_subtitling_lang_code, {
3979 "Language Code", "mpeg_descr.subtitling.lang_code",
3980 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
3983 { &hf_mpeg_descr_subtitling_type, {
3984 "Subtitling Type", "mpeg_descr.subtitling.type",
3985 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_subtitling_type_vals_ext, 0, NULL, HFILL
3988 { &hf_mpeg_descr_subtitling_composition_page_id, {
3989 "Composition Page ID", "mpeg_descr.subtitling.composition_page_id",
3990 FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL
3993 { &hf_mpeg_descr_subtitling_ancillary_page_id, {
3994 "Ancillary Page ID", "mpeg_descr.subtitling.ancillary_page_id",
3995 FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL
3998 /* 0x5A Terrestrial Delivery System Descriptor */
3999 { &hf_mpeg_descr_terrestrial_delivery_centre_frequency, {
4000 "Centre Frequency", "mpeg_descr.terr_delivery.centre_freq",
4001 FT_UINT64, BASE_DEC, NULL, 0, NULL, HFILL
4004 { &hf_mpeg_descr_terrestrial_delivery_bandwidth, {
4005 "Bandwidth", "mpeg_descr.terr_delivery.bandwidth",
4006 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_bandwidth_vals),
4007 MPEG_DESCR_TERRESTRIAL_DELIVERY_BANDWIDTH_MASK, NULL, HFILL
4010 { &hf_mpeg_descr_terrestrial_delivery_priority, {
4011 "Priority", "mpeg_descr.terr_delivery.priority",
4012 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_priority_vals),
4013 MPEG_DESCR_TERRESTRIAL_DELIVERY_PRIORITY_MASK, NULL, HFILL
4016 { &hf_mpeg_descr_terrestrial_delivery_time_slicing_indicator, {
4017 "Time Slicing Indicator", "mpeg_descr.terr_delivery.time_slicing_ind",
4018 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_time_slicing_indicator_vals),
4019 MPEG_DESCR_TERRESTRIAL_DELIVERY_TIME_SLICING_INDICATOR_MASK, NULL, HFILL
4022 { &hf_mpeg_descr_terrestrial_delivery_mpe_fec_indicator, {
4023 "MPE-FEC Indicator", "mpeg_descr.terr_delivery.mpe_fec_ind",
4024 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_mpe_fec_indicator_vals),
4025 MPEG_DESCR_TERRESTRIAL_DELIVERY_MPE_FEC_INDICATOR_MASK, NULL, HFILL
4028 { &hf_mpeg_descr_terrestrial_delivery_reserved1, {
4029 "Reserved", "mpeg_descr.terr_delivery.reserved1",
4030 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_TERRESTRIAL_DELIVERY_RESERVED1_MASK, NULL, HFILL
4033 { &hf_mpeg_descr_terrestrial_delivery_constellation, {
4034 "Constellation", "mpeg_descr.terr_delivery.constellation",
4035 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_constellation_vals),
4036 MPEG_DESCR_TERRESTRIAL_DELIVERY_CONSTELLATION_MASK, NULL, HFILL
4039 { &hf_mpeg_descr_terrestrial_delivery_hierarchy_information, {
4040 "Hierarchy Information", "mpeg_descr.terr_delivery.hierarchy_information",
4041 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_hierarchy_information_vals),
4042 MPEG_DESCR_TERRESTRIAL_DELIVERY_HIERARCHY_INFORMATION_MASK, NULL, HFILL
4045 { &hf_mpeg_descr_terrestrial_delivery_code_rate_hp_stream, {
4046 "Code Rate High Priority Stream", "mpeg_descr.terr_delivery.code_rate_hp_stream",
4047 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_code_rate_vals),
4048 MPEG_DESCR_TERRESTRIAL_DELIVERY_CODE_RATE_HP_STREAM_MASK, NULL, HFILL
4051 { &hf_mpeg_descr_terrestrial_delivery_code_rate_lp_stream, {
4052 "Code Rate Low Priority Stream", "mpeg_descr.terr_delivery.code_rate_lp_stream",
4053 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_code_rate_vals),
4054 MPEG_DESCR_TERRESTRIAL_DELIVERY_CODE_RATE_LP_STREAM_MASK, NULL, HFILL
4057 { &hf_mpeg_descr_terrestrial_delivery_guard_interval, {
4058 "Guard Interval", "mpeg_descr.terr_delivery.guard_interval",
4059 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_guard_interval_vals),
4060 MPEG_DESCR_TERRESTRIAL_DELIVERY_GUARD_INTERVAL_MASK, NULL, HFILL
4063 { &hf_mpeg_descr_terrestrial_delivery_transmission_mode, {
4064 "Transmission Mode", "mpeg_descr.terr_delivery.transmission_mode",
4065 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_transmission_mode_vals),
4066 MPEG_DESCR_TERRESTRIAL_DELIVERY_TRANSMISSION_MODE_MASK, NULL, HFILL
4069 { &hf_mpeg_descr_terrestrial_delivery_other_frequency_flag, {
4070 "Other Frequency Flag", "mpeg_descr.terr_delivery.other_freq_flag",
4071 FT_UINT8, BASE_HEX, VALS(mpeg_descr_terrestrial_delivery_other_frequency_flag_vals),
4072 MPEG_DESCR_TERRESTRIAL_DELIVERY_OTHER_FREQUENCY_FLAG_MASK, NULL, HFILL
4075 { &hf_mpeg_descr_terrestrial_delivery_reserved2, {
4076 "Reserved", "mpeg_descr.terr_delivery.reserved2",
4077 FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL
4081 /* 0x5F Private Data Specifier */
4082 { &hf_mpeg_descr_private_data_specifier_id, {
4083 "Private Data Specifier", "mpeg_descr.private_data_specifier.id",
4084 FT_UINT32, BASE_HEX, VALS(mpeg_descr_data_specifier_id_vals), 0, NULL, HFILL
4087 /* 0x64 Data Broadcast Descriptor */
4088 { &hf_mpeg_descr_data_bcast_bcast_id, {
4089 "Data Broadcast ID", "mpeg_descr.data_bcast.id",
4090 FT_UINT16, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_data_bcast_id_vals_ext, 0, NULL, HFILL
4093 { &hf_mpeg_descr_data_bcast_component_tag, {
4094 "Component Tag", "mpeg_descr.data_bcast.component_tag",
4095 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4098 { &hf_mpeg_descr_data_bcast_selector_len, {
4099 "Selector Length", "mpeg_descr.data_bcast.selector_len",
4100 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
4103 { &hf_mpeg_descr_data_bcast_selector_bytes, {
4104 "Selector Bytes", "mpeg_descr.data_bcast.selector_bytes",
4105 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4108 { &hf_mpeg_descr_data_bcast_lang_code, {
4109 "Language Code", "mpeg_descr.data_bcast.lang_code",
4110 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4113 { &hf_mpeg_descr_data_bcast_text_len, {
4114 "Text Length", "mpeg_descr.data_bcast.text_len",
4115 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
4118 { &hf_mpeg_descr_data_bcast_text, {
4119 "Text", "mpeg_descr.data_bcast.text",
4120 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4123 /* 0x66 Data Broadcast ID Descriptor */
4124 { &hf_mpeg_descr_data_bcast_id_bcast_id, {
4125 "Data Broadcast ID", "mpeg_descr.data_bcast_id.id",
4126 FT_UINT16, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_data_bcast_id_vals_ext, 0, NULL, HFILL
4129 { &hf_mpeg_descr_data_bcast_id_id_selector_bytes, {
4130 "ID Selector Bytes", "mpeg_descr.data_bcast_id.id_selector_bytes",
4131 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4134 /* 0x6A AC-3 Descriptor */
4135 { &hf_mpeg_descr_ac3_component_type_flag, {
4136 "Component Type Flag", "mpeg_descr.ac3.component_type_flag",
4137 FT_UINT8, BASE_DEC, VALS(mpeg_descr_ac3_component_type_flag_vals),
4138 MPEG_DESCR_AC3_COMPONENT_TYPE_FLAG_MASK, NULL, HFILL
4141 { &hf_mpeg_descr_ac3_bsid_flag, {
4142 "BSID Flag", "mpeg_descr.ac3.bsid_flag",
4143 FT_UINT8, BASE_DEC, VALS(mpeg_descr_ac3_bsid_flag_vals),
4144 MPEG_DESCR_AC3_BSID_FLAG_MASK, NULL, HFILL
4147 { &hf_mpeg_descr_ac3_mainid_flag, {
4148 "Main ID Flag", "mpeg_descr.ac3_main_id_flag",
4149 FT_UINT8, BASE_DEC, VALS(mpeg_descr_ac3_mainid_flag_vals),
4150 MPEG_DESCR_AC3_MAINID_FLAG_MASK, NULL, HFILL
4153 { &hf_mpeg_descr_ac3_asvc_flag, {
4154 "ASVC Flag", "mpeg_descr.ac3.asvc_flag",
4155 FT_UINT8, BASE_DEC, VALS(mpeg_descr_ac3_asvc_flag_vals),
4156 MPEG_DESCR_AC3_ASVC_FLAG_MASK, NULL, HFILL
4159 { &hf_mpeg_descr_ac3_reserved, {
4160 "Reserved", "mpeg_descr.ac3.reserved",
4161 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_RESERVED_MASK, NULL, HFILL
4164 { &hf_mpeg_descr_ac3_component_type_reserved_flag, {
4165 "Type Reserved Flag", "mpeg_descr.ac3.component_type.reserved_flag",
4166 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_COMPONENT_TYPE_RESERVED_FLAG_MASK, NULL, HFILL
4169 { &hf_mpeg_descr_ac3_component_type_full_service_flag, {
4170 "Full Service Flag", "mpeg_descr.ac3.component_type.full_service_flag",
4171 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_component_type_full_service_flag_vals),
4172 MPEG_DESCR_AC3_COMPONENT_TYPE_FULL_SERVICE_FLAG_MASK, NULL, HFILL
4175 { &hf_mpeg_descr_ac3_component_type_service_type_flags, {
4176 "Service Type Flags", "mpeg_descr.ac3.component_type.service_type_flags",
4177 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_component_type_service_type_flags_vals),
4178 MPEG_DESCR_AC3_COMPONENT_TYPE_SERVICE_TYPE_FLAGS_MASK, NULL, HFILL
4181 { &hf_mpeg_descr_ac3_component_type_number_of_channels_flags, {
4182 "Number of Channels Flags", "mpeg_descr.ac3.component_type.number_chan_flags",
4183 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_component_type_number_of_channels_flags_vals),
4184 MPEG_DESCR_AC3_COMPONENT_TYPE_NUMBER_OF_CHANNELS_FLAGS, NULL, HFILL
4187 { &hf_mpeg_descr_ac3_bsid, {
4188 "BSID", "mpeg_descr.ac3.bsid",
4189 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4192 { &hf_mpeg_descr_ac3_mainid, {
4193 "Main ID", "mpeg_descr.ac3.mainid",
4194 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4197 { &hf_mpeg_descr_ac3_asvc, {
4198 "ASVC", "mpeg_descr.ac3.asvc",
4199 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4202 { &hf_mpeg_descr_ac3_additional_info, {
4203 "Additional Info", "mpeg_descr.ac3.additional_info",
4204 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4207 /* 0x6F Application Signalling Descriptor */
4208 { &hf_mpeg_descr_app_sig_app_type, {
4209 "Application type", "mpeg_descr.app_sig.app_type",
4210 FT_UINT16, BASE_HEX, NULL, 0x7FFF, NULL, HFILL
4213 { &hf_mpeg_descr_app_sig_ait_ver, {
4214 "AIT version", "mpeg_descr.app_sig.ait_ver",
4215 FT_UINT8, BASE_HEX, NULL, 0x3F, NULL, HFILL
4218 /* 0x73 Default Authority Descriptor */
4219 { &hf_mpeg_descr_default_authority_name, {
4220 "Default Authority Name", "mpeg_descr.default_authority.name",
4221 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4224 /* 0x77 Content Identifier Descriptor */
4225 { &hf_mpeg_descr_content_identifier_crid_type, {
4226 "CRID Type", "mpeg_descr.content_identifier.crid_type",
4227 FT_UINT8, BASE_HEX, VALS(mpeg_descr_content_identifier_crid_type_vals),
4228 MPEG_DESCR_CONTENT_IDENTIFIER_CRID_TYPE_MASK, NULL, HFILL
4231 { &hf_mpeg_descr_content_identifier_crid_location, {
4232 "CRID Location", "mpeg_descr.content_identifier.crid_location",
4233 FT_UINT8, BASE_HEX, VALS(mpeg_descr_content_identifier_crid_location_vals),
4234 MPEG_DESCR_CONTENT_IDENTIFIER_CRID_LOCATION_MASK, NULL, HFILL
4237 { &hf_mpeg_descr_content_identifier_crid_length, {
4238 "CRID Length", "mpeg_descr.content_identifier.crid_len",
4239 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
4242 { &hf_mpeg_descr_content_identifier_crid_bytes, {
4243 "CRID Bytes", "mpeg_descr.content_identifier.crid_bytes",
4244 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4247 { &hf_mpeg_descr_content_identifier_cird_ref, {
4248 "CRID Reference", "mpeg_descr.content_identifier.crid_ref",
4249 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4252 /* 0x7F Extension Descriptor */
4253 { &hf_mpeg_descr_extension_tag_extension, {
4254 "Descriptor Tag Extension", "mpeg_descr.ext.tag",
4255 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_extension_tag_extension_vals_ext, 0, NULL, HFILL
4258 { &hf_mpeg_descr_extension_data, {
4259 "Descriptor Extension Data", "mpeg_descr.ext.data",
4260 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4263 /* Supplementary Audio Descriptor (part of Extension Descriptor) */
4264 { &hf_mpeg_descr_extension_supp_audio_mix_type, {
4265 "Mix type", "mpeg_descr.ext.supp_audio.mix_type",
4266 FT_UINT8, BASE_HEX, VALS(supp_audio_mix_type_vals), 0x80, NULL, HFILL
4269 { &hf_mpeg_descr_extension_supp_audio_ed_cla, {
4270 "Editorial classification", "mpeg_descr.ext.supp_audio.ed_cla",
4271 FT_UINT8, BASE_HEX, VALS(supp_audio_ed_cla), 0x7C, NULL, HFILL
4274 { &hf_mpeg_descr_extension_supp_audio_lang_code_present, {
4275 "Language code present", "mpeg_descr.ext.supp_audio.lang_code_present",
4276 FT_UINT8, BASE_HEX, NULL, 0x01, NULL, HFILL
4279 { &hf_mpeg_descr_extension_supp_audio_lang_code, {
4280 "ISO 639 language code", "mpeg_descr.ext.supp_audio.lang_code",
4281 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4284 { &hf_mpeg_descr_private_data, {
4285 "Private data", "mpeg_descr.private_data",
4286 FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL
4289 /* 0x81 ATSC A/52 AC-3 Descriptor */
4290 { &hf_mpeg_descr_ac3_sysa_srate, {
4291 "Sample Rate", "mpeg_descr.ac3.sysa_sample_rate",
4292 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_srate_flag_vals),
4293 MPEG_DESCR_AC3_SYSA_SRATE_MASK, NULL, HFILL
4296 { &hf_mpeg_descr_ac3_sysa_bsid, {
4297 "bsid", "mpeg_descr.ac3.sysa_bsid",
4298 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_BSID_MASK, NULL, HFILL
4301 { &hf_mpeg_descr_ac3_sysa_bitrate_limit, {
4302 "Bitrate Code limit type", "mpeg_descr.ac3.sysa_bitrate_code_limit",
4303 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_bitrate_code_limit_vals),
4304 MPEG_DESCR_AC3_SYSA_BITRATE_CODE_LIMIT_MASK, NULL, HFILL
4307 { &hf_mpeg_descr_ac3_sysa_bitrate, {
4308 "Bitrate Code", "mpeg_descr.ac3.sysa_bitrate_code",
4309 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_bitrate_code_vals),
4310 MPEG_DESCR_AC3_SYSA_BITRATE_CODE_MASK, NULL, HFILL
4313 { &hf_mpeg_descr_ac3_sysa_surround, {
4314 "Surround Mode", "mpeg_descr.ac3.sysa_surround_mode",
4315 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_surround_mode_vals),
4316 MPEG_DESCR_AC3_SYSA_SURROUND_MODE_MASK, NULL, HFILL
4319 { &hf_mpeg_descr_ac3_sysa_bsmod, {
4320 "Bsmod", "mpeg_descr.ac3.sysa_bsmod",
4321 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_BSMOD_MASK, NULL, HFILL
4324 { &hf_mpeg_descr_ac3_sysa_num_channels, {
4325 "Number of Channels", "mpeg_descr.ac3.sysa_num_channels",
4326 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_num_channels_vals),
4327 MPEG_DESCR_AC3_SYSA_NUM_CHANNELS_MASK, NULL, HFILL
4330 { &hf_mpeg_descr_ac3_sysa_full_svc, {
4331 "Full Service", "mpeg_descr.ac3.sysa_full_svc",
4332 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_FULL_SVC_MASK, NULL, HFILL
4335 { &hf_mpeg_descr_ac3_sysa_langcode, {
4336 "Language Code (Deprecated)", "mpeg_descr.ac3.sysa_langcode",
4337 FT_UINT8, BASE_HEX, NULL, 0xff, NULL, HFILL
4340 { &hf_mpeg_descr_ac3_sysa_langcode2, {
4341 "Language Code 2 (Deprecated)", "mpeg_descr.ac3.sysa_langcode2",
4342 FT_UINT8, BASE_HEX, NULL, 0xff, NULL, HFILL
4345 { &hf_mpeg_descr_ac3_sysa_mainid, {
4346 "Main ID", "mpeg_descr.ac3.sysa_mainid",
4347 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_MAINID_MASK, NULL, HFILL
4350 { &hf_mpeg_descr_ac3_sysa_priority, {
4351 "Priority", "mpeg_descr.ac3.sysa_priority",
4352 FT_UINT8, BASE_HEX, VALS(mpeg_descr_ac3_sysa_priority_vals),
4353 MPEG_DESCR_AC3_SYSA_PRIORITY_MASK, NULL, HFILL
4356 { &hf_mpeg_descr_ac3_sysa_reserved, {
4357 "Reserved", "mpeg_descr.ac3.sysa_reserved",
4358 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_RESERVED_MASK, NULL, HFILL
4361 { &hf_mpeg_descr_ac3_sysa_asvcflags, {
4362 "Associated Service Flags", "mpeg_descr.ac3.sysa_asvcflags",
4363 FT_UINT8, BASE_HEX, NULL, 0xff, NULL, HFILL
4366 { &hf_mpeg_descr_ac3_sysa_textlen, {
4367 "Text length", "mpeg_descr.ac3.sysa_textlen",
4368 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_TEXTLEN_MASK, NULL, HFILL
4371 { &hf_mpeg_descr_ac3_sysa_textcode, {
4372 "Text Code", "mpeg_descr.ac3.sysa_textcode",
4373 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_TEXTCODE_MASK, NULL, HFILL
4376 { &hf_mpeg_descr_ac3_sysa_lang1, {
4377 "Language 1 Present", "mpeg_descr.ac3.sysa_lang1",
4378 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_LANG1_MASK, NULL, HFILL
4381 { &hf_mpeg_descr_ac3_sysa_lang2, {
4382 "Language 2 Present", "mpeg_descr.ac3.sysa_lang2",
4383 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_AC3_SYSA_LANG2_MASK, NULL, HFILL
4386 { &hf_mpeg_descr_ac3_sysa_lang1_bytes, {
4387 "Language 1 ISO 639 language code", "mpeg_descr.ac3.sysa_lang1_bytes",
4388 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4391 { &hf_mpeg_descr_ac3_sysa_lang2_bytes, {
4392 "Language 2 ISO 639 language code", "mpeg_descr.ac3.sysa_lang2_bytes",
4393 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4396 /* 0xA2 Logon Initialize Descriptor */
4397 { &hf_mpeg_descr_logon_initialize_group_id, {
4398 "Group ID", "mpeg_descr.logon_init.group_id",
4399 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4402 { &hf_mpeg_descr_logon_initialize_logon_id, {
4403 "Logon ID", "mpeg_descr.logon_init.logon_id",
4404 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4407 { &hf_mpeg_descr_logon_initialize_continuous_carrier_reserved, {
4408 "Continuous Carrier Reserved", "mpeg_descr.logon_init.continuous_carrier_reserved",
4409 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_CONTINUOUS_CARRIER_RESERVED_MASK, NULL, HFILL
4412 { &hf_mpeg_descr_logon_initialize_continuous_carrier, {
4413 "Continuous Carrier", "mpeg_descr.logon_init.continuous_carrier",
4414 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_CONTINUOUS_CARRIER_MASK, NULL, HFILL
4417 { &hf_mpeg_descr_logon_initialize_security_handshake_required, {
4418 "Security Handshake Required", "mpeg_descr.logon_init.security_handshake_required",
4419 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_SECURITY_HANDSHAKE_REQUIRED_MASK, NULL, HFILL
4422 { &hf_mpeg_descr_logon_initialize_prefix_flag, {
4423 "Prefix Flag", "mpeg_descr.logon_init.prefix_flag",
4424 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_PREFIX_FLAG_MASK, NULL, HFILL
4427 { &hf_mpeg_descr_logon_initialize_data_unit_labelling_flag, {
4428 "Unit Labelling Flag", "mpeg_descr.logon_init.data_unit_labelling_flag",
4429 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_DATA_UNIT_LABELLING_FLAG_MASK, NULL, HFILL
4432 { &hf_mpeg_descr_logon_initialize_mini_slot_flag, {
4433 "Mini Slot Flag", "mpeg_descr.logon_init.mini_slot_flag",
4434 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_MINI_SLOT_FLAG_MASK, NULL, HFILL
4437 { &hf_mpeg_descr_logon_initialize_contention_based_mini_slot_flag, {
4438 "Contention Based Mini Slot Flag", "mpeg_descr.logon_init.contention_based_mini_slot_flag",
4439 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_CONTENTION_BASED_MINI_SLOT_FLAG_MASK, NULL, HFILL
4442 { &hf_mpeg_descr_logon_initialize_capacity_type_flag_reserved, {
4443 "Capacity Type Flag Reserved", "mpeg_descr.logon_init.capactity_type_flag_reserved",
4444 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_CAPACITY_TYPE_FLAG_RESERVED_MASK, NULL, HFILL
4447 { &hf_mpeg_descr_logon_initialize_capacity_type_flag, {
4448 "Capacity Type Flag", "mpeg_descr.logon_init.capactity_type_flag",
4449 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_CAPACITY_TYPE_FLAG_MASK, NULL, HFILL
4452 { &hf_mpeg_descr_logon_initialize_traffic_burst_type, {
4453 "Traffic Burst Type", "mpeg_descr.logon_init.traffic_burst_type",
4454 FT_UINT8, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_TRAFFIC_BURST_TYPE_MASK, NULL, HFILL
4457 { &hf_mpeg_descr_logon_initialize_return_trf_pid, {
4458 "Return TRF PID", "mpeg_descr.logon_init.return_trf_pid",
4459 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_TRF_PID_MASK, NULL, HFILL
4462 { &hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid_reserved, {
4463 "Return CTRL MNGM PID Reserved", "mpeg_descr.logon_init.return_mngm_pid_reserved",
4464 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_CTRL_MNGM_PID_RESERVED_MASK, NULL, HFILL
4467 { &hf_mpeg_descr_logon_initialize_return_ctrl_mngm_pid, {
4468 "Return CTRL MNGM PID", "mpeg_descr.logon_init.return_mngm_pid",
4469 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_CTRL_MNGM_PID_MASK, NULL, HFILL
4472 { &hf_mpeg_descr_logon_initialize_connectivity, {
4473 "Connectivity", "mpeg_descr.logon_init.connectivity",
4474 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_CONNECTIVITY_MASK, NULL, HFILL
4477 { &hf_mpeg_descr_logon_initialize_return_vpi_reserved, {
4478 "Return VPI Reserved", "mpeg_descr.logon_init.return_vpi_reserved",
4479 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_VPI_RESERVED_MASK, NULL, HFILL
4482 { &hf_mpeg_descr_logon_initialize_return_vpi, {
4483 "Return VPI", "mpeg_descr.logon_init.return_vpi",
4484 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_VPI_MASK, NULL, HFILL
4487 { &hf_mpeg_descr_logon_initialize_return_vci, {
4488 "Return VCI", "mpeg_descr.logon_init.return_vci",
4489 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4492 { &hf_mpeg_descr_logon_initialize_return_signalling_vpi_reserved, {
4493 "Return Signalling VPI Reserved", "mpeg_descr.logon_init.return_signalling_vpi_reserved",
4494 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_RESERVED_MASK, NULL, HFILL
4497 { &hf_mpeg_descr_logon_initialize_return_signalling_vpi, {
4498 "Return Signalling VPI", "mpeg_descr.logon_init.return_signalling_vpi",
4499 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_MASK, NULL, HFILL
4502 { &hf_mpeg_descr_logon_initialize_return_signalling_vci, {
4503 "Return Signalling VCI", "mpeg_descr.logon_init.return_signalling_vci",
4504 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4507 { &hf_mpeg_descr_logon_initialize_forward_signalling_vpi_reserved, {
4508 "Forward Signalling VPI Reserved", "mpeg_descr.logon_init.forward_signalling_vpi_reserved",
4509 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_RESERVED_MASK, NULL, HFILL
4512 { &hf_mpeg_descr_logon_initialize_forward_signalling_vpi, {
4513 "Forward Signalling VPI", "mpeg_descr.logon_init.forward_signalling_vpi",
4514 FT_UINT8, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_RETURN_SIGNALLING_VPI_MASK, NULL, HFILL
4517 { &hf_mpeg_descr_logon_initialize_forward_signalling_vci, {
4518 "Forward Signalling VCI", "mpeg_descr.logon_init.forward_signalling_vci",
4519 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4522 { &hf_mpeg_descr_logon_initialize_cra_level, {
4523 "CRA Level", "mpeg_descr.logon_init.cra_level",
4524 FT_UINT24, BASE_DEC, NULL, 0, NULL, HFILL
4527 { &hf_mpeg_descr_logon_initialize_vbdc_max_reserved, {
4528 "VDBC Max Reserved", "mpeg_descr.logon_init.vdbc_max_reserved",
4529 FT_UINT16, BASE_HEX, NULL, MPEG_DESCR_LOGON_INITIALIZE_VDBC_MAX_RESERVED_MASK, NULL, HFILL
4532 { &hf_mpeg_descr_logon_initialize_vbdc_max, {
4533 "VDBC Max", "mpeg_descr.logon_init.vdbc_max",
4534 FT_UINT16, BASE_DEC, NULL, MPEG_DESCR_LOGON_INITIALIZE_VDBC_MAX_MASK, NULL, HFILL
4537 { &hf_mpeg_descr_logon_initialize_rbdc_max, {
4538 "RDBC Max", "mpeg_descr.logon_init.rdbc_max",
4539 FT_UINT24, BASE_DEC, NULL, 0, NULL, HFILL
4542 { &hf_mpeg_descr_logon_initialize_rbdc_timeout, {
4543 "RDBC Timeout", "mpeg_descr.logon_init.rdbc_timeout",
4544 FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL
4547 /* 0xA7 RCS Content Descriptor */
4548 { &hf_mpeg_descr_rcs_content_table_id, {
4549 "Table ID", "mpeg_descr.rcs_content.tid",
4550 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4553 /* 0xCB CI+ Content Label Descriptor */
4554 { &hf_mpeg_descr_ciplus_cl_cb_min, {
4555 "Content byte minimum value", "mpeg_descr.ciplus_content_label.content_byte_min",
4556 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4559 { &hf_mpeg_descr_ciplus_cl_cb_max, {
4560 "Content byte maximum value", "mpeg_descr.ciplus_content_label.content_byte_max",
4561 FT_UINT8, BASE_HEX, NULL, 0, NULL, HFILL
4564 { &hf_mpeg_descr_ciplus_cl_lang, {
4565 "ISO 639 language code", "mpeg_descr.ciplus_content_label.lang_code",
4566 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4569 { &hf_mpeg_descr_ciplus_cl_label, {
4570 "Content label", "mpeg_descr.ciplus_content_label.label",
4571 FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4574 /* 0xCC CI+ Service Descriptor */
4575 { &hf_mpeg_descr_ciplus_svc_id, {
4576 "Service ID", "mpeg_descr.ciplus_svc.id",
4577 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4580 { &hf_mpeg_descr_ciplus_svc_type, {
4581 "Service type", "mpeg_descr.ciplus_svc.type",
4582 FT_UINT8, BASE_HEX | BASE_EXT_STRING, &mpeg_descr_service_type_vals_ext, 0, NULL, HFILL
4585 { &hf_mpeg_descr_ciplus_svc_visible, {
4586 "Visible Service Flag", "mpeg_descr.ciplus_svc.visible",
4587 FT_UINT16, BASE_HEX, NULL, 0x8000, NULL, HFILL
4590 { &hf_mpeg_descr_ciplus_svc_selectable, {
4591 "Selectable Service Flag", "mpeg_descr.ciplus_svc.selectable",
4592 FT_UINT16, BASE_HEX, NULL, 0x4000, NULL, HFILL
4595 { &hf_mpeg_descr_ciplus_svc_lcn, {
4596 "Logical Channel Number", "mpeg_descr.ciplus_svc.lcn",
4597 FT_UINT16, BASE_DEC, NULL, 0x3FFF, NULL, HFILL
4600 { &hf_mpeg_descr_ciplus_svc_prov_name, {
4601 "Service Provider Name", "mpeg_descr.ciplus_svc.provider_name",
4602 FT_UINT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4605 { &hf_mpeg_descr_ciplus_svc_name, {
4606 "Service Name", "mpeg_descr.ciplus_svc.name",
4607 FT_UINT_STRING, BASE_NONE, NULL, 0, NULL, HFILL
4610 { &hf_mpeg_descr_ciplus_prot_free_ci_mode, {
4611 "Free CI mode", "mpeg_descr.ciplus_prot.free_ci_mode",
4612 FT_BOOLEAN, 8, TFS(&tfs_prot_noprot), 0x80, NULL, HFILL
4615 { &hf_mpeg_descr_ciplus_prot_match_brand_flag, {
4616 "Match brand flag", "mpeg_descr.ciplus_prot.match_brand_flag",
4617 FT_BOOLEAN, 8, TFS(&tfs_enabled_disabled), 0x40, NULL, HFILL
4620 { &hf_mpeg_descr_ciplus_prot_num_entries, {
4621 "Number of entries", "mpeg_descr.ciplus_prot.num_entries",
4622 FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL
4625 { &hf_mpeg_descr_ciplus_prot_brand_id, {
4626 "CICAM brand identifier", "mpeg_descr.ciplus_prot.brand_id",
4627 FT_UINT16, BASE_HEX, NULL, 0, NULL, HFILL
4631 static gint *ett[] = {
4632 &ett_mpeg_descriptor,
4633 &ett_mpeg_descriptor_extended_event_item,
4634 &ett_mpeg_descriptor_component_content_type,
4635 &ett_mpeg_descriptor_content_nibble,
4636 &ett_mpeg_descriptor_vbi_data_service,
4637 &ett_mpeg_descriptor_content_identifier_crid,
4638 &ett_mpeg_descriptor_service_list,
4639 &ett_mpeg_descriptor_ac3_component_type,
4640 &ett_mpeg_descriptor_linkage_population_id
4643 proto_mpeg_descriptor = proto_register_protocol("MPEG2 Descriptors", "MPEG Descriptor", "mpeg_descr");
4644 proto_register_field_array(proto_mpeg_descriptor, hf, array_length(hf));
4645 proto_register_subtree_array(ett, array_length(ett));
4650 * Editor modelines - http://www.wireshark.org/tools/modelines.html
4655 * indent-tabs-mode: nil
4658 * vi: set shiftwidth=4 tabstop=8 expandtab:
4659 * :indentSize=4:tabSize=8:noTabs=true: