> -----Original Message----- > From: Ignas Anikevicius [mailto:anikevic...@gmail.com] > Sent: Friday, April 13, 2012 4:25 PM > To: matplotlib-users@lists.sourceforge.net > Subject: [Matplotlib-users] Matplotlib and Cpp > > Dear all, > > I was wondering if it is possible to use matplotlib from C++ directly > and I have found an example on how to do this on StackOverflow: > > http://stackoverflow.com/questions/2509156/anyone-knows-a-matplotlib- > equivalent-in-c-or-c > > However, my question is about piping. Where could I find any tutorials > on how to pipe data directly to matplotlib so that I would not need to > right it to a file and then read it? > > Also, does matplotlib benefit from usage of cython and if it does, are > there any things I should know before just trying to compile a > matplotlib script with cython? > > All best, > Ignas A. >
You're trying to solve the wrong problem. If you want to use matplotlib to show your results this way the easiest thing to do would be to rework so that python was the driver. i.e wrap your C++ code so that a python program called it instead of trying to call python from C++. The better solution here is probably to abandon matplotlib and use a plotting library that has C bindings. One example is DISLIN, but I'm sure there are others (and don't take this as a recommendation.) Eric ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users