Mp4 encoding gem?

Hi all,

I’m writing an audio encoding application, I need to encode wav files to
mp3 and mp4. I have managed the mp3 part using the lamer gem:
http://rubygems.org/gems/lamer
I am now looking to encode wav to mp4/aac i think i need to use the nero
encoder for this
http://www.nero.com/eng/downloads-nerodigital-nero-aac-codec.php does
anyone know if there is a ruby gem that would allow me to do this?

Thanks,

Will

I am now looking to encode wav to mp4/aac i think i need to use the
nero encoder for this

Not quite what you asked but ffmpeg is solid. Converts pretty much
everything to anything. Check out the list of supported file formats

http://www.ffmpeg.org/general.html#SEC3

If you used ffmpeg you wouldn’t need different tools to convert to
different formats, so your program would have fewer dependencies.

Once I needed just to convert some files so I did something like:

Not tested any of this tiny and flawed program

Convert the file specified by path to a different multimedia format

def convert path, type
ffmpeg -i #{in_file} #{in_file}.#{type}
end

convert “Rebecca Black - Friday.ogg”, “mp3”

That writes out to ‘Rebecca Black - Friday.ogg.mp3’

This approach of calling the command line application probably isn’t so
great if you were writing a big fancy program but it worked okay for my
little use case.

There is a work in progress gem here, but I haven’t used it so cannot
comment https://github.com/gwik/ffmpeg-ruby

Good luck,
Johnny

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs