LameXP is a free multi-format audio file converter that supports a variety of output formats, including MP3, AAC/MP4, Ogg Vorbis, Opus as well as FLAC, and that can read a multitude of input formats. It also supports multi-threaded batch processing.
Source code:https://lamexp.sourceforge.net/