replaygain for ogg and flac

135 views
Skip to first unread message

Daniel Phillips

unread,
Feb 4, 2013, 2:34:12 AM2/4/13
to beets...@googlegroups.com
Most of my collection is either in ogg or flac format. I would like to use beets to organise this and process the replaygain in one hit. Can anyone tell me if there is a way to do this currently?

Nice program, thanks

Adrian Sampson

unread,
Feb 4, 2013, 2:48:00 AM2/4/13
to beets...@googlegroups.com
Hi, Daniel --

Currently, the beets replaygain plugin uses the mp3gain command-line tool (or its cousin, aacgain), so it doesn't support the full range of audio formats that beets itself supports. But we have a project in the works to reimplement the ReplayGain algorithm in a codec-independent way.

In the mean time, does anyone else have any suggestions for RG analyzers that work on Ogg and FLAC files?

Adrian

On Feb 3, 2013, at 11:34 PM, Daniel Phillips <alleyo...@gmail.com> wrote:

Most of my collection is either in ogg or flac format. I would like to use beets to organise this and process the replaygain in one hit. Can anyone tell me if there is a way to do this currently?

Nice program, thanks

--
You received this message because you are subscribed to the Google Groups "beets" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beets-users...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Daniel Phillips

unread,
Feb 4, 2013, 2:53:13 AM2/4/13
to beets...@googlegroups.com
Thanks Adrian.

vorbisgain and metaflac work on ogg and flac respectively and
soundkonverter if you need a graphical tool

Francesco Rubino

unread,
Nov 7, 2014, 7:08:28 AM11/7/14
to beets...@googlegroups.com
I have a similar issue. Most of the collection in flac and some wavpack files.

I'm on Mac OS X and I've tried to use http://audiotools.sourceforge.net, a python package that includes a nice interface for replaygain analysis and supportes wavpack, flac and ogg as well as alac if you install the right libraries (via Homebrew). 

So, I wrote a small plugin for myself that uses it and tested it on my collection. 
It works well and I'm willing to share the code and maybe try to integrate it with the available replaygain plugin, as another backend.

Francescp

Adrian Sampson

unread,
Nov 7, 2014, 11:06:01 AM11/7/14
to beets...@googlegroups.com
Integrating with pyaudiotools as a backend for the RG plugin seems like a very reasonable idea. If you can, please do share the code—I'm sure it would be an interesting project.

I'm not sure how your plugin is architected, but it looks possible to link directly to the Python-wrapped RG library included in pyaudiotools:
For more options, visit https://groups.google.com/d/optout.

Francesco Rubino

unread,
Nov 7, 2014, 11:27:55 AM11/7/14
to beets...@googlegroups.com
I mainly copied code from the existing plugin, while trying to understand how the original beet plugin works, as well as the audiotools library. I actually used a lot of the code of the original plugin.
My idea was to make a new backend for the existing plugin, because that gives more choices to people: I tried to install gstreamer without success on mac os x, so I resorted to the audiotools module.

I thought about using that replaygain module separately, but it needs a PCM stream, so I need the rest of the library (or another one) to read the actual files (mp3, flac, etc.).

Feel free to use the code, I'll have a go at making it another backend for the replaygain plugin, anyway.
replaygain2.py

Adrian Sampson

unread,
Nov 7, 2014, 11:34:06 AM11/7/14
to beets...@googlegroups.com
Cool; thanks!

On Nov 7, 2014, at 8:27 AM, Francesco Rubino <rubino.f...@gmail.com> wrote:

I thought about using that replaygain module separately, but it needs a PCM stream, so I need the rest of the library (or another one) to read the actual files (mp3, flac, etc.).

The usual tool for this in the beets ecosystem is audioread: https://github.com/sampsyo/audioread

Francesco Rubino

unread,
Nov 7, 2014, 1:19:20 PM11/7/14
to beets...@googlegroups.com
So, I made a patch (attached) to add a new backend that uses audiotools. My repository is https://github.com/frubino/beets.

Didn't add comments, but I'd like for people to test it it if possible.

Francesco
Reply all
Reply to author
Forward
0 new messages