yardbird wrote:
> On Saturday 16 December 2006 19:42, Xavier Gnata wrote:

>> Each time I'm working on C++ codes using vector or valarray, I would
>> like to be able to plot them.

> you should really check out the Boost::Python libraries. They allow you, 
> among 
> other things, to expose your C++ container classes as python objects. I'm 
> using them heavily in my project and I'm very satisfied.

What this means is that you'd be using python to drive your C++ code, 
rather than using C++ code to drive a python/mpl code. In addition to 
Boost::Python, there are some other options to consider:

pyrex, Cxx, SWIG.

The other option is to use your C++ code to drive Python. This can be 
done by embedding a python interpreter in your C++ app. See the 
odfficial pyhton docs, and lots of other stuff online.

You also might want to check out Elmer:

http://elmer.sourceforge.net/

I've never used it, but it looks pretty cool. It's a tool that provides 
the infrastructure for calling python from C/C++.

Honestly, though, I'd go with the first approach -- drive your C++ code 
from Python -- I think that in addition to making it easy to plot 
results, etc, you'll be able to write unit tests, etc in python, and 
even get a full scripting engine, which could turn out to be very useful..

-Chris



-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[EMAIL PROTECTED]

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to