A basic audio library made mainly for games and game engines that utilises C++23.
Not fully complete yet, but will be very soon.
(This is NOT a continuation of Sprinity's FranAudio extension, but will be a replacement eventually.)
- Modular Backend Support with
FranAudio::Backend::BackendInterface - Miniaudio and OpenAL-Soft Backends
- Optional High-Level Local Server-Client Communication for Inter-Process Usage (Mainly for Game Modding)
- WAV, MP3, FLAC support, along with optional Vorbis and Opus extensions.
- Optional extensive logging for both developers and end users.
- Dynamic Positional Audio
- Post-Processing Effects
- Linux Support
- C API
FranAudioShared - Contains the shared modules for both client-server and the library itself.
- FranAudioShared::Logger - The module that contains the logging functionality for the library.
- FranAudioShared::Network - The module that contains the network helpers and constants for the library.
- FranAudioShared::Containers - The module that contains the container classes for the library.
FranAudio - The main module that contains the core functionality of the library.
- FranAudio::Backend - The module that contains the backend abstract and various backends.
- FranAudio::Backend::Miniaudio - The module that contains the miniaudio backend implementation.
- FranAudio::Backend::OpenAL - The module that contains the OpenAL backend implementation.
- FranAudio::Decoder - The module that contains the decoder abstract and various decoders.
- FranAudio::Decoder::Miniaudio - The module that contains the miniaudio decoder implementation.
- FranAudio::Decoder::Libnyquist - The module that contains the libnyquist decoder implementation.
FranAudioClient - Library module that contains the client-side functionality for standalone server-client system. To be linked with target applications.
FranAudioServer - Executable module that contains the server-side functionality for standalone server-client system.
FranAudioLegacy - Module that contains the C API for the library. To be used in C projects or other languages that support C bindings.
FranAudioTest - Module that contains the test application for the library. Can test both library and server-client system.
Basic usage of the library is as follows:
#include "FranAudio/FranAudio.h"
// TODOYou can also see the FranAudioTest/FranAudioTest.cpp
- CMake 3.23 or newer
- A Compiler that supports C++23
For now, only Windows is supported. In the near future, Linux support will be added.
- Get the code
- (Recommended) Use git to clone the repository (for example, using
git clone https://github.com/edgarbarney/FranAudio) - Download the code using the
<> Codebutton andDownload ZIPoption.
- (Recommended) Use git to clone the repository (for example, using
- Open the directory using Visual Studio
- You can use
File > Open > Folder - You can use the
Open a local folderbutton on the Welcome Screen - You can right-click on the folder, click on the
Open with Visual Studiooption, if you have context menus activated for Visual Studio
- You can use
- Choose your desired profile and build the project.
- You can use the
F7build shortcut. - You can use
Build > Build All
- You can use the
- After choosing your desired profile, you can also install the project.
- You can use
Build > Install FranAudio
- You can use
Upon completing the build process:
your binaries will be in FranAudio/out/build/{build_profile}/bin
Upon completing the installation:
your binaries will be in FranAudio/out/install/{build_profile}/bin
your headers will be in FranAudio/out/install/{build_profile}/include
your libraries will be in FranAudio/out/install/{build_profile}/lib
After you've built the project, you can test if it works with the test application. Instead of unit tests, you should use the application manually, since interactivity and 3D audio is the main feature.
-
Get some test files.
-
Run
FranAudio_Testand use the UI to test out the library.
miniaudio - As Backend and Decoder
libnyquist - As Decoder
ImGui - As Test Application GUI
imgui-filebrowser - Extension for ImGui for file browsing
GLAD - For Test Application GUI
ankerl::unordered_dense - As STL Unordered Map Replacement
vector.hpp from chobo-shl - As STL Vector Replacement
OpenALSoft - As Backend
libogg - Vorbis library depends on this.
libvorbis - Used for OGG/Vorbis support.
libopus - Opusfile library depends on this.
libopusfile - Used for Opus support.
GLFW - For Test Application GUI
Libraries can be modified in one way or another.
So it's not advisable to just replace them drop-in when updating.
Try to do a folder-by-folder diff with a tool like WinMerge or Meld.