Add notes on sample offset calculation
Write up some basic reminders of valid ways to address samples in a fragmented MP4 when using movie-fragment-relative addressing.
Showing
1 changed file
with
27 additions
and
1 deletions
... | @@ -46,4 +46,30 @@ track | ... | @@ -46,4 +46,30 @@ track |
46 | chunk | 46 | chunk |
47 | sample | 47 | sample |
48 | 48 | ||
49 | movie fragment -> track fragment -> [samples] | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
49 | movie fragment -> track fragment -> [samples] | ||
50 | |||
51 | ### Sample Data Offsets | ||
52 | Movie-fragment Relative Addressing: all trun data offsets are relative | ||
53 | to the containing moof (?). | ||
54 | |||
55 | Without default-base-is-moof, the base data offset for each trun in | ||
56 | trafs after the first is the *end* of the previous traf. | ||
57 | |||
58 | #### iso5/DASH Style | ||
59 | moof | ||
60 | |- traf (default-base-is-moof) | ||
61 | | |- trun_0 <size of moof> + 0 | ||
62 | | `- trun_1 <size of moof> + 100 | ||
63 | `- traf (default-base-is-moof) | ||
64 | `- trun_2 <size of moof> + 300 | ||
65 | mdat | ||
66 | |- samples_for_trun_0 (100 bytes) | ||
67 | |- samples_for_trun_1 (200 bytes) | ||
68 | `- samples_for_trun_2 | ||
69 | |||
70 | #### Single Track Style | ||
71 | moof | ||
72 | `- traf | ||
73 | `- trun_0 <size of moof> + 0 | ||
74 | mdat | ||
75 | `- samples_for_trun_0 | ||
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
-
Please register or sign in to post a comment