int SCProcess::findNextFreeUdpPort(int startNum) { int server_socket = -1; struct sockaddr_in mBindSockAddr; int numberOfTries=50; int port = startNum; if ((server_socket = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { scprintf("failed to create udp socket\n"); return -1; } bzero((char *)&mBindSockAddr, sizeof(mBindSockAddr)); mBindSockAddr.sin_family = AF_INET; mBindSockAddr.sin_addr.s_addr = htonl(INADDR_ANY); mBindSockAddr.sin_port = htons(port); const int on = 1; setsockopt( server_socket, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)); while (bind(server_socket, (struct sockaddr *)&mBindSockAddr, sizeof(mBindSockAddr)) < 0) { if(--numberOfTries <0 || (errno != EADDRINUSE)) { scprintf("unable to bind udp socket\n"); return -1; } port++; mBindSockAddr.sin_port = htons(port); } close(server_socket); return port; }
void dumpOSC(int mode, int size, char* inData) { if (mode & 1) { if (strcmp(inData, "#bundle") == 0) { char* data = inData + 8; scprintf("[ \"#bundle\", %lld, ", OSCtime(data)); data += 8; char* dataEnd = inData + size; while (data < dataEnd) { int32 msgSize = OSCint(data); data += sizeof(int32); scprintf("\n "); dumpOSCmsg(msgSize, data); data += msgSize; if (data < dataEnd) scprintf(","); } scprintf("\n]\n"); } else { dumpOSCmsg(size, inData); scprintf("\n"); } } if (mode & 2) hexdump(size, inData); }
static bool PlugIn_Load(const char *filename) { #ifdef _WIN32 HINSTANCE hinstance = LoadLibrary( filename ); if (!hinstance) { char *s; DWORD lastErr = GetLastError(); FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, 0, lastErr , 0, (char*)&s, 1, 0 ); scprintf("*** ERROR: LoadLibrary '%s' err '%s'\n", filename, s); LocalFree( s ); return false; } void *ptr = (void *)GetProcAddress( hinstance, SC_PLUGIN_LOAD_SYM ); if (!ptr) { char *s; FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, 0, GetLastError(), 0, (char*)&s, 1, 0 ); scprintf("*** ERROR: GetProcAddress %s err '%s'\n", SC_PLUGIN_LOAD_SYM, s); LocalFree( s ); FreeLibrary(hinstance); return false; } LoadPlugInFunc loadFunc = (LoadPlugInFunc)ptr; (*loadFunc)(&gInterfaceTable); // FIXME: at the moment we never call FreeLibrary() on a loaded plugin return true; #else void* handle = dlopen(filename, RTLD_NOW); if (!handle) { scprintf("*** ERROR: dlopen '%s' err '%s'\n", filename, dlerror()); dlclose(handle); return false; } void *ptr; ptr = dlsym(handle, SC_PLUGIN_LOAD_SYM); if (!ptr) { scprintf("*** ERROR: dlsym %s err '%s'\n", SC_PLUGIN_LOAD_SYM, dlerror()); dlclose(handle); return false; } LoadPlugInFunc loadFunc = (LoadPlugInFunc)ptr; (*loadFunc)(&gInterfaceTable); return true; #endif }
void PublishPortToRendezvous(SCRendezvousProtocol protocol, short portNum) { scprintf("PublishPortToRendezvous %d %hu\n", protocol, portNum); CFStringRef serviceType = 0; switch (protocol) { case kSCRendezvous_UDP: serviceType = CFSTR("_osc._udp."); break; case kSCRendezvous_TCP: serviceType = CFSTR("_osc._tcp."); break; } CFNetServiceRef netServiceRef = CFNetServiceCreate(NULL, // use default allocator CFSTR(""), // use default domain serviceType, CFSTR("SuperCollider"), portNum); // DEBUG if (!netServiceRef) { scprintf("Couldn't create a Rendezvous net service.\n"); return; } CFNetServiceRegisterWithOptions(netServiceRef, 0, NULL); // don't care about the error CFRelease( netServiceRef ); }
void World_LoadGraphDefs(World* world) { GraphDef *list = 0; if(getenv("SC_SYNTHDEF_PATH")){ if(world->mVerbosity > 0) scprintf("Loading synthdefs from path: %s\n", getenv("SC_SYNTHDEF_PATH")); SC_StringParser sp(getenv("SC_SYNTHDEF_PATH"), SC_STRPARSE_PATHDELIMITER); while (!sp.AtEnd()) { GraphDef *list = 0; char *path = const_cast<char *>(sp.NextToken()); list = GraphDef_LoadDir(world, path, list); GraphDef_Define(world, list); } }else{ char resourceDir[MAXPATHLEN]; if(sc_IsStandAlone()) sc_GetResourceDirectory(resourceDir, MAXPATHLEN); else sc_GetUserAppSupportDirectory(resourceDir, MAXPATHLEN); sc_AppendToPath(resourceDir, MAXPATHLEN, "synthdefs"); if(world->mVerbosity > 0) scprintf("Loading synthdefs from default path: %s\n", resourceDir); list = GraphDef_LoadDir(world, resourceDir, list); GraphDef_Define(world, list); } }
AvahiSession::AvahiSession() : mPoll(0), mClient(0), mGroup(0), mEntries(0), mServiceName(0) { int err; mServiceName = avahi_strdup(kSCRendezvousServiceName); mPoll = avahi_threaded_poll_new(); if (!mPoll) { scprintf("Zeroconf: failed to create poll API\n"); return; } mClient = avahi_client_new( avahi_threaded_poll_get(mPoll), (AvahiClientFlags)0, client_cb, this, &err); if (!mClient) { scprintf("Zeroconf: failed to create client: %s\n", avahi_strerror(err)); avahi_threaded_poll_free(mPoll); mPoll = 0; return; } avahi_threaded_poll_start(mPoll); }
static void ReleaseInputBuffers(GraphDef *inGraphDef, UnitSpec *unitSpec, BufColorAllocator& bufColor) { for (int64 i=(int64)(unitSpec->mNumInputs)-1; i>=0; --i) { InputSpec *inputSpec = unitSpec->mInputSpec + i; if (inputSpec->mFromUnitIndex >= 0) { UnitSpec *outUnit = inGraphDef->mUnitSpecs + inputSpec->mFromUnitIndex; OutputSpec *outputSpec = outUnit->mOutputSpec + inputSpec->mFromOutputIndex; inputSpec->mWireIndex = outputSpec->mWireIndex; if (outputSpec->mCalcRate == calc_FullRate) { if (unitSpec->mCalcRate == calc_DemandRate) // we never release any input buffers of demand-rate ugens continue; if (!bufColor.release(outputSpec->mBufferIndex)) { scprintf("buffer coloring error: tried to release output with zero count\n"); scprintf("output: %d %s %d\n", inputSpec->mFromUnitIndex, outUnit->mUnitDef->mUnitDefName, inputSpec->mFromOutputIndex); scprintf("input: %s %d\n", unitSpec->mUnitDef->mUnitDefName, i); throw std::runtime_error("buffer coloring error."); } } } else { inputSpec->mWireIndex = inputSpec->mFromOutputIndex; } } }
CFPropertyListRef Resources::getPropertyList(const char* filename) { CFDataRef xmlCFDataRef; CFStringRef error; char cerror[10240]; CFPropertyListRef myCFPropertyListRef = NULL; Boolean readOK; char filePathBuf[PATH_MAX]; CFStringRef filePath = this->getResourcePath(filename); CFStringGetCString(filePath, filePathBuf, sizeof(filePathBuf), kCFStringEncodingUTF8); CFURLRef fileURL = CFURLCreateFromFileSystemRepresentation (kCFAllocatorDefault, (const unsigned char*)filePathBuf, strlen (filePathBuf), false); if (fileURL!=NULL) { readOK = CFURLCreateDataAndPropertiesFromResource( kCFAllocatorDefault, fileURL, &xmlCFDataRef, NULL, NULL, NULL); if (readOK) { myCFPropertyListRef = CFPropertyListCreateFromXMLData(kCFAllocatorDefault, xmlCFDataRef, kCFPropertyListImmutable, &error); if (error != NULL){ CFStringGetCString(error, cerror, sizeof(cerror), kCFStringEncodingUTF8); scprintf("getPropertyList error: %s\n", cerror); } CFRelease(xmlCFDataRef); } else{ scprintf("Couldn't read Plist File %s\n", filePathBuf); } } return myCFPropertyListRef; }
extern "C" void scsynth_android_initlogging() { SetPrintFunc((PrintFunc) *scvprintf_android); #ifndef NDEBUG scprintf("SCSYNTH->ANDROID logging active (no debug)\n"); #else scprintf("SCSYNTH->ANDROID logging active (debug)\n"); #endif }
int main(int argc, char *argv[]) { setbuf(stdout, NULL); if (argc < 2) { scprintf(_SC("SQDBG error : no file specified")); return -1; } HSQUIRRELVM v = sq_open(1024); sqstd_seterrorhandlers(v); //!! INITIALIZES THE DEBUGGER ON THE TCP PORT 1234 //!! ENABLES AUTOUPDATE HSQREMOTEDBG rdbg = sq_rdbg_init(v, 1234, SQTrue); if (rdbg) { //!! ENABLES DEBUG INFO GENERATION(for the compiler) sq_enabledebuginfo(v, SQTrue); sq_setprintfunc(v, printfunc, errorfunc); //!! SUSPENDS THE APP UNTIL THE DEBUGGER CLIENT CONNECTS if (SQ_SUCCEEDED(sq_rdbg_waitforconnections(rdbg))) { scprintf(_SC("connected\n")); const SQChar *fname = NULL; #ifdef _UNICODE SQChar sTemp[256]; mbstowcs(sTemp,argv[1],(int)strlen(argv[1])+1); fname=sTemp; #else fname = argv[1]; #endif //!!REGISTERS STANDARDS LIBS sq_pushroottable(v); sqstd_register_bloblib(v); sqstd_register_iolib(v); //!!EXECUTE A SCTIPT if (SQ_FAILED(sqstd_dofile(v, fname, SQFalse, SQTrue))) { PrintError(v); #if defined(_WIN32) || defined(_WIN64) _getch(); #else getch(); #endif } } //!! CLEANUP sq_rdbg_shutdown(rdbg); } else { PrintError(v); } sq_close(v); return 0; }
bool BufReadCmd::Stage2() { #ifdef NO_LIBSNDFILE SendFailure(&mReplyAddress, "/b_read", "scsynth compiled without libsndfile\n"); scprintf("scsynth compiled without libsndfile\n"); return false; #else SF_INFO fileinfo; SndBuf *buf = World_GetNRTBuf(mWorld, mBufIndex); int framesToEnd = buf->frames - mBufOffset; if (framesToEnd <= 0) return true; SNDFILE* sf = sf_open(mFilename, SFM_READ, &fileinfo); if (!sf) { char str[512]; sprintf(str, "File '%s' could not be opened: %s\n", mFilename, sf_strerror(NULL)); SendFailureWithIntValue(&mReplyAddress, "/b_read", str, mBufIndex); //SendFailure(&mReplyAddress, "/b_read", str); scprintf(str); return false; } if (fileinfo.channels != buf->channels) { char str[512]; sf_close(sf); sprintf(str, "Channel mismatch. File '%s' has %d channels. Buffer has %d channels.\n", mFilename, fileinfo.channels, buf->channels); SendFailureWithIntValue(&mReplyAddress, "/b_read", str, mBufIndex); //SendFailure(&mReplyAddress, "/b_read", str); scprintf(str); return false; } if (mFileOffset < 0) mFileOffset = 0; else if (mFileOffset > fileinfo.frames) mFileOffset = fileinfo.frames; if (mNumFrames < 0 || mNumFrames + mFileOffset > fileinfo.frames) mNumFrames = fileinfo.frames - mFileOffset; if (mNumFrames > framesToEnd) mNumFrames = framesToEnd; sf_seek(sf, mFileOffset, SEEK_SET); if (mNumFrames > 0) { sf_readf_float(sf, buf->data + (mBufOffset * buf->channels), mNumFrames); } if(buf->sndfile) sf_close(buf->sndfile); if (mLeaveFileOpen) { buf->sndfile = sf; } else { sf_close(sf); buf->sndfile = 0; } mSampleRate = (double)fileinfo.samplerate; return true; #endif }
void DumpLiteral(SQObjectPtr &o) { switch(type(o)){ case OT_STRING: scprintf(_SC("\"%s\""),_stringval(o));break; case OT_FLOAT: scprintf(_SC("{%f}"),_float(o));break; case OT_INTEGER: scprintf(_SC("{") _PRINT_INT_FMT _SC("}"),_integer(o));break; case OT_BOOL: scprintf(_SC("%s"),_integer(o)?_SC("true"):_SC("false"));break; default: scprintf(_SC("(%s %p)"),GetTypeName(o),(void*)_rawval(o));break; break; //shut up compiler } }
/* * this is like World_OpenUDP() except it stores a static reference to the object * TODO: maybe we could destatickify by pass a reference to the object back to java, to be passed to the closer? */ extern "C" void scsynth_android_open_udp(JNIEnv* env, jobject obj, jint port) { scprintf("scsynth_android_open_udp\n"); try { udpInPort = new SC_UdpInPort(world, port); } catch (std::exception& exc) { scprintf("Exception in scsynth_android_open_udp: %s\n", exc.what()); udpInPort = NULL; } catch (...) { } }
void World_AddGraphDef(World *inWorld, GraphDef* inGraphDef) { bool added = inWorld->hw->mGraphDefLib->Add(inGraphDef); if(!added) scprintf("ERROR: Could not add SynthDef %s.\nTry adjusting ServerOptions:maxSynthDefs or the -d cmdline flag.\n", (char*)inGraphDef->mNodeDef.mName); for (uint32 i=0; i<inGraphDef->mNumVariants; ++i) { GraphDef* var = inGraphDef->mVariants + i; added = inWorld->hw->mGraphDefLib->Add(var); if(!added) scprintf("ERROR: Could not add SynthDef %s.\nTry adjusting ServerOptions:maxSynthDefs or the -d cmdline flag.\n", (char*)var->mNodeDef.mName); } }
void PrintError(HSQUIRRELVM v) { const SQChar *err; sq_getlasterror(v); if(SQ_SUCCEEDED(sq_getstring(v,-1,&err))) { scprintf(_SC("SQDBG error : %s"),err); }else { scprintf(_SC("SQDBG error"),err); } sq_pop(v,1); }
void Group_CalcTrace(Group *inGroup) { scprintf("TRACE Group %d\n", inGroup->mNode.mID); Node *child = inGroup->mHead; while (child) { Node *next = child->mNext; scprintf(" %d %s\n", child->mID, (char*)child->mDef->mName); (*child->mCalcFunc)(child); child = next; } inGroup->mNode.mCalcFunc = (NodeCalcFunc)&Group_Calc; }
GraphDef* GraphDef_Recv(World *inWorld, char *buffer, GraphDef *inList) { try { inList = GraphDefLib_Read(inWorld, buffer, inList); } catch (std::exception& exc) { scprintf("exception in GraphDef_Recv: %s\n", exc.what()); } catch (...) { scprintf("unknown exception in GraphDef_Recv\n"); } return inList; }
void AvahiSession::CreateServices(AvahiClient* client) { int err; if (mGroup) { avahi_entry_group_reset(mGroup); } else { mGroup = avahi_entry_group_new(client, group_cb, this); if (!mGroup) { scprintf("Zeroconf: failed to create entry group: %s\n", avahi_strerror(avahi_client_errno(client))); return; } } mMutex.lock(); AvahiEntry* entry = mEntries; while (entry) { const char* type = SCRendezvousProtocolString(entry->mProto); err = avahi_entry_group_add_service( mGroup, AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC, (AvahiPublishFlags)0, mServiceName, type, NULL, NULL, entry->mPort, NULL); if (err == AVAHI_ERR_COLLISION) { // BUG: shouldn't this actually be triggered in the entry // group callback? RenameService(); err = avahi_entry_group_add_service( mGroup, AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC, (AvahiPublishFlags)0, mServiceName, type, NULL, NULL, entry->mPort, NULL); } if (err < 0) { scprintf("Zeroconf: failed to register service '%s': %s\n", mServiceName, avahi_strerror(err)); } entry = entry->mNext; } mMutex.unlock(); if (!avahi_entry_group_is_empty(mGroup)) { err = avahi_entry_group_commit(mGroup); if (err < 0) { scprintf("Zeroconf: failed to commit entry group: %s\n", avahi_strerror(err)); return; } } }
extern "C" void scsynth_android_makeSynth(JNIEnv* env, jobject obj, jstring theName){ if (world->mRunning){ jboolean isCopy; const char* synthName = env->GetStringUTFChars(theName, &isCopy); scprintf("scsynth_android_makeSynth(%s)\n", synthName); OSCMessages messages; small_scpacket packet; size_t messageSize = messages.createSynthMessage(&packet, synthName); World_SendPacket(world,messageSize, (char*)packet.buf, null_reply_func); env->ReleaseStringUTFChars(theName, synthName); }else{ scprintf("scsynth_android_makeSynth: not running!\n"); } }
extern "C" void scsynth_android_close_udp(JNIEnv* env, jobject obj) { scprintf("scsynth_android_close_udp\n"); if(udpInPort==NULL){ scprintf("scsynth_android_close_udp : no open port to close\n"); return; } try { udpInPort->~SC_UdpInPort(); udpInPort = NULL; } catch (std::exception& exc) { scprintf("Exception in scsynth_android_close_udp: %s\n", exc.what()); } catch (...) { } }
GraphDef* GraphDef_LoadDir(World *inWorld, char *dirname, GraphDef *inList) { SC_DirHandle *dir = sc_OpenDir(dirname); if (!dir) { scprintf("*** ERROR: open directory failed '%s'\n", dirname); return inList; } for (;;) { char diritem[MAXPATHLEN]; bool skipItem = false; bool validItem = sc_ReadDir(dir, dirname, diritem, skipItem); if (!validItem) break; if (skipItem) continue; if (sc_DirectoryExists(diritem)) { inList = GraphDef_LoadDir(inWorld, diritem, inList); } else { int dnamelen = strlen(diritem); if (strncmp(diritem+dnamelen-9, ".scsyndef", 9) == 0) { inList = GraphDef_Load(inWorld, diritem, inList); } } } sc_CloseDir(dir); return inList; }
void HowlSession::PublishPort(sw_discovery session, SCRendezvousProtocol protocol, short portNum) { const char* serviceType = SCRendezvousProtocolString(protocol); sw_discovery_oid oid; sw_result res = sw_discovery_publish( session, 0, // interface kSCRendezvousServiceName, // name serviceType, // type 0, // domain (.local) 0, // host portNum, // port 0, 0, // text records howl_publish_reply_func, 0, // reply func &oid // request id ); scprintf( "Zeroconf: publishing service %s on port %hu %s\n", serviceType, portNum, res == SW_OKAY ? "succeeded" : "failed" ); }
int BufWriteCmd::Init(char *inData, int inSize) { #ifdef NO_LIBSNDFILE SendFailure(&mReplyAddress, "/b_write", "scsynth compiled without libsndfile\n"); scprintf("scsynth compiled without libsndfile\n"); return false; #else sc_msg_iter msg(inSize, inData); mBufIndex = msg.geti(); const char *filename = msg.gets(); if (!filename) return kSCErr_WrongArgType; if(mWorld->mRestrictedPath){ mFilename = allocAndRestrictPath(mWorld, filename, mWorld->mRestrictedPath); }else{ mFilename = (char*)World_Alloc(mWorld, strlen(filename)+1); strcpy(mFilename, filename); } const char *headerFormatString = msg.gets("aiff"); const char *sampleFormatString = msg.gets("int16"); mNumFrames = msg.geti(-1); mBufOffset = msg.geti(); mLeaveFileOpen = msg.geti(); GET_COMPLETION_MSG(msg); memset(&mFileInfo, 0, sizeof(mFileInfo)); return sndfileFormatInfoFromStrings(&mFileInfo, headerFormatString, sampleFormatString); #endif }
void sc_jack_shutdown_cb(void* arg) { scprintf("%s: killed by jack\n", kJackDriverIdent); World * world = (World*)arg; world->hw->mTerminating = true; world->hw->mQuitProgram->post(); }
SCErr meth_s_newargs(World *inWorld, int inSize, char *inData, ReplyAddress* /*inReply*/) { SCErr err; sc_msg_iter msg(inSize, inData); int32 *defname = msg.gets4(); if (!defname) return kSCErr_WrongArgType; int32 nodeID = msg.geti(); int32 addAction = msg.geti(); GraphDef *def = World_GetGraphDef(inWorld, defname); if (!def) { scprintf("*** ERROR: SynthDef %s not found\n", (char*)defname); return kSCErr_SynthDefNotFound; } Graph *graph = 0; switch (addAction) { case 0 : { Group *group = Msg_GetGroup(inWorld, msg); if (!group) return kSCErr_GroupNotFound; err = Graph_New(inWorld, def, nodeID, &msg, &graph,false);//false for setn type args if (err) return err; if (!graph) return kSCErr_Failed; Group_AddHead(group, &graph->mNode); } break; case 1 : { Group *group = Msg_GetGroup(inWorld, msg); if (!group) return kSCErr_GroupNotFound; err = Graph_New(inWorld, def, nodeID, &msg, &graph,false); if (err) return err; Group_AddTail(group, &graph->mNode); } break; case 2 : { Node *beforeThisNode = Msg_GetNode(inWorld, msg); if (!beforeThisNode) return kSCErr_NodeNotFound; err = Graph_New(inWorld, def, nodeID, &msg, &graph,false); if (err) return err; Node_AddBefore(&graph->mNode, beforeThisNode); } break; case 3 : { Node *afterThisNode = Msg_GetNode(inWorld, msg); if (!afterThisNode) return kSCErr_NodeNotFound; err = Graph_New(inWorld, def, nodeID, &msg, &graph,false); if (err) return err; Node_AddAfter(&graph->mNode, afterThisNode); } break; case 4 : { Node *replaceThisNode = Msg_GetNode(inWorld, msg); if (!replaceThisNode) return kSCErr_NodeNotFound; err = Graph_New(inWorld, def, nodeID, &msg, &graph,false); if (err) return err; Node_Replace(&graph->mNode, replaceThisNode); } break; default: return kSCErr_Failed; } Node_StateMsg(&graph->mNode, kNode_Go); return kSCErr_None; }
void PrintFunc(HSQUIRRELVM vm, const SQChar* fmt, ...) { va_list l; va_start(l, fmt); _vtcprintf(fmt, l); scprintf(_SC("\n")); va_end(l); }
void ConnectPorts(const char * src, const char * dst) { int err = jack_connect(mClient, src, dst); scprintf("%s: %s %s to %s\n", kJackDriverIdent, err ? "couldn't connect " : "connected ", src, dst); }
static void hexdump(int size, char* data) { char ascii[20]; int padsize = (size + 15) & -16; scprintf("size %d\n", size); for (int i=0; i<padsize; ++i) { if ((i&15)==0) { scprintf("%4d ", i); } if (i >= size) { scprintf(" "); ascii[i&15] = 0; } else { scprintf("%02x ", (unsigned char)data[i] & 255); if (isprint(data[i])) ascii[i&15] = data[i]; else ascii[i&15] = '.'; } if ((i&15)==15) { ascii[16] = 0; scprintf(" |%s|\n", ascii); } else if ((i&3)==3) { scprintf(" "); } } scprintf("\n"); }
static bool dumpOSCbndl(int indent, int size, char *inData) { char* data = inData + 8; char* dataEnd = inData + size; scprintf("[ \"#bundle\", %" PRIu64 ", ", OSCtime(data)); data += 8; while (data < dataEnd) { int contentPrinted; int32 msgSize = OSCint(data); data += sizeof(int32); scprintf("\n"); for (int i=0; i<indent+1; i++) scprintf(" "); if (!strcmp(data, "#bundle")) contentPrinted = dumpOSCbndl(indent+1, msgSize, data); else contentPrinted = dumpOSCmsg(msgSize, data, true); data += msgSize; if ( (data < dataEnd) && contentPrinted) scprintf(","); } scprintf("\n"); for (int i=0; i<indent; i++) scprintf(" "); scprintf("]"); return true; }
extern "C" void scsynth_android_doOsc(JNIEnv* env, jobject classobj, jobjectArray oscMessage){ if (world->mRunning){ small_scpacket packet; makePacket(env,oscMessage,packet); World_SendPacket(world, packet.size(), (char*)packet.buf, androidReplyFunc); }else{ scprintf("scsynth_android_doOsc: not running!\n"); } }