compile with only necessary files to get mic's volume

I’m trying to create a program to decode morse code by using the microphone.
I had some trouble to understand how to work with DirectSound, and i’ve tried to download rtAudio but it didn’t compile under vs2010.
so i’ve modified the “audioInputExample” to my needs
1.added some fields in testApp class
2.added a “morse” function that translate integer (1 is dot and 2 is line) to char
3.added fields in draw() to see results

the main algorithm is in update() :

	if((scaledVol*100)<50){ //background noise -> logic "0"  
		if (oneCounter){ //if this is an end of logic "1" recieved  
			if (oneCounter<28){  
				x=x*10+1; //temp value of corrent letter - easier to convert from integer (x)  
		if((zeroCounter>25) && index && x){ //end of letter  
			text2[Tindex++]=morse(x); //decode x and display it  
	else{ // logic "1"  
		if (zeroCounter){ //end of spacing  
			if((zeroCounter>25) && index)  
					text[index++]=' ';  
					text2[Tindex++]=' ';  

as you can see I only use “scaledVol” for my needs, i want to know how can i take from OpenFrameworks only necessary files to compile a simple program that uses a scaled volume from microphone input.
(i dont have to use the testApp at all, i want to create the user interface using visual studio “forms”)
at the end i need to submit my work and the OF folder is like 1.3 GB, i’ve tried to delete some folders and i got left with ~300MB before it didn’t compile anymore, it’s still huge.

by the way im using Win7

Thank you

You definitely don’t need the entire OF folder, just the application in app/bin and the data folder included with it. That executable should be portable to any other Windows 7 computer.

Thanks for the reply

I need to submit my work uncompiled - with all c++ code files and headers
(this is a part of a university course)

Ah, well, then I suppose you might need to just use raw rtAudio then. It does compile on Windows and plays nice with both DirectSOund and ASIO though I don’t think it has Visual Studio projects ready to go. If you remove all the other examples, addons, and the precompiled OF libs, I’d bet OF is around 20mb, so that might be small enough, but I can’t imagine that your professors would want to dig through all those file.

I’m wondering, is there an automatic C++ way of detecting which files are touched/needed in a program. This would enable people to ship only the files they need. Surely, it would need some #include magic I’m sure, but may be viable?

hi buchi,

i think that information is only known at link-time… i guess you could use nm to dump out the symbols compiled into the oF resulting app and then backtrack to only include the source files/libs that contribute to that, but it would be a lot of work.

ohad.baron: welcome to openFrameworks! it sounds like an interesting project, is it for a course?

openFrameworks is a ‘framework’ rather than a ‘library’, that means that it is designed to be used as a complete system itself. it’s not so easy to include openFrameworks code inside another framework (such as a Forms based application). if you can make the gui using one of the UI addons on then that would save having to use Forms, but if not then i’m not sure what your options are.

the easiest way to include a bare minimum for submission is to start from a freshly downloaded openFrameworks installation (if you’re working from the git repository then you have the entire history of the project as well, and that’s huge). delete everything in examples/ and if you’re not using any addons, everything in addons/ as well. then make sure that the only files in apps/ are the files you need for your morse code project. this should get you down to < 100MB.