/************************************************************************** * main.c: The main program and supporting stuff. * Part of MP, the MIDI Playground. * * Author: Daniel Barrett * Version: See the file "version.h". * Copyright: None! This program is in the Public Domain. * Please share it with others. ***************************************************************************/ #include "mp.h" BOOL WorkbenchProgram(char *argv[]); BOOL CommandLineProgram(int argc, char *argv[]); main(int argc, char *argv[]) { BOOL success; if (argc == 0) success = WorkbenchProgram(argv); else success = CommandLineProgram(argc, argv); exit(success ? RETURN_OK : RETURN_FAIL); } /************************************************************************ * Initialization of important variables. ************************************************************************/ void InitStuff(FLAGS theFlags[], FILE **in, FILE **out, char **inFile, char **outFile) { int i; for (i=0; i