comparison mxfenc.c @ 4430:d6fe53c5c8d2 libavformat

correctly set multi track operational pattern
author bcoudurier
date Tue, 10 Feb 2009 04:53:41 +0000
parents 7854590fb1fd
children 723d05287ae9
comparison
equal deleted inserted replaced
4429:7ed870203bfe 4430:d6fe53c5c8d2
379 379
380 // write content_storage_refs 380 // write content_storage_refs
381 mxf_write_local_tag(pb, 16, 0x3B03); 381 mxf_write_local_tag(pb, 16, 0x3B03);
382 mxf_write_uuid(pb, ContentStorage, 0); 382 mxf_write_uuid(pb, ContentStorage, 0);
383 383
384 // operational pattern
384 mxf_write_local_tag(pb, 16, 0x3B09); 385 mxf_write_local_tag(pb, 16, 0x3B09);
385 put_buffer(pb, op1a_ul, 16); 386 if (s->nb_streams > 1) {
387 put_buffer(pb, op1a_ul, 14);
388 put_be16(pb, 0x0900); // multi track
389 } else {
390 put_buffer(pb, op1a_ul, 16);
391 }
386 392
387 // write essence_container_refs 393 // write essence_container_refs
388 mxf_write_local_tag(pb, 8 + 16 * mxf->essence_container_count, 0x3B0A); 394 mxf_write_local_tag(pb, 8 + 16 * mxf->essence_container_count, 0x3B0A);
389 mxf_write_essence_container_refs(s); 395 mxf_write_essence_container_refs(s);
390 396
998 put_be64(pb, index_byte_count); // indexByteCount 1004 put_be64(pb, index_byte_count); // indexByteCount
999 put_be32(pb, indexsid); // indexSID 1005 put_be32(pb, indexsid); // indexSID
1000 put_be64(pb, 0); // bodyOffset 1006 put_be64(pb, 0); // bodyOffset
1001 1007
1002 put_be32(pb, bodysid); // bodySID 1008 put_be32(pb, bodysid); // bodySID
1003 put_buffer(pb, op1a_ul, 16); // operational pattern 1009
1010 // operational pattern
1011 if (s->nb_streams > 1) {
1012 put_buffer(pb, op1a_ul, 14);
1013 put_be16(pb, 0x0900); // multi track
1014 } else {
1015 put_buffer(pb, op1a_ul, 16);
1016 }
1004 1017
1005 // essence container 1018 // essence container
1006 mxf_write_essence_container_refs(s); 1019 mxf_write_essence_container_refs(s);
1007 1020
1008 if (write_metadata) { 1021 if (write_metadata) {