Class: BMFF::Box::MediaHeader
- Defined in:
- lib/bmff/box/media_header.rb
Overview
vim: set expandtab tabstop=2 shiftwidth=2 softtabstop=2 autoindent:
Instance Attribute Summary collapse
-
#creation_time ⇒ Object
Returns the value of attribute creation_time.
-
#duration ⇒ Object
Returns the value of attribute duration.
-
#language ⇒ Object
Returns the value of attribute language.
-
#modification_time ⇒ Object
Returns the value of attribute modification_time.
-
#pre_defined ⇒ Object
Returns the value of attribute pre_defined.
-
#timescale ⇒ Object
Returns the value of attribute timescale.
Attributes inherited from Full
Attributes inherited from Base
#io, #largesize, #offset, #parent, #size, #type, #usertype
Instance Method Summary collapse
Methods inherited from Base
#actual_size, #container?, #eob?, #parse, register_box, #remaining_size, #seek_to_end
Instance Attribute Details
#creation_time ⇒ Object
Returns the value of attribute creation_time.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def creation_time @creation_time end |
#duration ⇒ Object
Returns the value of attribute duration.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def duration @duration end |
#language ⇒ Object
Returns the value of attribute language.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def language @language end |
#modification_time ⇒ Object
Returns the value of attribute modification_time.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def modification_time @modification_time end |
#pre_defined ⇒ Object
Returns the value of attribute pre_defined.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def pre_defined @pre_defined end |
#timescale ⇒ Object
Returns the value of attribute timescale.
5 6 7 |
# File 'lib/bmff/box/media_header.rb', line 5 def timescale @timescale end |
Instance Method Details
#parse_data ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/bmff/box/media_header.rb', line 9 def parse_data super if version == 1 @creation_time = io.get_uint64 @modification_time = io.get_uint64 @timescale = io.get_uint32 @duration = io.get_uint64 else @creation_time = io.get_uint32 @modification_time = io.get_uint32 @timescale = io.get_uint32 @duration = io.get_uint32 end @language = io.get_iso639_2_language @pre_defined = io.get_uint16 end |