Class: Hydra::Derivatives::AudioEncoder
- Inherits:
-
Object
- Object
- Hydra::Derivatives::AudioEncoder
- Defined in:
- lib/hydra/derivatives/audio_encoder.rb
Instance Method Summary collapse
- #audio_encoder ⇒ Object
-
#initialize ⇒ AudioEncoder
constructor
A new instance of AudioEncoder.
Constructor Details
#initialize ⇒ AudioEncoder
Returns a new instance of AudioEncoder.
6 7 8 9 10 11 |
# File 'lib/hydra/derivatives/audio_encoder.rb', line 6 def initialize @ffmpeg_output = Open3.capture3('ffmpeg -codecs').to_s rescue StandardError Logger.warn('Unable to find ffmpeg') @ffmpeg_output = "" end |
Instance Method Details
#audio_encoder ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'lib/hydra/derivatives/audio_encoder.rb', line 13 def audio_encoder audio_encoder = if fdk_aac? 'libfdk_aac' else 'aac' end audio_encoder end |