C++ Audio and Music DSP Library

Related tags

Audio Maximilian
Overview
  _____ _____ ___   __ _  _____  __ __   __ ____  ____
 /     \\_   \\  \/  /  |/     \|  |  | |  \_   \/    \
|  Y Y  \/ /_ \>    <|  |  Y Y  \  |  |_|  |/ /_ \  Y  \
|__|_|  (___  /__/\__\__|__|_|  /__|____/__(___  /__|  /
      \/    \/                \/               \/    \/

version GitHub license


What's Maximilian?

Maximilian is a cross-platform and multi-target audio synthesis and signal processing library. It was written in C++ and provides bindings to Javascript. It's compatible with native implementations for MacOS, Windows, Linux and iOS systems, as well as client-side browser-based applications. The main features are:

  • sample playback, recording and looping
  • support for WAV and OGG files.
  • a selection of oscillators and filters
  • enveloping
  • multichannel mixing for 1, 2, 4 and 8 channel setups
  • controller mapping functions
  • effects including delay, distortion, chorus, flanging
  • granular synthesis, including time and pitch stretching
  • atom synthesis
  • real-time music information retrieval functions: spectrum analysis, spectral features, octave analysis, Bark scale analysis, and MFCCs
  • example projects for Windows and MacOS, susing command line and OpenFrameworks environments
  • example projects for Firefox and Chromium-based browsers using the Web Audio API ScriptProcessorNode (deprecated!)
  • example projects for Chromium-based browsers using the Web Audio API AudioWorklet (e.g. Chrome, Brave, Edge, Opera, Vivaldi)

Basic Examples

You can choose between using RTAudio and PortAudio drivers in player.h by uncommenting the appropriate line. To use PortAudio, you will need to compile the portAudio library from http://www.portaudio.com/ and link it with your executable.

Examples demonstrating different features can be found in the maximilian_examples folder. To try them, replace the contents of main.cpp with the contents of a tutorial file and compile.

Web Audio

A transpiled javascript version of the library is included in this repository, for both Script Processor Nodes and AudioWorklets. Try this out at (https://mimicproject.com/guides/maximJS).

Mac OS XCode Project

You can run the examples using the 'maximilianTest' XCode 3 project provided.

MS Windows Visual Studio Project

This is in the maximilianTestWindowsVS2010 folder. You will need to install the DirectX SDK, so that the program can use DirectSound.

Command Line Compilation in Mac OS

g++ -Wall -D__MACOSX_CORE__ -o maximilian main.cpp RtAudio.cpp player.cpp maximilian.cpp -framework CoreAudio -framework CoreFoundation -lpthread

./maximilian

Command Line Compilation in Linux

With OSS:

g++ -Wall -D__LINUX_OSS__ -o maximilian main.cpp RtAudio.cpp player.cpp maximilian.cpp -lpthread

With ALSA:

g++ -Wall -D__LINUX_ALSA__ -o maximilian main.cpp RtAudio.cpp player.cpp maximilian.cpp -lasound -lpthread

With Jack:

g++ -Wall -D__UNIX_JACK__ -o maximilian main.cpp RtAudio.cpp player.cpp maximilian.cpp pkg-config --cflags --libs jack -lpthread

then:

./maximilian

OpenFrameworks Project

Maximilian works well with the OpenFrameworks C++ creative coding toolkit (http://www.openframeworks.cc).

In the ofxMaxim directory you will find examples to run in Windows, OSX and iOS, including FFT analysis and granular synthesis.

You can install the ofxMaxim addon by copying the ofxMaxim/ofxMaxim folder into your openframeworks addons directory.

Important: when using Maximilian on OSX, link against the Accelerate framework.

Comments
  • FFT example doesn't compile.

    FFT example doesn't compile.

    Hi, i'm really interested in using Maximillian's FFT capabilities, but when i run the fft example from the examples folder in VS 2015, it doesn't compile? Does anyone have a solution? Thanks in advance!

    opened by goncasmage1 14
  • URGENT - maxiGrainWindowCache double* getWindow consistent run time crashes.

    URGENT - maxiGrainWindowCache double* getWindow consistent run time crashes.

    Hi Mick,

    Got an urgent question. I have been building an audiovisual granular synth for my PhD and my examination performance is on Friday. I am getting run time crashes at least 3 times a day relating to the double* getWindow function in maxiGrainWindowCache. (See image below)

    Would you be able to suggest how or why this is continually occurring? Or what safe guards I could do temporarily to ensure that this never happens during my examination? Any advice or tips at all at this stage would help my sanity immensely. Thanks!

    screen shot 2014-12-14 at 12 45 30 pm

    opened by JoshuaBatty 9
  • Simple granular synthesis

    Simple granular synthesis

    Hi!

    First, thanks and congratulations with Maximilian, it works great and is well optimized.

    I use it on OpenFrameworks for iOS. I don't manage to do a simple stuff: a very basic granular synthesis. I would like to play a orchestral wav file with position (in the wav file) as a parameter. I explain, i would like to have 16 grain players, and every xx milliseconds (xx = random numbers) one of these players plays a very short part of the file (at the right play head position), with no loop. Because there are 16 players and they play very quickly small grains, it gives you the impression that the play head stays immobile. I made a Max/MSP patch and it works well, but i cannot make it in OpenFrameworks / Maximilian.

    Hope my explanation is obvious. Thanks for your help!

    Cheers, Olivier

    opened by og0 9
  • compilation in ubuntu

    compilation in ubuntu

    i'm trying to compile a small app i got running is OSX and tried to port it to Ubuntu (CodeBlocks 10.05)

    i got this errors :

    ../../../addons/ofxMaxim/libs/maxiMFCC.h|62|error: there are no arguments to ‘malloc’ that depend on a template parameter, so a declaration of ‘malloc’ must be available [-fpermissive]| ../../../addons/ofxMaxim/libs/maxiMFCC.h|67|error: there are no arguments to ‘malloc’ that depend on a template parameter, so a declaration of ‘malloc’ must be available [-fpermissive]| ../../../addons/ofxMaxim/libs/maxiMFCC.h||In member function ‘void maxiMFCCAnalyser::calcMelFilterBank(double, int)’:| ../../../addons/ofxMaxim/libs/maxiMFCC.h|128|error: there are no arguments to ‘malloc’ that depend on a template parameter, so a declaration of ‘malloc’ must be available [-fpermissive]| ../../../addons/ofxMaxim/libs/maxiMFCC.h|139|error: there are no arguments to ‘malloc’ that depend on a template parameter, so a declaration of ‘malloc’ must be available [-fpermissive]| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp||In member function ‘void maxiMFCCAnalyser::dct(T_) [with T = double]’:| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp|16|error: ‘vDSP_mmulD’ was not declared in this scope| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp|18|error: ‘vDSP_vsdivD’ was not declared in this scope| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp||In member function ‘void maxiMFCCAnalyser::dct(T_) [with T = float]’:| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp|23|error: ‘vDSP_mmul’ was not declared in this scope| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp|25|error: ‘vDSP_vsdiv’ was not declared in this scope| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp||In member function ‘void maxiMFCCAnalyser::melFilterAndLogSq_Part2()’:| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp|58|error: ‘powerSpectrum’ was not declared in this scope| ../../../addons/ofxMaxim/libs/maxiMFCC.cpp||In member function ‘void maxiMFCCAnalyser::melFilterAndLogSq_Part2() [with T = double]’:|

    i've already added the #include as memset and memalloc where not found ...

    hope it's usefull ...

    e*

    opened by eloimaduell 7
  • maximilian not taking

    maximilian not taking "audio data file offset" into account.

    hi @micknoise,

    im working with ofxMaxim in OF on iOS. basically, im trying to load a song from my iphones music library, convert it to a wav and have ofxMaxim do some cool shit with it :)

    so far ive been successful in converting the library file to a wav file and storing it in the documents folder of the app to be then loaded by ofxMaxim, but this is where it trips up...

    ive done lots of tests and worked out that when iOS exports a PCM wave file, it adds a "audio data file offset" of 4096 bytes. a normal wav file that works with ofxMaxim has a "audio data file offset" of 44 bytes. otherwise the files are identical when inspecting using the AFInfo command in terminal.

    im thinking maximilian needs to find out what this "audio data file offset" value is before it starts reading the file into memory. ive had a hack around in maxiSample::read function but its a bit over my head at the moment.

    is the solution to this something apparent to you?

    cheers, L.

    opened by julapy 5
  • Error in maxiatom.cpp

    Error in maxiatom.cpp

    Hey everyone,

    I'm trying to run maximilian in xcode 3.2.6 and open frameworks 0071 but i get errors in "maxiatom.cpp". It goes like this:

    .../addons/ofxMaxim/libs/maxiAtoms.cpp:74: error: cannot convert 'double_' to 'float_' for argument '1' to 'void vDSP_vlint(float_, float_, vDSP_Stride, float*, vDSP_Stride, vDSP_Length, vDSP_Length)'

    ../addons/ofxMaxim/libs/maxiAtoms.cpp:112: error: no matching function for call to 'min(unsigned int&, long unsigned int)'

    Does anybody know how to fix this?

    Thanks

    opened by druckmax 5
  • New PR for Maximilian 2.1 with JS and AudioWorklet

    New PR for Maximilian 2.1 with JS and AudioWorklet

    Summary: Main changes to Web Audio build – transpiled javascript version of the library is included in this repository, for both Script Processor Nodes and Audio AudioWorklets.

    Other changes:

    README -> README.md src - now holds the C++ src, the C++ libs and the embindings. js - holds ScriptProcessorNode (asm.js legacy) and audioWorklet (Wasm) dirs, each with it's own * makefile, build directory, shared libs, examples, and a python webserver script for convenience of testing. cpp - holds C++ client code and project (basically the old stuff).

    opened by frantic0 4
  • Errors when trying to compile Maximilian on Mac OSX 10.11.6...Are there any dependencies missing?

    Errors when trying to compile Maximilian on Mac OSX 10.11.6...Are there any dependencies missing?

    Shyamals-iMac-174:Maximilian shyamalchandra$ g++ -Wall -D__MACOSX_CORE__ -o maximilian main.cpp RtAudio.cpp player.cpp maximilian.cpp -framework CoreAudio -lpthread
    In file included from main.cpp:1:
    ./maximilian.h:242:18: warning: field 'temp' will be initialized after field 'position' [-Wreorder]
        maxiSample():temp(NULL),position(0), recordPosition(0), myChannels(1), mySampleRate(maxiSettings::sampleRate) {};
                     ^
    ./maximilian.h:436:15: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
            long holdtime=1;
                         ^
    ./maximilian.h:644:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:645:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD =0 ;
                       ^
    ./maximilian.h:647:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:648:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:649:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:650:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:651:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:654:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:669:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:670:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0 ;
                       ^
    ./maximilian.h:672:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:673:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:674:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = true;
                       ^
    ./maximilian.h:675:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:676:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:679:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:699:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0;
                      ^
    ./maximilian.h:700:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:702:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:703:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:704:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:705:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:706:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:709:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:752:22: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int originalPitch=67;
                         ^
    ./maximilian.h:754:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:758:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:759:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:760:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:761:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:762:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:765:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:767:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int currentVoice=0;
                        ^
    ./maximilian.h:777:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool sustain = true;
                     ^
    36 warnings generated.
    RtAudio.cpp:1083:74: warning: '&' within '|' [-Wbitwise-op-parentheses]
        formatFlags = description.mFormatFlags | kLinearPCMFormatFlagIsFloat & ~kLinearPCMFormatFlagIsSignedInteger;
                                               ~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    RtAudio.cpp:1083:74: note: place parentheses around the '&' expression to silence this warning
        formatFlags = description.mFormatFlags | kLinearPCMFormatFlagIsFloat & ~kLinearPCMFormatFlagIsSignedInteger;
                                                                             ^
                                                 (                                                                 )
    1 warning generated.
    In file included from player.cpp:11:
    ./maximilian.h:242:18: warning: field 'temp' will be initialized after field 'position' [-Wreorder]
        maxiSample():temp(NULL),position(0), recordPosition(0), myChannels(1), mySampleRate(maxiSettings::sampleRate) {};
                     ^
    ./maximilian.h:436:15: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
            long holdtime=1;
                         ^
    ./maximilian.h:644:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:645:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD =0 ;
                       ^
    ./maximilian.h:647:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:648:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:649:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:650:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:651:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:654:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:669:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:670:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0 ;
                       ^
    ./maximilian.h:672:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:673:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:674:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = true;
                       ^
    ./maximilian.h:675:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:676:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:679:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:699:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0;
                      ^
    ./maximilian.h:700:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:702:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:703:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:704:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:705:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:706:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:709:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:752:22: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int originalPitch=67;
                         ^
    ./maximilian.h:754:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:758:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:759:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:760:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:761:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:762:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:765:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:767:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int currentVoice=0;
                        ^
    ./maximilian.h:777:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool sustain = true;
                     ^
    36 warnings generated.
    In file included from maximilian.cpp:34:
    ./maximilian.h:242:18: warning: field 'temp' will be initialized after field 'position' [-Wreorder]
        maxiSample():temp(NULL),position(0), recordPosition(0), myChannels(1), mySampleRate(maxiSettings::sampleRate) {};
                     ^
    ./maximilian.h:436:15: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
            long holdtime=1;
                         ^
    ./maximilian.h:644:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:645:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD =0 ;
                       ^
    ./maximilian.h:647:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:648:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:649:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:650:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:651:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:654:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:669:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0 ;
                      ^
    ./maximilian.h:670:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0 ;
                       ^
    ./maximilian.h:672:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:673:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:674:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = true;
                       ^
    ./maximilian.h:675:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:676:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:679:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:699:19: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double output = 0;
                      ^
    ./maximilian.h:700:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:702:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:703:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:704:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:705:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:706:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:709:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:752:22: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int originalPitch=67;
                         ^
    ./maximilian.h:754:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double outputD = 0;
                       ^
    ./maximilian.h:758:24: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useDistortion = false;
                           ^
    ./maximilian.h:759:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useLimiter = false;
                        ^
    ./maximilian.h:760:20: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool useFilter = false;
                       ^
    ./maximilian.h:761:23: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double distortion = 0;
                          ^
    ./maximilian.h:762:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool inverse = false;
                     ^
    ./maximilian.h:765:17: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        double gain = 1;
                    ^
    ./maximilian.h:767:21: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        int currentVoice=0;
                        ^
    ./maximilian.h:777:18: warning: in-class initialization of non-static data member is a C++11 extension
          [-Wc++11-extensions]
        bool sustain = true;
                     ^
    ./maximilian.h:70:9: warning: private field 'frequency' is not used [-Wunused-private-field]
            double frequency;
                   ^
    ./maximilian.h:72:9: warning: private field 'startphase' is not used [-Wunused-private-field]
            double startphase;
                   ^
    ./maximilian.h:73:9: warning: private field 'endphase' is not used [-Wunused-private-field]
            double endphase;
                   ^
    ./maximilian.h:75:9: warning: private field 'tri' is not used [-Wunused-private-field]
            double tri;
                   ^
    ./maximilian.h:117:9: warning: private field 'frequency' is not used [-Wunused-private-field]
            double frequency;
                   ^
    ./maximilian.h:119:9: warning: private field 'startphase' is not used [-Wunused-private-field]
            double startphase;
                   ^
    ./maximilian.h:120:9: warning: private field 'endphase' is not used [-Wunused-private-field]
            double endphase;
                   ^
    ./maximilian.h:134:9: warning: private field 'gain' is not used [-Wunused-private-field]
            double gain;
                   ^
    ./maximilian.h:135:9: warning: private field 'input' is not used [-Wunused-private-field]
            double input;
                   ^
    ./maximilian.h:139:9: warning: private field 'cutoff1' is not used [-Wunused-private-field]
            double cutoff1;
                   ^
    ./maximilian.h:158:9: warning: private field 'input' is not used [-Wunused-private-field]
            double input;
                   ^
    ./maximilian.h:159:9: warning: private field 'two' is not used [-Wunused-private-field]
            double two[2];
                   ^
    ./maximilian.h:160:9: warning: private field 'four' is not used [-Wunused-private-field]
            double four[4];
                   ^
    ./maximilian.h:161:9: warning: private field 'eight' is not used [-Wunused-private-field]
            double eight[8];
                   ^
    50 warnings generated.
    Undefined symbols for architecture x86_64:
      "_CFRelease", referenced from:
          RtApiCore::getDeviceInfo(unsigned int) in RtAudio-36f666.o
      "_CFStringGetCString", referenced from:
          RtApiCore::getDeviceInfo(unsigned int) in RtAudio-36f666.o
      "_CFStringGetLength", referenced from:
          RtApiCore::getDeviceInfo(unsigned int) in RtAudio-36f666.o
      "_CFStringGetSystemEncoding", referenced from:
          RtApiCore::getDeviceInfo(unsigned int) in RtAudio-36f666.o
    ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    Shyamals-iMac-174:Maximilian shyamalchandra$ 
    

    This is the output. What should I do to solve this problem?

    opened by shyamalschandra 4
  • Multiple C4244 Warnings

    Multiple C4244 Warnings

    Hello I am new to C++ and would like some help on getting started with Maximilian.... I am on Windows XP running Visual Studio 2010 Premium

    Any help in sorting these errors would be great

    1>------ Build started: Project: maximilianTestWindowsVS2010, Configuration: Debug Win32 ------ 1>Build started 13/06/2012 16:08:38. 1>InitializeBuildStatus: 1> Touching "Debug\maximilianTestWindowsVS2010.unsuccessfulbuild". 1>ClCompile: 1> maximilian.cpp 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.h(262): warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. 1> c:\program files\microsoft visual studio 10.0\vc\include\stdio.h(371) : see declaration of 'sprintf' 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(408): warning C4800: 'void *' : forcing value to bool 'true' or 'false' (performance warning) 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(456): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(534): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(542): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(553): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(560): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(591): warning C4244: 'initializing' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(613): warning C4244: 'initializing' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(732): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(740): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(751): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(758): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(770): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(781): warning C4244: 'initializing' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(803): warning C4244: 'initializing' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(902): warning C4244: '=' : conversion from 'double' to 'long', possible loss of data 1>c:\documents and settings\nexphase\my documents\visual studio 2010\projects\maximilian\maximilian.cpp(398): error C4716: 'maxiSample::loadOgg' : must return a value 1> 1>Build FAILED. 1> 1>Time Elapsed 00:00:03.93 ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

    opened by nkm1 4
  • Compiling fails on Linux

    Compiling fails on Linux

    Been a while since I looked at this. But trying to compile on Ubuntu 13.10 I get the following (from the command line).

    OSS :

    RtAudio.cpp:6391:23: fatal error: soundcard.h: No such file or directory #include "soundcard.h"

    ALSA : RtAudio.cpp:5148:28: fatal error: alsa/asoundlib.h: No such file or directory #include <alsa/asoundlib.h>

    Jack : RtAudio.cpp:1798:23: fatal error: jack/jack.h: No such file or directory #include <jack/jack.h>

    Are there files? Submodules missing? Or is there something I need to install / do before trying to compile?

    opened by interstar 3
  • Crash in MaxiSample::Read

    Crash in MaxiSample::Read

    When reading the first channel from a 2 channel file, the read function crashes. this code seems wrong

    if (myChannels>1) {
                int position=0;
                int channel=readChannel*2;
                for (int i=channel;i<myDataSize +6;i+=(myChannels*2)) {
                    myData[position]=myData[i];
                    myData[position+1]=myData[i+1];
                    position+=2;
           }
    }
    

    I removed the +6 from this line and so the crash no longer occurs;

    for (int i=channel;i < myDataSize +6;i+=(myChannels*2)
    

    so now it looks like this

    for (int i=channel;i<myDataSize ;i+=(myChannels*2) // removed +6
    

    why is that +6 there? the index of myData should not go beyond myDataSize?

    opened by Ahbee 3
  • maxiSample::play() too many arguments

    maxiSample::play() too many arguments

    In maxiSampler::play()

    outputs[i]=samples[i].play(pitchRatios[(int)pitch[i]+originalPitch]*((1./samples[i].getLength())*maxiSettings::sampleRate),0,samples[i].getLength())*envOut[i];

    opened by leehu 2
  • Supporting Maximilian on OWL platform

    Supporting Maximilian on OWL platform

    Hello, great to see the project being actively maintained.

    We're adding support for compiling Maximilian patches on the OWL platform, which is an open source embedded hardware ecosystem thingy-jig. We've got an online patch library and compiler here.

    This means in short that our users will be able to write their own patches using Maximilian and run them on OWL hardware. Other supported languages are plain C++, FAUST, Pure data, Max Gen and most recently SOUL, so you're in good company :)

    To get this to work on a bare-bones (no OS) embedded audio device we've had to adapt the library files a bit. Some of these changes are specific to our platform, others would be nice to contribute back upstream.

    In particular I'd like to lobby for a new feature (which I briefly discussed with Mick ages ago), which is maxiParam. maxiParam is a value object which can be used instead of a double, but which can be updated outside of the patch context. Using maxiParam allows us to map parameters to a hardware knob or button, and so provides easy user control for patch parameters like gain, frequency, et c. It's just as useful for connecting into any other user interface, a GUI or plugin format.

    Rather than post a big PR I decided to open this issue and start a dialogue. What is the best way to proceed?

    opened by pingdynasty 4
Releases(2.5-alpha)
Owner
Mick Grierson
Professor of Computing
Mick Grierson
A lightweight music DSP library.

Soundpipe Soundpipe is a lightweight music DSP library written in C. It aims to provide a set of high-quality DSP modules for composers, sound designe

Paul Batchelor 102 Dec 14, 2021
Xan's NFS Music Player - Custom music player replacement and a BASS library interface for NFS.

Xan's NFS Music Player This is a custom music player replacement and a BASS library interface for NFS. FEATURES Custom playlist generation - put any n

Lovro Pleše 16 Dec 24, 2022
Strawberry is a music player and music collection organizer.

Strawberry is a music player and music collection organizer. It is a fork of Clementine released in 2018 aimed at music collectors and audiophiles. It's written in C++ using the Qt toolkit.

Strawberry Music Player 1.8k Jan 5, 2023
DSP C++ audio filters

DSP filters in C++ This repo contains some DSP biquad filters used in audio. I've extracted those filters from the Designing Audio Effect Plug-Ins in

Dimitris Tassopoulos 101 Dec 26, 2022
C++ library for audio and music analysis, description and synthesis, including Python bindings

Essentia Essentia is an open-source C++ library for audio analysis and audio-based music information retrieval released under the Affero GPL license.

Music Technology Group - Universitat Pompeu Fabra 2.3k Jan 7, 2023
a library for audio and music analysis

aubio is a library to label music and sounds. It listens to audio signals and attempts to detect events. For instance, when a drum is hit, at which frequency is a note, or at what tempo is a rhythmic melody.

aubio 2.9k Jan 2, 2023
A simple CLI to extract & save artwork of a 🎵 music/audio file.

artwork-extractor A simple CLI to extract & save artwork of a ?? music/audio file. Usage Dependencies MediaInfoLib On Debian based distros, one may in

Hitesh Kumar Saini 5 Aug 4, 2021
multichannel eurorack dsp platform

Nemesis multichannel dsp platform for eurorack \hardware panel, pcb and gerber files \software project template \doc datasheets and additional informa

Arev Imer 25 Dec 3, 2022
cute_dsp is a C API for various DSP effects suitable for video games

cute_dsp is a C API for various DSP effects suitable for video games and meant to interface directly with the cute_sound library created by Randy Gaul

Matt Rosen 14 Jan 2, 2023
PortAudio is a portable audio I/O library designed for cross-platform support of audio

PortAudio is a cross-platform, open-source C language library for real-time audio input and output.

PortAudio 786 Jan 1, 2023
🎵 Music notation engraving library for MEI with MusicXML and Humdrum support and various toolkits (JavaScript, Python)

Verovio is a fast, portable and lightweight library for engraving Music Encoding Initiative (MEI) digital scores into SVG images. Verovio also contain

RISM Switzerland 519 Jan 1, 2023
C/C++ library for converting a stream of OPL FM synth chip commands to the OPB music format

OPBinaryLib C/C++ library for converting a stream of OPL FM synth chip commands to the OPB music format Basic usage Store your OPL commands as a conti

Emma Maassen 10 Feb 2, 2022
PendulumSynth is an on-going and open-source project, running on Arduino platform with the goal of mixing real-world physics into music composition and musical performance.

PendulumSynth PendulumSynth is an on-going and open-source project, running on Arduino platform with the goal of mixing real-world physics into music

Mohammadreza Anvari 3 Oct 7, 2022
projectM - cross-platform music visualization. Open-source and Milkdrop-compatible

projectM - cross-platform music visualization. Open-source and Milkdrop-compatible

projectM Visualizer 2.5k Dec 31, 2022
A music player based on RT-thread and AB32VG1.

A music player based on RT-thread and AB32VG1.

杨澄 7 May 16, 2022
By controlling the frequency at which the output Pins of MSP430 are turned off and on, we can make music.

By controlling the frequency at which the output Pins of MSP430 are turned off and on, we can make music.

Premkumar Vincent 1 Nov 9, 2021
Standalone player of Monkey Island PC-Speaker music

Standalone player of Monkey Island PC-Speaker music

Thanassis Tsiodras 29 Oct 7, 2022
Linux client for Archo Music written in C++, uses Qt Framework.

ArchoMusicLinux Linux client for Archo Music written in C++, uses Qt Framework. For the original client, visit Archo Music Compiling Setting up the li

GianXD 2 Nov 13, 2021