Module: Abrizer::InformationHelpers
Instance Method Summary collapse
- #duration ⇒ Object
- #max_height ⇒ Object
- #max_width ⇒ Object
- #min_height ⇒ Object
- #min_width ⇒ Object
- #mp4_height ⇒ Object
- #mp4_width ⇒ Object
Instance Method Details
#duration ⇒ Object
4 5 6 7 |
# File 'lib/abrizer/information_helpers.rb', line 4 def duration informer = Abrizer::FfprobeInformer.new(mp4_filepath) informer.duration.to_f end |
#max_height ⇒ Object
17 18 19 |
# File 'lib/abrizer/information_helpers.rb', line 17 def max_height @adaptations.last.height end |
#max_width ⇒ Object
9 10 11 |
# File 'lib/abrizer/information_helpers.rb', line 9 def max_width @adaptations.last.width end |
#min_height ⇒ Object
21 22 23 |
# File 'lib/abrizer/information_helpers.rb', line 21 def min_height @adaptations.first.height end |
#min_width ⇒ Object
13 14 15 |
# File 'lib/abrizer/information_helpers.rb', line 13 def min_width @adaptations.first.width end |
#mp4_height ⇒ Object
29 30 31 |
# File 'lib/abrizer/information_helpers.rb', line 29 def mp4_height @adaptations[-2].height end |
#mp4_width ⇒ Object
25 26 27 |
# File 'lib/abrizer/information_helpers.rb', line 25 def mp4_width @adaptations[-2].width end |