comparison DOCS/tech/mpcf.txt @ 17640:6b69c5b4b92a

more cosmetics
author ods15
date Fri, 17 Feb 2006 20:05:25 +0000
parents 56ec8716e25b
children 9ef8d2944c21
comparison
equal deleted inserted replaced
17639:56ec8716e25b 17640:6b69c5b4b92a
177 max_pts_distance v 177 max_pts_distance v
178 decode_delay v 178 decode_delay v
179 fixed_fps u(1) 179 fixed_fps u(1)
180 reserved u(7) 180 reserved u(7)
181 codec_specific_data vb 181 codec_specific_data vb
182 182 if(stream_class == video){
183 video_stream_header: 183 width v
184 stream_header 184 height v
185 width v 185 sample_width v
186 height v 186 sample_height v
187 sample_width v 187 colorspace_type v
188 sample_height v 188 }else if(stream_class == audio){
189 colorspace_type v 189 samplerate_nom v
190 reserved_bytes 190 samplerate_denom v
191 checksum u(32) 191 channel_count v
192 192 }
193 audio_stream_header:
194 stream_header
195 samplerate_nom v
196 samplerate_denom v
197 channel_count v
198 reserved_bytes
199 checksum u(32)
200
201 other_stream_header:
202 stream_header
203 reserved_bytes 193 reserved_bytes
204 checksum u(32) 194 checksum u(32)
205 195
206 Basic Packets: 196 Basic Packets:
207 197
308 file: 298 file:
309 file_id_string 299 file_id_string
310 while(!eof){ 300 while(!eof){
311 main_header 301 main_header
312 for(i=0; i<stream_count; i++){ 302 for(i=0; i<stream_count; i++){
313 if(next_packet==video_stream_header) 303 stream_header
314 video_stream_header
315 else if(next_packet==audio_stream_header)
316 audio_stream_header
317 else
318 other_stream_header
319 } 304 }
320 while(next_code == info_startcode){ 305 while(next_code == info_startcode){
321 info_packet 306 info_packet
322 } 307 }
323 if(next_code == index_startcode){ 308 if(next_code == index_startcode){
497 data_size_lsb[frame_code] 482 data_size_lsb[frame_code]
498 must be <16384 483 must be <16384
499 484
500 pts_delta[frame_code] 485 pts_delta[frame_code]
501 must be <16384 and >-16384 486 must be <16384 and >-16384
487
488 reserved_count[frame_code]
489 must be <256
502 490
503 data_size 491 data_size
504 data_size= data_size_lsb + data_size_msb*data_size_mul; 492 data_size= data_size_lsb + data_size_msb*data_size_mul;
505 493
506 coded_pts 494 coded_pts
560 checksum is calculated for the area pointed to by forward_ptr not 548 checksum is calculated for the area pointed to by forward_ptr not
561 including the checksum itself (from first byte after the 549 including the checksum itself (from first byte after the
562 forward_ptr until last byte before the checksum). 550 forward_ptr until last byte before the checksum).
563 In the case of info frames, covers area from begginning of frame. 551 In the case of info frames, covers area from begginning of frame.
564 552
553 Syncpoint tags:
554 ---------------
555
565 syncpoint_checksum 556 syncpoint_checksum
566 crc32 checksum 557 crc32 checksum
567 checksum covers from first byte after syncpoint startcode until last 558 checksum covers from first byte after syncpoint startcode until last
568 byte before the syncpoint_checksum. 559 byte before the syncpoint_checksum.
569 560
581 last_pts[i] = convert_ts(global_key_pts, timebase[stream], timebase[i]) 572 last_pts[i] = convert_ts(global_key_pts, timebase[stream], timebase[i])
582 573
583 global_key_pts MUST be bigger or equal to dts of all past frames across 574 global_key_pts MUST be bigger or equal to dts of all past frames across
584 all streams, and smaller or equal to pts of all future frames. 575 all streams, and smaller or equal to pts of all future frames.
585 576
577 Index tags:
578 -----------
579
586 max_pts 580 max_pts
587 s = max_pts % stream_count 581 s = max_pts % stream_count
588 pts = max_pts / stream_count 582 pts = max_pts / stream_count
589 The highest pts in the entire file in the timebase of stream 's' . 583 The highest pts in the entire file in the timebase of stream 's' .
590 584
609 Length in bytes of the entire index, from the first byte of the 603 Length in bytes of the entire index, from the first byte of the
610 startcode until the last byte of the checksum. 604 startcode until the last byte of the checksum.
611 Note: A demuxer can use this to find the index when it is written at 605 Note: A demuxer can use this to find the index when it is written at
612 EOF, as index_ptr will always be 12 bytes before the end of file if 606 EOF, as index_ptr will always be 12 bytes before the end of file if
613 there is an index at all. 607 there is an index at all.
608
609 Info tags:
610 ----------
614 611
615 id 612 id
616 the ID of the type/name pair, so it is more compact 613 the ID of the type/name pair, so it is more compact
617 0 means end 614 0 means end
618 615