21 function getid3_quicktime(&$fd, &$ThisFileInfo, $ReturnAtomData=
true, $ParseAllPossibleAtoms=
false) {
23 $ThisFileInfo[
'fileformat'] =
'quicktime';
24 $ThisFileInfo[
'quicktime'][
'hinting'] =
false;
26 fseek($fd, $ThisFileInfo[
'avdataoffset'], SEEK_SET);
31 while ($offset < $ThisFileInfo[
'avdataend']) {
32 fseek($fd, $offset, SEEK_SET);
33 $AtomHeader = fread($fd, 8);
36 $atomname = substr($AtomHeader, 4, 4);
37 $ThisFileInfo[
'quicktime'][$atomname][
'name'] = $atomname;
38 $ThisFileInfo[
'quicktime'][$atomname][
'size'] = $atomsize;
39 $ThisFileInfo[
'quicktime'][$atomname][
'offset'] = $offset;
41 if (($offset + $atomsize) > $ThisFileInfo[
'avdataend']) {
42 $ThisFileInfo[
'error'][] =
'Atom at offset '.$offset.
' claims to go beyond end-of-file (length: '.$atomsize.
' bytes)';
55 if (($atomsize > 8) && (!isset($ThisFileInfo[
'avdataend_tmp']) || ($ThisFileInfo[
'quicktime'][$atomname][
'size'] > ($ThisFileInfo[
'avdataend_tmp'] - $ThisFileInfo[
'avdataoffset'])))) {
57 $ThisFileInfo[
'avdataoffset'] = $ThisFileInfo[
'quicktime'][$atomname][
'offset'] + 8;
58 $OldAVDataEnd = $ThisFileInfo[
'avdataend'];
59 $ThisFileInfo[
'avdataend'] = $ThisFileInfo[
'quicktime'][$atomname][
'offset'] + $ThisFileInfo[
'quicktime'][$atomname][
'size'];
63 if (isset($ThisFileInfo[
'mpeg'][
'audio'])) {
64 $ThisFileInfo[
'audio'][
'dataformat'] =
'mp3';
65 $ThisFileInfo[
'audio'][
'codec'] = (!empty($ThisFileInfo[
'mpeg'][
'audio'][
'encoder']) ? $ThisFileInfo[
'mpeg'][
'audio'][
'encoder'] : (!empty($ThisFileInfo[
'mpeg'][
'audio'][
'codec']) ? $ThisFileInfo[
'mpeg'][
'audio'][
'codec'] : (!empty($ThisFileInfo[
'mpeg'][
'audio'][
'LAME']) ?
'LAME' :
'mp3')));
66 $ThisFileInfo[
'audio'][
'sample_rate'] = $ThisFileInfo[
'mpeg'][
'audio'][
'sample_rate'];
67 $ThisFileInfo[
'audio'][
'channels'] = $ThisFileInfo[
'mpeg'][
'audio'][
'channels'];
68 $ThisFileInfo[
'audio'][
'bitrate'] = $ThisFileInfo[
'mpeg'][
'audio'][
'bitrate'];
69 $ThisFileInfo[
'audio'][
'bitrate_mode'] = strtolower($ThisFileInfo[
'mpeg'][
'audio'][
'bitrate_mode']);
70 $ThisFileInfo[
'bitrate'] = $ThisFileInfo[
'audio'][
'bitrate'];
73 $ThisFileInfo[
'avdataend'] = $OldAVDataEnd;
86 $atomHierarchy = array();
87 $ThisFileInfo[
'quicktime'][$atomname] = $this->
QuicktimeParseAtom($atomname, $atomsize, fread($fd, $atomsize), $ThisFileInfo, $offset, $atomHierarchy, $ParseAllPossibleAtoms);
95 if (!empty($ThisFileInfo[
'avdataend_tmp'])) {
98 $ThisFileInfo[
'avdataend'] = $ThisFileInfo[
'avdataend_tmp'];
99 unset($ThisFileInfo[
'avdataend_tmp']);
102 if (!isset($ThisFileInfo[
'bitrate']) && isset($ThisFileInfo[
'playtime_seconds'])) {
103 $ThisFileInfo[
'bitrate'] = (($ThisFileInfo[
'avdataend'] - $ThisFileInfo[
'avdataoffset']) * 8) / $ThisFileInfo[
'playtime_seconds'];
105 if (isset($ThisFileInfo[
'bitrate']) && !isset($ThisFileInfo[
'audio'][
'bitrate']) && !isset($ThisFileInfo[
'quicktime'][
'video'])) {
106 $ThisFileInfo[
'audio'][
'bitrate'] = $ThisFileInfo[
'bitrate'];
109 if (($ThisFileInfo[
'audio'][
'dataformat'] ==
'mp4') && empty($ThisFileInfo[
'video'][
'resolution_x'])) {
110 $ThisFileInfo[
'fileformat'] =
'mp4';
111 $ThisFileInfo[
'mime_type'] =
'audio/mp4';
112 unset($ThisFileInfo[
'video'][
'dataformat']);
115 if (!$ReturnAtomData) {
116 unset($ThisFileInfo[
'quicktime'][
'moov']);
119 if (empty($ThisFileInfo[
'audio'][
'dataformat']) && !empty($ThisFileInfo[
'quicktime'][
'audio'])) {
120 $ThisFileInfo[
'audio'][
'dataformat'] =
'quicktime';
122 if (empty($ThisFileInfo[
'video'][
'dataformat']) && !empty($ThisFileInfo[
'quicktime'][
'video'])) {
123 $ThisFileInfo[
'video'][
'dataformat'] =
'quicktime';
129 function QuicktimeParseAtom($atomname, $atomsize, $atomdata, &$ThisFileInfo, $baseoffset, &$atomHierarchy, $ParseAllPossibleAtoms) {
132 array_push($atomHierarchy, $atomname);
133 $atomstructure[
'hierarchy'] = implode(
' ', $atomHierarchy);
134 $atomstructure[
'name'] = $atomname;
135 $atomstructure[
'size'] = $atomsize;
136 $atomstructure[
'offset'] = $baseoffset;
154 $atomstructure[
'subatoms'] = $this->
QuicktimeParseContainerAtom($atomdata, $ThisFileInfo, $baseoffset + 8, $atomHierarchy, $ParseAllPossibleAtoms);
196 $atomstructure[
'data'] = substr($atomdata, 4);
199 if (empty($ThisFileInfo[
'comments'][
'language']) || (!in_array($atomstructure[
'language'], $ThisFileInfo[
'comments'][
'language']))) {
200 $ThisFileInfo[
'comments'][
'language'][] = $atomstructure[
'language'];
209 $ThisFileInfo[
'quicktime'][
'autoplay'] = $atomstructure[
'autoplay'];
230 $atomstructure[
'data'] = $atomdata;
239 $CompressedFileData = substr($atomdata, 4);
240 if ($UncompressedHeader = @gzuncompress($CompressedFileData)) {
241 $atomstructure[
'subatoms'] = $this->
QuicktimeParseContainerAtom($UncompressedHeader, $ThisFileInfo, 0, $atomHierarchy, $ParseAllPossibleAtoms);
243 $ThisFileInfo[
'warning'][] =
'Error decompressing compressed MOV atom at offset '.$atomstructure[
'offset'];
249 $atomstructure[
'compression_id'] = $atomdata;
257 $atomstructure[
'flags'][
'internal_data'] = (bool) ($atomstructure[
'flags_raw'] & 0x000001);
259 $atomstructure[
'reference_type_name'] = substr($atomdata, 4, 4);
261 switch ($atomstructure[
'reference_type_name']) {
263 $atomstructure[
'url'] = $this->
NoNullString(substr($atomdata, 12));
267 $atomstructure[
'file_alias'] = substr($atomdata, 12);
271 $atomstructure[
'resource_alias'] = substr($atomdata, 12);
275 $atomstructure[
'data'] = substr($atomdata, 12);
296 $atomstructure[
'gestalt_selector'] = substr($atomdata, 4, 4);
306 $atomstructure[
'component_type'] = substr($atomdata, 4, 4);
307 $atomstructure[
'component_subtype'] = substr($atomdata, 8, 4);
308 $atomstructure[
'component_manufacturer'] = substr($atomdata, 12, 4);
320 $atomstructure[
'data_rate_bps'] = $atomstructure[
'data_rate'] * 10;
330 if (empty($ThisFileInfo[
'comments'][
'language']) || (!in_array($atomstructure[
'language'], $ThisFileInfo[
'comments'][
'language']))) {
331 $ThisFileInfo[
'comments'][
'language'][] = $atomstructure[
'language'];
351 $atomstructure[
'flags'][
'play_on_open'] = (bool) $atomstructure[
'play_on_open_flag'];
352 $atomstructure[
'flags'][
'slide_show'] = (bool) $atomstructure[
'slide_show_flag'];
354 $ptv_lookup[0] =
'normal';
355 $ptv_lookup[1] =
'double';
356 $ptv_lookup[2] =
'half';
357 $ptv_lookup[3] =
'full';
358 $ptv_lookup[4] =
'current';
359 if (isset($ptv_lookup[$atomstructure[
'display_size_raw']])) {
360 $atomstructure[
'display_size'] = $ptv_lookup[$atomstructure[
'display_size_raw']];
362 $ThisFileInfo[
'warning'][] =
'unknown "ptv " display constant ('.$atomstructure[
'display_size_raw'].
')';
371 $stsdEntriesDataOffset = 8;
372 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
373 $atomstructure[
'sample_description_table'][$i][
'size'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stsdEntriesDataOffset, 4));
374 $stsdEntriesDataOffset += 4;
375 $atomstructure[
'sample_description_table'][$i][
'data_format'] = substr($atomdata, $stsdEntriesDataOffset, 4);
376 $stsdEntriesDataOffset += 4;
377 $atomstructure[
'sample_description_table'][$i][
'reserved'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stsdEntriesDataOffset, 6));
378 $stsdEntriesDataOffset += 6;
379 $atomstructure[
'sample_description_table'][$i][
'reference_index'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stsdEntriesDataOffset, 2));
380 $stsdEntriesDataOffset += 2;
381 $atomstructure[
'sample_description_table'][$i][
'data'] = substr($atomdata, $stsdEntriesDataOffset, ($atomstructure[
'sample_description_table'][$i][
'size'] - 4 - 4 - 6 - 2));
382 $stsdEntriesDataOffset += ($atomstructure[
'sample_description_table'][$i][
'size'] - 4 - 4 - 6 - 2);
384 $atomstructure[
'sample_description_table'][$i][
'encoder_version'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 0, 2));
385 $atomstructure[
'sample_description_table'][$i][
'encoder_revision'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 2, 2));
386 $atomstructure[
'sample_description_table'][$i][
'encoder_vendor'] = substr($atomstructure[
'sample_description_table'][$i][
'data'], 4, 4);
388 switch ($atomstructure[
'sample_description_table'][$i][
'encoder_vendor']) {
390 case "\x00\x00\x00\x00":
392 $atomstructure[
'sample_description_table'][$i][
'audio_channels'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 8, 2));
393 $atomstructure[
'sample_description_table'][$i][
'audio_bit_depth'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 10, 2));
394 $atomstructure[
'sample_description_table'][$i][
'audio_compression_id'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 12, 2));
395 $atomstructure[
'sample_description_table'][$i][
'audio_packet_size'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 14, 2));
396 $atomstructure[
'sample_description_table'][$i][
'audio_sample_rate'] =
getid3_lib::FixedPoint16_16(substr($atomstructure[
'sample_description_table'][$i][
'data'], 16, 4));
398 switch ($atomstructure[
'sample_description_table'][$i][
'data_format']) {
400 $ThisFileInfo[
'fileformat'] =
'mp4';
401 $ThisFileInfo[
'error'][] =
'This version ('.GETID3_VERSION.
') of getID3() does not fully support MPEG-4 audio/video streams';
405 $ThisFileInfo[
'video'][
'dataformat'] =
'quicktimevr';
410 $ThisFileInfo[
'quicktime'][
'audio'][
'codec'] = $this->
QuicktimeAudioCodecLookup($atomstructure[
'sample_description_table'][$i][
'data_format']);
411 $ThisFileInfo[
'quicktime'][
'audio'][
'sample_rate'] = $atomstructure[
'sample_description_table'][$i][
'audio_sample_rate'];
412 $ThisFileInfo[
'quicktime'][
'audio'][
'channels'] = $atomstructure[
'sample_description_table'][$i][
'audio_channels'];
413 $ThisFileInfo[
'quicktime'][
'audio'][
'bit_depth'] = $atomstructure[
'sample_description_table'][$i][
'audio_bit_depth'];
414 $ThisFileInfo[
'audio'][
'codec'] = $ThisFileInfo[
'quicktime'][
'audio'][
'codec'];
415 $ThisFileInfo[
'audio'][
'sample_rate'] = $ThisFileInfo[
'quicktime'][
'audio'][
'sample_rate'];
416 $ThisFileInfo[
'audio'][
'channels'] = $ThisFileInfo[
'quicktime'][
'audio'][
'channels'];
417 $ThisFileInfo[
'audio'][
'bits_per_sample'] = $ThisFileInfo[
'quicktime'][
'audio'][
'bit_depth'];
418 switch ($atomstructure[
'sample_description_table'][$i][
'data_format']) {
421 $ThisFileInfo[
'audio'][
'lossless'] =
true;
424 $ThisFileInfo[
'audio'][
'lossless'] =
false;
432 switch ($atomstructure[
'sample_description_table'][$i][
'data_format']) {
434 $ThisFileInfo[
'fileformat'] =
'mp4';
439 $atomstructure[
'sample_description_table'][$i][
'video_temporal_quality'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 8, 4));
440 $atomstructure[
'sample_description_table'][$i][
'video_spatial_quality'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 12, 4));
441 $atomstructure[
'sample_description_table'][$i][
'video_frame_width'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 16, 2));
442 $atomstructure[
'sample_description_table'][$i][
'video_frame_height'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 18, 2));
443 $atomstructure[
'sample_description_table'][$i][
'video_resolution_x'] =
getid3_lib::FixedPoint16_16(substr($atomstructure[
'sample_description_table'][$i][
'data'], 20, 4));
444 $atomstructure[
'sample_description_table'][$i][
'video_resolution_y'] =
getid3_lib::FixedPoint16_16(substr($atomstructure[
'sample_description_table'][$i][
'data'], 24, 4));
445 $atomstructure[
'sample_description_table'][$i][
'video_data_size'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 28, 4));
446 $atomstructure[
'sample_description_table'][$i][
'video_frame_count'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 32, 2));
447 $atomstructure[
'sample_description_table'][$i][
'video_encoder_name_len'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 34, 1));
448 $atomstructure[
'sample_description_table'][$i][
'video_encoder_name'] = substr($atomstructure[
'sample_description_table'][$i][
'data'], 35, $atomstructure[
'sample_description_table'][$i][
'video_encoder_name_len']);
449 $atomstructure[
'sample_description_table'][$i][
'video_pixel_color_depth'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 66, 2));
450 $atomstructure[
'sample_description_table'][$i][
'video_color_table_id'] =
getid3_lib::BigEndian2Int(substr($atomstructure[
'sample_description_table'][$i][
'data'], 68, 2));
452 $atomstructure[
'sample_description_table'][$i][
'video_pixel_color_type'] = (($atomstructure[
'sample_description_table'][$i][
'video_pixel_color_depth'] > 32) ?
'grayscale' :
'color');
453 $atomstructure[
'sample_description_table'][$i][
'video_pixel_color_name'] = $this->
QuicktimeColorNameLookup($atomstructure[
'sample_description_table'][$i][
'video_pixel_color_depth']);
455 if ($atomstructure[
'sample_description_table'][$i][
'video_pixel_color_name'] !=
'invalid') {
456 $ThisFileInfo[
'quicktime'][
'video'][
'codec_fourcc'] = $atomstructure[
'sample_description_table'][$i][
'data_format'];
457 $ThisFileInfo[
'quicktime'][
'video'][
'codec_fourcc_lookup'] = $this->
QuicktimeVideoCodecLookup($atomstructure[
'sample_description_table'][$i][
'data_format']);
458 $ThisFileInfo[
'quicktime'][
'video'][
'codec'] = $atomstructure[
'sample_description_table'][$i][
'video_encoder_name'];
459 $ThisFileInfo[
'quicktime'][
'video'][
'color_depth'] = $atomstructure[
'sample_description_table'][$i][
'video_pixel_color_depth'];
460 $ThisFileInfo[
'quicktime'][
'video'][
'color_depth_name'] = $atomstructure[
'sample_description_table'][$i][
'video_pixel_color_name'];
462 $ThisFileInfo[
'video'][
'codec'] = $ThisFileInfo[
'quicktime'][
'video'][
'codec'];
463 $ThisFileInfo[
'video'][
'bits_per_sample'] = $ThisFileInfo[
'quicktime'][
'video'][
'color_depth'];
465 $ThisFileInfo[
'video'][
'lossless'] =
false;
466 $ThisFileInfo[
'video'][
'pixel_aspect_ratio'] = (float) 1;
471 switch (strtolower($atomstructure[
'sample_description_table'][$i][
'data_format'])) {
473 $ThisFileInfo[
'audio'][
'dataformat'] =
'mp4';
474 $ThisFileInfo[
'quicktime'][
'audio'][
'codec'] =
'mp4';
480 $ThisFileInfo[
'video'][
'dataformat'] =
'3ivx';
484 $ThisFileInfo[
'video'][
'dataformat'] =
'xvid';
488 $ThisFileInfo[
'video'][
'dataformat'] =
'mpeg4';
498 $TDIVXileInfo[
'video'][
'dataformat'] =
'divx';
505 unset($atomstructure[
'sample_description_table'][$i][
'data']);
515 $sttsEntriesDataOffset = 8;
516 $FrameRateCalculatorArray = array();
517 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
518 $atomstructure[
'time_to_sample_table'][$i][
'sample_count'] =
getid3_lib::BigEndian2Int(substr($atomdata, $sttsEntriesDataOffset, 4));
519 $sttsEntriesDataOffset += 4;
520 $atomstructure[
'time_to_sample_table'][$i][
'sample_duration'] =
getid3_lib::BigEndian2Int(substr($atomdata, $sttsEntriesDataOffset, 4));
521 $sttsEntriesDataOffset += 4;
523 if (!empty($ThisFileInfo[
'quicktime'][
'time_scale']) && (@$atomstructure[
'time_to_sample_table'][$i][
'sample_duration'] > 0)) {
524 $stts_new_framerate = $ThisFileInfo[
'quicktime'][
'time_scale'] / $atomstructure[
'time_to_sample_table'][$i][
'sample_duration'];
525 if ($stts_new_framerate <= 60) {
527 $ThisFileInfo[
'video'][
'frame_rate'] = max(@$ThisFileInfo[
'video'][
'frame_rate'], $stts_new_framerate);
554 if ($ParseAllPossibleAtoms) {
558 $stssEntriesDataOffset = 8;
559 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
561 $stssEntriesDataOffset += 4;
568 if ($ParseAllPossibleAtoms) {
572 $stscEntriesDataOffset = 8;
573 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
574 $atomstructure[
'sample_to_chunk_table'][$i][
'first_chunk'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stscEntriesDataOffset, 4));
575 $stscEntriesDataOffset += 4;
576 $atomstructure[
'sample_to_chunk_table'][$i][
'samples_per_chunk'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stscEntriesDataOffset, 4));
577 $stscEntriesDataOffset += 4;
578 $atomstructure[
'sample_to_chunk_table'][$i][
'sample_description'] =
getid3_lib::BigEndian2Int(substr($atomdata, $stscEntriesDataOffset, 4));
579 $stscEntriesDataOffset += 4;
586 if ($ParseAllPossibleAtoms) {
591 $stszEntriesDataOffset = 12;
592 if ($atomstructure[
'sample_size'] == 0) {
593 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
595 $stszEntriesDataOffset += 4;
603 if ($ParseAllPossibleAtoms) {
607 $stcoEntriesDataOffset = 8;
608 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
610 $stcoEntriesDataOffset += 4;
621 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++) {
623 $drefDataOffset += 4;
624 $atomstructure[
'data_references'][$i][
'type'] = substr($atomdata, $drefDataOffset, 4);
625 $drefDataOffset += 4;
627 $drefDataOffset += 1;
629 $drefDataOffset += 3;
630 $atomstructure[
'data_references'][$i][
'data'] = substr($atomdata, $drefDataOffset, ($atomstructure[
'data_references'][$i][
'size'] - 4 - 4 - 1 - 3));
631 $drefDataOffset += ($atomstructure[
'data_references'][$i][
'size'] - 4 - 4 - 1 - 3);
633 $atomstructure[
'data_references'][$i][
'flags'][
'self_reference'] = (bool) ($atomstructure[
'data_references'][$i][
'flags_raw'] & 0x001);
666 $atomstructure[
'flags'][
'no_lean_ahead'] = (bool) ($atomstructure[
'flags_raw'] & 0x001);
673 $atomstructure[
'component_type'] = substr($atomdata, 4, 4);
674 $atomstructure[
'component_subtype'] = substr($atomdata, 8, 4);
675 $atomstructure[
'component_manufacturer'] = substr($atomdata, 12, 4);
678 $atomstructure[
'component_name'] = $this->
Pascal2String(substr($atomdata, 24));
680 if (($atomstructure[
'component_subtype'] ==
'STpn') && ($atomstructure[
'component_manufacturer'] ==
'zzzz')) {
681 $ThisFileInfo[
'video'][
'dataformat'] =
'quicktimevr';
696 if ($atomstructure[
'time_scale'] == 0) {
697 $ThisFileInfo[
'error'][] =
'Corrupt Quicktime file: mdhd.time_scale == zero';
702 $atomstructure[
'playtime_seconds'] = $atomstructure[
'duration'] / $atomstructure[
'time_scale'];
704 if (empty($ThisFileInfo[
'comments'][
'language']) || (!in_array($atomstructure[
'language'], $ThisFileInfo[
'comments'][
'language']))) {
705 $ThisFileInfo[
'comments'][
'language'][] = $atomstructure[
'language'];
713 $atomstructure[
'atom_type'] = substr($atomdata, 6, 4);
723 $atomstructure[
'clipping_data'] = substr($atomdata, 10);
733 $atomstructure[
'default_hints'][
'double_buffer'] = (bool) ($atomstructure[
'default_hints_raw'] & 0x0020);
734 $atomstructure[
'default_hints'][
'high_quality'] = (bool) ($atomstructure[
'default_hints_raw'] & 0x0100);
743 for ($i = 0; $i < (strlen($atomdata) % 4); $i++) {
753 for ($i = 0; $i < $atomstructure[
'number_entries']; $i++ ) {
764 $atomstructure[
'matte_data_raw'] = substr($atomdata, 4);
772 for ($colortableentry = 0; $colortableentry < $atomstructure[
'color_table_size']; $colortableentry++) {
773 $atomstructure[
'color_table'][$colortableentry][
'alpha'] =
getid3_lib::BigEndian2Int(substr($atomdata, 8 + ($colortableentry * 8) + 0, 2));
774 $atomstructure[
'color_table'][$colortableentry][
'red'] =
getid3_lib::BigEndian2Int(substr($atomdata, 8 + ($colortableentry * 8) + 2, 2));
775 $atomstructure[
'color_table'][$colortableentry][
'green'] =
getid3_lib::BigEndian2Int(substr($atomdata, 8 + ($colortableentry * 8) + 4, 2));
776 $atomstructure[
'color_table'][$colortableentry][
'blue'] =
getid3_lib::BigEndian2Int(substr($atomdata, 8 + ($colortableentry * 8) + 6, 2));
790 $atomstructure[
'reserved'] = substr($atomdata, 26, 10);
808 if ($atomstructure[
'time_scale'] == 0) {
809 $ThisFileInfo[
'error'][] =
'Corrupt Quicktime file: mvhd.time_scale == zero';
814 $ThisFileInfo[
'quicktime'][
'time_scale'] = $atomstructure[
'time_scale'];
815 $ThisFileInfo[
'quicktime'][
'display_scale'] = $atomstructure[
'matrix_a'];
816 $ThisFileInfo[
'playtime_seconds'] = $atomstructure[
'duration'] / $atomstructure[
'time_scale'];
845 $atomstructure[
'flags'][
'enabled'] = (bool) ($atomstructure[
'flags_raw'] & 0x0001);
846 $atomstructure[
'flags'][
'in_movie'] = (bool) ($atomstructure[
'flags_raw'] & 0x0002);
847 $atomstructure[
'flags'][
'in_preview'] = (bool) ($atomstructure[
'flags_raw'] & 0x0004);
848 $atomstructure[
'flags'][
'in_poster'] = (bool) ($atomstructure[
'flags_raw'] & 0x0008);
852 if (!isset($ThisFileInfo[
'video'][
'resolution_x']) || !isset($ThisFileInfo[
'video'][
'resolution_y'])) {
853 $ThisFileInfo[
'video'][
'resolution_x'] = $atomstructure[
'width'];
854 $ThisFileInfo[
'video'][
'resolution_y'] = $atomstructure[
'height'];
856 if ($atomstructure[
'flags'][
'enabled'] == 1) {
857 $ThisFileInfo[
'video'][
'resolution_x'] = max($ThisFileInfo[
'video'][
'resolution_x'], $atomstructure[
'width']);
858 $ThisFileInfo[
'video'][
'resolution_y'] = max($ThisFileInfo[
'video'][
'resolution_y'], $atomstructure[
'height']);
860 if (!empty($ThisFileInfo[
'video'][
'resolution_x']) && !empty($ThisFileInfo[
'video'][
'resolution_y'])) {
861 $ThisFileInfo[
'quicktime'][
'video'][
'resolution_x'] = $ThisFileInfo[
'video'][
'resolution_x'];
862 $ThisFileInfo[
'quicktime'][
'video'][
'resolution_y'] = $ThisFileInfo[
'video'][
'resolution_y'];
864 unset($ThisFileInfo[
'video'][
'resolution_x']);
865 unset($ThisFileInfo[
'video'][
'resolution_y']);
866 unset($ThisFileInfo[
'quicktime'][
'video']);
873 $NextTagPosition = strpos($atomdata,
'©');
874 while ($NextTagPosition < strlen($atomdata)) {
876 if ($metaItemSize == -4) {
879 $metaItemRaw = substr($atomdata, $NextTagPosition, $metaItemSize);
880 $metaItemKey = substr($metaItemRaw, 0, 4);
881 $metaItemData = substr($metaItemRaw, 20);
882 $NextTagPosition += $metaItemSize + 4;
889 $atomstructure[
'signature'] = substr($atomdata, 0, 4);
891 $atomstructure[
'fourcc'] = substr($atomdata, 8, 4);
921 $atomstructure[
'ctyp'] = substr($atomdata, 0, 4);
922 switch ($atomstructure[
'ctyp']) {
924 $ThisFileInfo[
'video'][
'dataformat'] =
'quicktimevr';
937 $ThisFileInfo[
'quicktime'][
'hinting'] =
true;
941 for ($i = 0; $i < ($atomstructure[
'size'] - 8); $i += 4) {
952 $atomstructure[
'data'] = $atomdata;
956 $ThisFileInfo[
'warning'][] =
'Unknown QuickTime atom type: "'.$atomname.
'" at offset '.$baseoffset;
957 $atomstructure[
'data'] = $atomdata;
960 array_pop($atomHierarchy);
961 return $atomstructure;
965 $atomstructure =
false;
971 while ($subatomoffset < strlen($atomdata)) {
973 $subatomname = substr($atomdata, $subatomoffset + 4, 4);
974 $subatomdata = substr($atomdata, $subatomoffset + 8, $subatomsize - 8);
975 if ($subatomsize == 0) {
979 return $atomstructure;
982 $atomstructure[$subatomcounter] = $this->
QuicktimeParseAtom($subatomname, $subatomsize, $subatomdata, $ThisFileInfo, $baseoffset + $subatomoffset, $atomHierarchy, $ParseAllPossibleAtoms);
984 $subatomoffset += $subatomsize;
987 return $atomstructure;
992 static $QuicktimeLanguageLookup = array();
993 if (empty($QuicktimeLanguageLookup)) {
994 $QuicktimeLanguageLookup[0] =
'English';
995 $QuicktimeLanguageLookup[1] =
'French';
996 $QuicktimeLanguageLookup[2] =
'German';
997 $QuicktimeLanguageLookup[3] =
'Italian';
998 $QuicktimeLanguageLookup[4] =
'Dutch';
999 $QuicktimeLanguageLookup[5] =
'Swedish';
1000 $QuicktimeLanguageLookup[6] =
'Spanish';
1001 $QuicktimeLanguageLookup[7] =
'Danish';
1002 $QuicktimeLanguageLookup[8] =
'Portuguese';
1003 $QuicktimeLanguageLookup[9] =
'Norwegian';
1004 $QuicktimeLanguageLookup[10] =
'Hebrew';
1005 $QuicktimeLanguageLookup[11] =
'Japanese';
1006 $QuicktimeLanguageLookup[12] =
'Arabic';
1007 $QuicktimeLanguageLookup[13] =
'Finnish';
1008 $QuicktimeLanguageLookup[14] =
'Greek';
1009 $QuicktimeLanguageLookup[15] =
'Icelandic';
1010 $QuicktimeLanguageLookup[16] =
'Maltese';
1011 $QuicktimeLanguageLookup[17] =
'Turkish';
1012 $QuicktimeLanguageLookup[18] =
'Croatian';
1013 $QuicktimeLanguageLookup[19] =
'Chinese (Traditional)';
1014 $QuicktimeLanguageLookup[20] =
'Urdu';
1015 $QuicktimeLanguageLookup[21] =
'Hindi';
1016 $QuicktimeLanguageLookup[22] =
'Thai';
1017 $QuicktimeLanguageLookup[23] =
'Korean';
1018 $QuicktimeLanguageLookup[24] =
'Lithuanian';
1019 $QuicktimeLanguageLookup[25] =
'Polish';
1020 $QuicktimeLanguageLookup[26] =
'Hungarian';
1021 $QuicktimeLanguageLookup[27] =
'Estonian';
1022 $QuicktimeLanguageLookup[28] =
'Lettish';
1023 $QuicktimeLanguageLookup[28] =
'Latvian';
1024 $QuicktimeLanguageLookup[29] =
'Saamisk';
1025 $QuicktimeLanguageLookup[29] =
'Lappish';
1026 $QuicktimeLanguageLookup[30] =
'Faeroese';
1027 $QuicktimeLanguageLookup[31] =
'Farsi';
1028 $QuicktimeLanguageLookup[31] =
'Persian';
1029 $QuicktimeLanguageLookup[32] =
'Russian';
1030 $QuicktimeLanguageLookup[33] =
'Chinese (Simplified)';
1031 $QuicktimeLanguageLookup[34] =
'Flemish';
1032 $QuicktimeLanguageLookup[35] =
'Irish';
1033 $QuicktimeLanguageLookup[36] =
'Albanian';
1034 $QuicktimeLanguageLookup[37] =
'Romanian';
1035 $QuicktimeLanguageLookup[38] =
'Czech';
1036 $QuicktimeLanguageLookup[39] =
'Slovak';
1037 $QuicktimeLanguageLookup[40] =
'Slovenian';
1038 $QuicktimeLanguageLookup[41] =
'Yiddish';
1039 $QuicktimeLanguageLookup[42] =
'Serbian';
1040 $QuicktimeLanguageLookup[43] =
'Macedonian';
1041 $QuicktimeLanguageLookup[44] =
'Bulgarian';
1042 $QuicktimeLanguageLookup[45] =
'Ukrainian';
1043 $QuicktimeLanguageLookup[46] =
'Byelorussian';
1044 $QuicktimeLanguageLookup[47] =
'Uzbek';
1045 $QuicktimeLanguageLookup[48] =
'Kazakh';
1046 $QuicktimeLanguageLookup[49] =
'Azerbaijani';
1047 $QuicktimeLanguageLookup[50] =
'AzerbaijanAr';
1048 $QuicktimeLanguageLookup[51] =
'Armenian';
1049 $QuicktimeLanguageLookup[52] =
'Georgian';
1050 $QuicktimeLanguageLookup[53] =
'Moldavian';
1051 $QuicktimeLanguageLookup[54] =
'Kirghiz';
1052 $QuicktimeLanguageLookup[55] =
'Tajiki';
1053 $QuicktimeLanguageLookup[56] =
'Turkmen';
1054 $QuicktimeLanguageLookup[57] =
'Mongolian';
1055 $QuicktimeLanguageLookup[58] =
'MongolianCyr';
1056 $QuicktimeLanguageLookup[59] =
'Pashto';
1057 $QuicktimeLanguageLookup[60] =
'Kurdish';
1058 $QuicktimeLanguageLookup[61] =
'Kashmiri';
1059 $QuicktimeLanguageLookup[62] =
'Sindhi';
1060 $QuicktimeLanguageLookup[63] =
'Tibetan';
1061 $QuicktimeLanguageLookup[64] =
'Nepali';
1062 $QuicktimeLanguageLookup[65] =
'Sanskrit';
1063 $QuicktimeLanguageLookup[66] =
'Marathi';
1064 $QuicktimeLanguageLookup[67] =
'Bengali';
1065 $QuicktimeLanguageLookup[68] =
'Assamese';
1066 $QuicktimeLanguageLookup[69] =
'Gujarati';
1067 $QuicktimeLanguageLookup[70] =
'Punjabi';
1068 $QuicktimeLanguageLookup[71] =
'Oriya';
1069 $QuicktimeLanguageLookup[72] =
'Malayalam';
1070 $QuicktimeLanguageLookup[73] =
'Kannada';
1071 $QuicktimeLanguageLookup[74] =
'Tamil';
1072 $QuicktimeLanguageLookup[75] =
'Telugu';
1073 $QuicktimeLanguageLookup[76] =
'Sinhalese';
1074 $QuicktimeLanguageLookup[77] =
'Burmese';
1075 $QuicktimeLanguageLookup[78] =
'Khmer';
1076 $QuicktimeLanguageLookup[79] =
'Lao';
1077 $QuicktimeLanguageLookup[80] =
'Vietnamese';
1078 $QuicktimeLanguageLookup[81] =
'Indonesian';
1079 $QuicktimeLanguageLookup[82] =
'Tagalog';
1080 $QuicktimeLanguageLookup[83] =
'MalayRoman';
1081 $QuicktimeLanguageLookup[84] =
'MalayArabic';
1082 $QuicktimeLanguageLookup[85] =
'Amharic';
1083 $QuicktimeLanguageLookup[86] =
'Tigrinya';
1084 $QuicktimeLanguageLookup[87] =
'Galla';
1085 $QuicktimeLanguageLookup[87] =
'Oromo';
1086 $QuicktimeLanguageLookup[88] =
'Somali';
1087 $QuicktimeLanguageLookup[89] =
'Swahili';
1088 $QuicktimeLanguageLookup[90] =
'Ruanda';
1089 $QuicktimeLanguageLookup[91] =
'Rundi';
1090 $QuicktimeLanguageLookup[92] =
'Chewa';
1091 $QuicktimeLanguageLookup[93] =
'Malagasy';
1092 $QuicktimeLanguageLookup[94] =
'Esperanto';
1093 $QuicktimeLanguageLookup[128] =
'Welsh';
1094 $QuicktimeLanguageLookup[129] =
'Basque';
1095 $QuicktimeLanguageLookup[130] =
'Catalan';
1096 $QuicktimeLanguageLookup[131] =
'Latin';
1097 $QuicktimeLanguageLookup[132] =
'Quechua';
1098 $QuicktimeLanguageLookup[133] =
'Guarani';
1099 $QuicktimeLanguageLookup[134] =
'Aymara';
1100 $QuicktimeLanguageLookup[135] =
'Tatar';
1101 $QuicktimeLanguageLookup[136] =
'Uighur';
1102 $QuicktimeLanguageLookup[137] =
'Dzongkha';
1103 $QuicktimeLanguageLookup[138] =
'JavaneseRom';
1105 return (isset($QuicktimeLanguageLookup[$languageid]) ? $QuicktimeLanguageLookup[$languageid] :
'invalid');
1109 static $QuicktimeVideoCodecLookup = array();
1110 if (empty($QuicktimeVideoCodecLookup)) {
1111 $QuicktimeVideoCodecLookup[
'3IVX'] =
'3ivx MPEG-4';
1112 $QuicktimeVideoCodecLookup[
'3IV1'] =
'3ivx MPEG-4 v1';
1113 $QuicktimeVideoCodecLookup[
'3IV2'] =
'3ivx MPEG-4 v2';
1114 $QuicktimeVideoCodecLookup[
'avr '] =
'AVR-JPEG';
1115 $QuicktimeVideoCodecLookup[
'base'] =
'Base';
1116 $QuicktimeVideoCodecLookup[
'WRLE'] =
'BMP';
1117 $QuicktimeVideoCodecLookup[
'cvid'] =
'Cinepak';
1118 $QuicktimeVideoCodecLookup[
'clou'] =
'Cloud';
1119 $QuicktimeVideoCodecLookup[
'cmyk'] =
'CMYK';
1120 $QuicktimeVideoCodecLookup[
'yuv2'] =
'ComponentVideo';
1121 $QuicktimeVideoCodecLookup[
'yuvu'] =
'ComponentVideoSigned';
1122 $QuicktimeVideoCodecLookup[
'yuvs'] =
'ComponentVideoUnsigned';
1123 $QuicktimeVideoCodecLookup[
'dvc '] =
'DVC-NTSC';
1124 $QuicktimeVideoCodecLookup[
'dvcp'] =
'DVC-PAL';
1125 $QuicktimeVideoCodecLookup[
'dvpn'] =
'DVCPro-NTSC';
1126 $QuicktimeVideoCodecLookup[
'dvpp'] =
'DVCPro-PAL';
1127 $QuicktimeVideoCodecLookup[
'fire'] =
'Fire';
1128 $QuicktimeVideoCodecLookup[
'flic'] =
'FLC';
1129 $QuicktimeVideoCodecLookup[
'b48r'] =
'48RGB';
1130 $QuicktimeVideoCodecLookup[
'gif '] =
'GIF';
1131 $QuicktimeVideoCodecLookup[
'smc '] =
'Graphics';
1132 $QuicktimeVideoCodecLookup[
'h261'] =
'H261';
1133 $QuicktimeVideoCodecLookup[
'h263'] =
'H263';
1134 $QuicktimeVideoCodecLookup[
'IV41'] =
'Indeo4';
1135 $QuicktimeVideoCodecLookup[
'jpeg'] =
'JPEG';
1136 $QuicktimeVideoCodecLookup[
'PNTG'] =
'MacPaint';
1137 $QuicktimeVideoCodecLookup[
'msvc'] =
'Microsoft Video1';
1138 $QuicktimeVideoCodecLookup[
'mjpa'] =
'Motion JPEG-A';
1139 $QuicktimeVideoCodecLookup[
'mjpb'] =
'Motion JPEG-B';
1140 $QuicktimeVideoCodecLookup[
'myuv'] =
'MPEG YUV420';
1141 $QuicktimeVideoCodecLookup[
'dmb1'] =
'OpenDML JPEG';
1142 $QuicktimeVideoCodecLookup[
'kpcd'] =
'PhotoCD';
1143 $QuicktimeVideoCodecLookup[
'8BPS'] =
'Planar RGB';
1144 $QuicktimeVideoCodecLookup[
'png '] =
'PNG';
1145 $QuicktimeVideoCodecLookup[
'qdrw'] =
'QuickDraw';
1146 $QuicktimeVideoCodecLookup[
'qdgx'] =
'QuickDrawGX';
1147 $QuicktimeVideoCodecLookup[
'raw '] =
'RAW';
1148 $QuicktimeVideoCodecLookup[
'.SGI'] =
'SGI';
1149 $QuicktimeVideoCodecLookup[
'b16g'] =
'16Gray';
1150 $QuicktimeVideoCodecLookup[
'b64a'] =
'64ARGB';
1151 $QuicktimeVideoCodecLookup[
'SVQ1'] =
'Sorenson Video 1';
1152 $QuicktimeVideoCodecLookup[
'SVQ1'] =
'Sorenson Video 3';
1153 $QuicktimeVideoCodecLookup[
'syv9'] =
'Sorenson YUV9';
1154 $QuicktimeVideoCodecLookup[
'tga '] =
'Targa';
1155 $QuicktimeVideoCodecLookup[
'b32a'] =
'32AlphaGray';
1156 $QuicktimeVideoCodecLookup[
'tiff'] =
'TIFF';
1157 $QuicktimeVideoCodecLookup[
'path'] =
'Vector';
1158 $QuicktimeVideoCodecLookup[
'rpza'] =
'Video';
1159 $QuicktimeVideoCodecLookup[
'ripl'] =
'WaterRipple';
1160 $QuicktimeVideoCodecLookup[
'WRAW'] =
'Windows RAW';
1161 $QuicktimeVideoCodecLookup[
'y420'] =
'YUV420';
1163 return (isset($QuicktimeVideoCodecLookup[$codecid]) ? $QuicktimeVideoCodecLookup[$codecid] :
'');
1167 static $QuicktimeAudioCodecLookup = array();
1168 if (empty($QuicktimeAudioCodecLookup)) {
1169 $QuicktimeAudioCodecLookup[
'.mp3'] =
'Fraunhofer MPEG Layer-III alias';
1170 $QuicktimeAudioCodecLookup[
'aac '] =
'ISO/IEC 14496-3 AAC';
1171 $QuicktimeAudioCodecLookup[
'agsm'] =
'Apple GSM 10:1';
1172 $QuicktimeAudioCodecLookup[
'alac'] =
'Apple Lossless Audio Codec';
1173 $QuicktimeAudioCodecLookup[
'alaw'] =
'A-law 2:1';
1174 $QuicktimeAudioCodecLookup[
'conv'] =
'Sample Format';
1175 $QuicktimeAudioCodecLookup[
'dvca'] =
'DV';
1176 $QuicktimeAudioCodecLookup[
'dvi '] =
'DV 4:1';
1177 $QuicktimeAudioCodecLookup[
'eqal'] =
'Frequency Equalizer';
1178 $QuicktimeAudioCodecLookup[
'fl32'] =
'32-bit Floating Point';
1179 $QuicktimeAudioCodecLookup[
'fl64'] =
'64-bit Floating Point';
1180 $QuicktimeAudioCodecLookup[
'ima4'] =
'Interactive Multimedia Association 4:1';
1181 $QuicktimeAudioCodecLookup[
'in24'] =
'24-bit Integer';
1182 $QuicktimeAudioCodecLookup[
'in32'] =
'32-bit Integer';
1183 $QuicktimeAudioCodecLookup[
'lpc '] =
'LPC 23:1';
1184 $QuicktimeAudioCodecLookup[
'MAC3'] =
'Macintosh Audio Compression/Expansion (MACE) 3:1';
1185 $QuicktimeAudioCodecLookup[
'MAC6'] =
'Macintosh Audio Compression/Expansion (MACE) 6:1';
1186 $QuicktimeAudioCodecLookup[
'mixb'] =
'8-bit Mixer';
1187 $QuicktimeAudioCodecLookup[
'mixw'] =
'16-bit Mixer';
1188 $QuicktimeAudioCodecLookup[
'mp4a'] =
'ISO/IEC 14496-3 AAC';
1189 $QuicktimeAudioCodecLookup[
'MS'.
"\x00\x02"] =
'Microsoft ADPCM';
1190 $QuicktimeAudioCodecLookup[
'MS'.
"\x00\x11"] =
'DV IMA';
1191 $QuicktimeAudioCodecLookup[
'MS'.
"\x00\x55"] =
'Fraunhofer MPEG Layer III';
1192 $QuicktimeAudioCodecLookup[
'NONE'] =
'No Encoding';
1193 $QuicktimeAudioCodecLookup[
'Qclp'] =
'Qualcomm PureVoice';
1194 $QuicktimeAudioCodecLookup[
'QDM2'] =
'QDesign Music 2';
1195 $QuicktimeAudioCodecLookup[
'QDMC'] =
'QDesign Music 1';
1196 $QuicktimeAudioCodecLookup[
'ratb'] =
'8-bit Rate';
1197 $QuicktimeAudioCodecLookup[
'ratw'] =
'16-bit Rate';
1198 $QuicktimeAudioCodecLookup[
'raw '] =
'raw PCM';
1199 $QuicktimeAudioCodecLookup[
'sour'] =
'Sound Source';
1200 $QuicktimeAudioCodecLookup[
'sowt'] =
'signed/two\'s complement (Little Endian)';
1201 $QuicktimeAudioCodecLookup[
'str1'] =
'Iomega MPEG layer II';
1202 $QuicktimeAudioCodecLookup[
'str2'] =
'Iomega MPEG *layer II';
1203 $QuicktimeAudioCodecLookup[
'str3'] =
'Iomega MPEG **layer II';
1204 $QuicktimeAudioCodecLookup[
'str4'] =
'Iomega MPEG ***layer II';
1205 $QuicktimeAudioCodecLookup[
'twos'] =
'signed/two\'s complement (Big Endian)';
1206 $QuicktimeAudioCodecLookup[
'ulaw'] =
'mu-law 2:1';
1208 return (isset($QuicktimeAudioCodecLookup[$codecid]) ? $QuicktimeAudioCodecLookup[$codecid] :
'');
1212 static $QuicktimeDCOMLookup = array();
1213 if (empty($QuicktimeDCOMLookup)) {
1214 $QuicktimeDCOMLookup[
'zlib'] =
'ZLib Deflate';
1215 $QuicktimeDCOMLookup[
'adec'] =
'Apple Compression';
1217 return (isset($QuicktimeDCOMLookup[$compressionid]) ? $QuicktimeDCOMLookup[$compressionid] :
'');
1221 static $QuicktimeColorNameLookup = array();
1222 if (empty($QuicktimeColorNameLookup)) {
1223 $QuicktimeColorNameLookup[1] =
'2-color (monochrome)';
1224 $QuicktimeColorNameLookup[2] =
'4-color';
1225 $QuicktimeColorNameLookup[4] =
'16-color';
1226 $QuicktimeColorNameLookup[8] =
'256-color';
1227 $QuicktimeColorNameLookup[16] =
'thousands (16-bit color)';
1228 $QuicktimeColorNameLookup[24] =
'millions (24-bit color)';
1229 $QuicktimeColorNameLookup[32] =
'millions+ (32-bit color)';
1230 $QuicktimeColorNameLookup[33] =
'black & white';
1231 $QuicktimeColorNameLookup[34] =
'4-gray';
1232 $QuicktimeColorNameLookup[36] =
'16-gray';
1233 $QuicktimeColorNameLookup[40] =
'256-gray';
1235 return (isset($QuicktimeColorNameLookup[$colordepthid]) ? $QuicktimeColorNameLookup[$colordepthid] :
'invalid');
1239 static $handyatomtranslatorarray = array();
1240 if (empty($handyatomtranslatorarray)) {
1241 $handyatomtranslatorarray[
'©cpy'] =
'copyright';
1242 $handyatomtranslatorarray[
'©day'] =
'creation_date';
1243 $handyatomtranslatorarray[
'©dir'] =
'director';
1244 $handyatomtranslatorarray[
'©ed1'] =
'edit1';
1245 $handyatomtranslatorarray[
'©ed2'] =
'edit2';
1246 $handyatomtranslatorarray[
'©ed3'] =
'edit3';
1247 $handyatomtranslatorarray[
'©ed4'] =
'edit4';
1248 $handyatomtranslatorarray[
'©ed5'] =
'edit5';
1249 $handyatomtranslatorarray[
'©ed6'] =
'edit6';
1250 $handyatomtranslatorarray[
'©ed7'] =
'edit7';
1251 $handyatomtranslatorarray[
'©ed8'] =
'edit8';
1252 $handyatomtranslatorarray[
'©ed9'] =
'edit9';
1253 $handyatomtranslatorarray[
'©fmt'] =
'format';
1254 $handyatomtranslatorarray[
'©inf'] =
'information';
1255 $handyatomtranslatorarray[
'©prd'] =
'producer';
1256 $handyatomtranslatorarray[
'©prf'] =
'performers';
1257 $handyatomtranslatorarray[
'©req'] =
'system_requirements';
1258 $handyatomtranslatorarray[
'©src'] =
'source_credit';
1259 $handyatomtranslatorarray[
'©wrt'] =
'writer';
1262 $handyatomtranslatorarray[
'©nam'] =
'title';
1263 $handyatomtranslatorarray[
'©cmt'] =
'comment';
1264 $handyatomtranslatorarray[
'©wrn'] =
'warning';
1265 $handyatomtranslatorarray[
'©hst'] =
'host_computer';
1266 $handyatomtranslatorarray[
'©mak'] =
'make';
1267 $handyatomtranslatorarray[
'©mod'] =
'model';
1268 $handyatomtranslatorarray[
'©PRD'] =
'product';
1269 $handyatomtranslatorarray[
'©swr'] =
'software';
1270 $handyatomtranslatorarray[
'©aut'] =
'author';
1271 $handyatomtranslatorarray[
'©ART'] =
'artist';
1272 $handyatomtranslatorarray[
'©trk'] =
'track';
1273 $handyatomtranslatorarray[
'©alb'] =
'album';
1274 $handyatomtranslatorarray[
'©com'] =
'comment';
1275 $handyatomtranslatorarray[
'©gen'] =
'genre';
1276 $handyatomtranslatorarray[
'©ope'] =
'composer';
1277 $handyatomtranslatorarray[
'©url'] =
'url';
1278 $handyatomtranslatorarray[
'©enc'] =
'encoder';
1280 if (isset($handyatomtranslatorarray[$keyname])) {
1281 $ThisFileInfo[
'quicktime'][
'comments'][$handyatomtranslatorarray[$keyname]][] =
$data;
1289 if (substr($nullterminatedstring, strlen($nullterminatedstring) - 1, 1) ===
"\x00") {
1290 return substr($nullterminatedstring, 0, strlen($nullterminatedstring) - 1);
1292 return $nullterminatedstring;
1297 return substr($pascalstring, 1);