From 03c7468fcc51888c8271b904e4d6400ed5c1cbb1 Mon Sep 17 00:00:00 2001 From: Thomas Grill Date: Wed, 7 Mar 2007 13:40:14 +0000 Subject: multiply inlets for py (hot and cold inlets) small optimizations and fixes use PyGILState_\*() functionality (enabled with PY_USE_GIL) updates for DSP processing __str__ method for pyext, to enable print self calls added message bundle functionality (pyext.Bundle class) enable compiled-only scripts (without .py) enable optimization of Python code in reease build let _inlets and _outlets default to 0 fix for numpy some ASSERTs for explicitly created pyext classes (should be runtime checks i guess) open editor for script under OS X fixing numpy initialization quirks enable symbol binding for all callables (not only functions and methods) _isthreaded is now a data member instead of a method fix for gcc4 added pyext._list and pyext._tuple to convert input lists to Python sequence objects enable module packages (module/__init__.py[co]), now also for Max python-like dotted module.function syntax cleaned up float vs. int pyext tags compiler flag to exclude DSP objects some optimizations and py reload fix more safety for calls where association python-pd has already been removed always run Python interpreter in the background svn path=/trunk/; revision=7474 --- externals/grill/py/source/pyprefix.h | 86 ++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 43 deletions(-) (limited to 'externals/grill/py/source/pyprefix.h') diff --git a/externals/grill/py/source/pyprefix.h b/externals/grill/py/source/pyprefix.h index de74ca42..9be12e85 100644 --- a/externals/grill/py/source/pyprefix.h +++ b/externals/grill/py/source/pyprefix.h @@ -1,43 +1,43 @@ -/* - -py/pyext - python script object for PD and MaxMSP - -Copyright (c)2002-2005 Thomas Grill (gr@grrrr.org) -For information on usage and redistribution, and for a DISCLAIMER OF ALL -WARRANTIES, see the file, "license.txt," in this distribution. - -*/ - -#ifndef __PYPREFIX_H -#define __PYPREFIX_H - -#define FLEXT_ATTRIBUTES 1 -#include - -// hack: must include math.h before Python.h (at least on OSX) -// otherwise some functions don't get defined -#include - -#if FLEXT_OS == FLEXT_OS_MAC -#include -#else -#include -#endif - -#if !defined(FLEXT_VERSION) || (FLEXT_VERSION < 501) -#error You need at least flext version 0.5.1 -#endif - -#if FLEXT_OS == FLEXT_LINUX || FLEXT_OS == FLEXT_IRIX -#include -#endif - -#if FLEXT_SYS == FLEXT_SYS_PD && (!defined (PD_MINOR_VERSION) || PD_MINOR_VERSION < 37) -#error PD version >= 0.37 required, please upgrade! -#endif - -#include -#include - - -#endif +/* + +py/pyext - python script object for PD and MaxMSP + +Copyright (c)2002-2005 Thomas Grill (gr@grrrr.org) +For information on usage and redistribution, and for a DISCLAIMER OF ALL +WARRANTIES, see the file, "license.txt," in this distribution. + +*/ + +#ifndef __PYPREFIX_H +#define __PYPREFIX_H + +#define FLEXT_ATTRIBUTES 1 +#include + +// hack: must include math.h before Python.h (at least on OSX) +// otherwise some functions don't get defined +#include + +#if FLEXT_OS == FLEXT_OS_MAC +#include +#else +#include +#endif + +#if !defined(FLEXT_VERSION) || (FLEXT_VERSION < 501) +#error You need at least flext version 0.5.1 +#endif + +#if FLEXT_OS == FLEXT_LINUX || FLEXT_OS == FLEXT_IRIX +#include +#endif + +#if FLEXT_SYS == FLEXT_SYS_PD && (!defined (PD_MINOR_VERSION) || PD_MINOR_VERSION < 37) +#error PD version >= 0.37 required, please upgrade! +#endif + +#include +#include + + +#endif -- cgit v1.2.1