Class: BMFF::Box::TrackHeader
- Defined in:
- lib/bmff/box/track_header.rb
Overview
vim: set expandtab tabstop=2 shiftwidth=2 softtabstop=2 autoindent:
Instance Attribute Summary collapse
-
#alternate_group ⇒ Object
Returns the value of attribute alternate_group.
-
#creation_time ⇒ Object
Returns the value of attribute creation_time.
-
#duration ⇒ Object
Returns the value of attribute duration.
-
#height ⇒ Object
Returns the value of attribute height.
-
#layer ⇒ Object
Returns the value of attribute layer.
-
#matrix ⇒ Object
Returns the value of attribute matrix.
-
#modification_time ⇒ Object
Returns the value of attribute modification_time.
-
#reserved1 ⇒ Object
Returns the value of attribute reserved1.
-
#reserved2 ⇒ Object
Returns the value of attribute reserved2.
-
#reserved3 ⇒ Object
Returns the value of attribute reserved3.
-
#track_id ⇒ Object
Returns the value of attribute track_id.
-
#volume ⇒ Object
Returns the value of attribute volume.
-
#width ⇒ Object
Returns the value of attribute width.
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, register_uuid_box, #remaining_size, #root, #seek_to_end
Instance Attribute Details
#alternate_group ⇒ Object
Returns the value of attribute alternate_group.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def alternate_group @alternate_group end |
#creation_time ⇒ Object
Returns the value of attribute creation_time.
5 6 7 |
# File 'lib/bmff/box/track_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/track_header.rb', line 5 def duration @duration end |
#height ⇒ Object
Returns the value of attribute height.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def height @height end |
#layer ⇒ Object
Returns the value of attribute layer.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def layer @layer end |
#matrix ⇒ Object
Returns the value of attribute matrix.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def matrix @matrix end |
#modification_time ⇒ Object
Returns the value of attribute modification_time.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def modification_time @modification_time end |
#reserved1 ⇒ Object
Returns the value of attribute reserved1.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def reserved1 @reserved1 end |
#reserved2 ⇒ Object
Returns the value of attribute reserved2.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def reserved2 @reserved2 end |
#reserved3 ⇒ Object
Returns the value of attribute reserved3.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def reserved3 @reserved3 end |
#track_id ⇒ Object
Returns the value of attribute track_id.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def track_id @track_id end |
#volume ⇒ Object
Returns the value of attribute volume.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def volume @volume end |
#width ⇒ Object
Returns the value of attribute width.
5 6 7 |
# File 'lib/bmff/box/track_header.rb', line 5 def width @width end |
Instance Method Details
#parse_data ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
# File 'lib/bmff/box/track_header.rb', line 9 def parse_data super if version == 1 @creation_time = io.get_uint64 @modification_time = io.get_uint64 @track_id = io.get_uint32 @reserved1 = io.get_uint32 @duration = io.get_uint64 else @creation_time = io.get_uint32 @modification_time = io.get_uint32 @track_id = io.get_uint32 @reserved1 = io.get_uint32 @duration = io.get_uint32 end @reserved2 = [io.get_uint32, io.get_uint32] @layer = io.get_int16 @alternate_group = io.get_int16 @volume = io.get_int16 @reserved3 = io.get_uint16 @matrix = [] 9.times do @matrix << io.get_int32 end @width = io.get_uint32 @height = io.get_uint32 end |