diff --git a/src/core/chuck.cpp b/src/core/chuck.cpp index f07455278..347cc2ec5 100644 --- a/src/core/chuck.cpp +++ b/src/core/chuck.cpp @@ -1587,6 +1587,28 @@ void ChucK::poop() +//----------------------------------------------------------------------------- +// name: bind() +// desc: additional native chuck bindings/types (use with extra caution) +//----------------------------------------------------------------------------- +t_CKBOOL ChucK::bind( f_ck_query queryFunc, const std::string & name ) +{ + // check if we have initialized a compiler + if( !compiler() ) + { + // error message + EM_error2( 0, "cannot bind() -- ChucK/compiler is not initialized..." ); + // done + return FALSE; + } + + // perform the bind + return compiler()->bind( queryFunc, name ); +} + + + + //----------------------------------------------------------------------------- // name: setMainThreadHook() // desc: set a function pointer to call from the main thread loop