Re: Problems embedding python 2.6 in C++

2010-02-02 Thread Gabriel Genellina
En Tue, 02 Feb 2010 02:26:57 -0300, Paul escribió: I've managed to get it working and so far stable... Glad to see you finally made it work! Current working version: [...] mycppclass::callpy(funcname, args...) m_mypymodule = PyImport_Import(pModuleName) pyargs = PyTuple_SetI

Re: Problems embedding python 2.6 in C++

2010-02-01 Thread Paul
Thanks Gabriel, I've managed to get it working and so far stable... What wasn't working reliably: mycppclass mycppclass::mycppclass() m_mypymodule = PyImport_Import(pModuleName) mycppclass::~ mycppclass() Py_XDECREF(m_mypymodule) mycppclass::callpy(funcname, args...)

Re: Problems embedding python 2.6 in C++

2010-02-01 Thread Gabriel Genellina
En Mon, 01 Feb 2010 18:21:56 -0300, Paul escribió: I'm extending some old Visual Studio 6 code to add embedded python scripting. It works fine most of the time but some python function calls do not work as expected. The C++ code is a multithreaded MFC application. I was assuming that it w

Problems embedding python 2.6 in C++

2010-02-01 Thread Paul
Hi, I'm extending some old Visual Studio 6 code to add embedded python scripting. It works fine most of the time but some python function calls do not work as expected. The C++ code is a multithreaded MFC application. I was assuming that it was GIL issues but I have tried using the manual locking