Audio Manipulation in C++

Hi all. I hope this is the right place to post this.

I am a music technology student and I’ve recently picked up learning C++ as it would greatly help my career knowing a programming language, especially this one since it is used in the video games industry.

Anyways onto the main topic. What I want to create is a program (in C++) that lets the user load a 16bit linear PCM WAVE file. Then I want to manipulate the audio sample data within that wave file. I want to either remove every nth sample or randomise them within a certain parameter (±10%). Then write it as a new WAVE file.

I am familier with the structure of WAVE files and the RIFF header. I also at the moment use Xcode as my IDE (since my macbook pro is my work computer), but I can code on my PC if necessary using codeblocks.

So in simple terms it should display something similar to this? I know there are errors in this, just so you get an idea of what I’m after:

#include <iostream>
using namespace std;

class main()	//function start
	string fileinput;	//variable
	string outlocation;	//variable
	cout << "please type file path directory: n n";
	cin >> fileinput;	//navigate to file by typing
	cout << "Where would you like to save new file? n n";
	cin >> outlocation;	//select output by typing
	// Then all the maths and manipulation is done
	cout << "Your file has been created at ";
	cout << outlocation;
	cout << "n n";
	return 0;

Is it possible to do this in Xcode, if at all? What libraries would I need? I hope its simpler than I think it is.

Thankyou for your help and time.



Mac developers rarely hang round on the Forum. You could try subscribing to audacity-devel mailing list and asking (gently) for a few pointers. We are very busy working up to a new 1.3.13 Beta release.