view src/main.cpp @ 36:f973f0cc743b

Merge.
author samer
date Wed, 15 Feb 2012 12:26:10 +0000
parents 460c05dd74d0
children
line wrap: on
line source
#include "ofMain.h"
#include "melodyTriangle.h"
#include "ofAppGlutWindow.h"

#define HOST "localhost"
#define PORT 7770
#define NUMVOICES 4
#define RECEIVEPORT 7771

//========================================================================
int main(int argc, const char **argv ){
	
    ofAppGlutWindow window;
	
	if (argc>4 ? atoi(argv[4]) : false){
		ofSetupOpenGL(&window, 1280,800, OF_FULLSCREEN);			// <-------- setup the GL context
	}else{
		ofSetupOpenGL(&window, 800,600, OF_WINDOW);
	}
	// this kicks off the running of my app
	// can be OF_WINDOW or OF_FULLSCREEN
	// pass in width and height too:
	ofRunApp( new melodyTriangle(argc>1 ? argv[1] : HOST, 
								 argc>2 ? atoi(argv[2]) : PORT,
								 argc>3 ? atoi(argv[3]) : NUMVOICES,
								 argc>5 ? atoi(argv[5]) : true,
								 argc>6 ? atoi(argv[6]) : 0,
								 argc>7 ? atoi(argv[7]) : RECEIVEPORT)
			 );

}