Version 4.4.0

This commit is contained in:
Gary Scavone
2013-09-29 23:11:39 +02:00
committed by Stephen Sinclair
parent d199342e86
commit eccd8c9981
287 changed files with 11712 additions and 7676 deletions

View File

@@ -28,14 +28,24 @@
This class is primarily for use in STK example programs but it is
generic enough to work in many other contexts.
by Perry R. Cook and Gary P. Scavone, 1995 - 2007.
by Perry R. Cook and Gary P. Scavone, 1995 - 2009.
*/
/***************************************************/
#include "Messager.h"
#include <iostream>
#include <algorithm>
#include "SKINI.msg"
namespace stk {
#if defined(__STK_REALTIME__)
extern "C" THREAD_RETURN THREAD_TYPE stdinHandler(void * ptr);
extern "C" THREAD_RETURN THREAD_TYPE socketHandler(void * ptr);
#endif // __STK_REALTIME__
static const int STK_FILE = 0x1;
static const int STK_MIDI = 0x2;
static const int STK_STDIN = 0x4;
@@ -152,6 +162,8 @@ bool Messager :: startStdInput()
return true;
}
//} // stk namespace
THREAD_RETURN THREAD_TYPE stdinHandler(void *ptr)
{
Messager::MessagerData *data = (Messager::MessagerData *) ptr;
@@ -208,6 +220,8 @@ void midiHandler( double timeStamp, std::vector<unsigned char> *bytes, void *ptr
data->mutex.unlock();
}
//namespace stk {
bool Messager :: startMidiInput( int port )
{
if ( data_.sources == STK_FILE ) {
@@ -290,6 +304,8 @@ bool Messager :: startSocketInput( int port )
return true;
}
//} // stk namespace
#if (defined(__OS_IRIX__) || defined(__OS_LINUX__) || defined(__OS_MACOSX__))
#include <sys/time.h>
#include <errno.h>
@@ -412,4 +428,7 @@ THREAD_RETURN THREAD_TYPE socketHandler(void *ptr)
return NULL;
}
} // stk namespace
#endif