Hi,
I have trouble compiling the simplest examples with Boost.Python. I
hope you could help me find out what I'm doing wrong.
I am using Microsoft Visual C++ 2010 on 64-bit Windows 7. I use 64-bit
version of Python 2.7.2 from Enthought Python Distribution 7.2-2. I
installed Boost as described in "
I'm having a conceptual issue with the way C++ interfaces with Python.
I'm trying to convert a C++ object to a Python object, but my attempt
causes the program to crash. I suspect I'm doing a lot of things
wrong. Ultimately I'd like to be able to pass C++ objects to a python
function that modifies
DarkAnt,
have you tried taking out the explicit to_python converter ? I don't
think you need that, as the class_ will already implicitly provide
that.
Also, out of curiosity: I'm not sure the "coord" member conversion will
work out-of-the-box, unless you also reflect std::pair to
Python using clas
I removed everything except int health and I still crash. If I do not
have the explicit to_python converter I receive this error message:
TypeError: No to_python (by-value) converter found for C++ type: Unit
On Tue, Apr 3, 2012 at 11:20 AM, Stefan Seefeld wrote:
> DarkAnt,
>
> have you tried taki
DarkAnt,
the problem is that you don't initialize / import the newly defined
module. The attached version works fine for me.
Stefan
--
...ich hab' noch einen Koffer in Berlin...
#include
#include
struct Unit
{
int health;
std::string name;
std::string type;
std::pair
Thanks a bunch Stefan!
On Tue, Apr 3, 2012 at 12:01 PM, Stefan Seefeld wrote:
> DarkAnt,
>
> the problem is that you don't initialize / import the newly defined
> module. The attached version works fine for me.
>
> Stefan
>
> --
>
> ...ich hab' noch einen Koffer in Berlin...
>
___
On Tue, Apr 3, 2012 at 4:12 AM, Payam Shiva wrote:
> Hi,
>
> I have trouble compiling the simplest examples with Boost.Python. I
> hope you could help me find out what I'm doing wrong.
> I am using Microsoft Visual C++ 2010 on 64-bit Windows 7. I use 64-bit
> version of Python 2.7.2 from Enthough
>It looks to me like you're not as concerned with building the DLL as you with
>just
> using them. If that is the case, then maybe consider the pre-built
> libraries you could get here:
>
> http://www.boostpro.com/download/
The problem is that my home computer, which I use for development,
isn't