lexiMee / mp4parser

Automatically exported from code.google.com/p/mp4parser
0 stars 0 forks source link

support for extended box (largesize) #27

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hello,

It seems parsing for extended boxes is not supported.
Here is a small part of the spec :
[...]
4.2 Object Structure
[...]
unsigned int(32) size;
unsigned int(32) type = boxtype;
if (size==1) {
unsigned int(64) largesize;
} else if (size==0) {
[...]

Some encoders builds extended box for the mdat box, even if the content can fit 
in a 32 bits box.
Here a small dump of the file:
00 00 00 01 // use big box (size is 1)
6D 64 61 74 // mdat 
00 00 00 00 00 07 BC AB // The size (here fits in 32 bit !!)

Sylvain

Original issue reported on code.google.com by marechal...@gmail.com on 7 Nov 2011 at 9:56

GoogleCodeExporter commented 9 years ago
Hi Sylvain, 

it is supported in general. The 'large size' is only used for boxes > 4GB when 
I write a newly created file. At least the trunk should even detect large mdats 
(even though they don't need to be large) and replicate the mdat with the large 
size so that all the offset are still alright when writing the file back to 
disk.
If you can tell me what you are trying to do? Perhaps you can even provide me 
with an example file where the parsing or writing fails. 

best Regards,
Sebastian

Original comment by Sebastian.Annies on 7 Nov 2011 at 4:57

GoogleCodeExporter commented 9 years ago
Hi Sebastian,

I'm currently building an mp4 parser for smooth streaming.
For input, I get data from an elemental encoder. 
This encoder always uses big boxes for mdat streams.
I will sent a private email with a sample stream.

Regards,
Sylvain

Original comment by marechal...@gmail.com on 8 Nov 2011 at 10:23

GoogleCodeExporter commented 9 years ago
I was wrong. Big boxes are correctly parsed. This ticket is invalid.

Original comment by marechal...@gmail.com on 8 Nov 2011 at 3:03

GoogleCodeExporter commented 9 years ago
Happy to help ;)

Original comment by Sebastian.Annies on 8 Nov 2011 at 3:14