Is there any way to include python code in a C/C++ program? for example write a C++ program that prints hello world then calls a python script thats been linked to the executable then returns back to the C++ code after it's finished?
Python in C/C++?
Started by JewFro297, Jan 13 2010 06:54 AM
4 replies to this topic
#1
Posted 13 January 2010 - 06:54 AM
Yea Dat's right.
Apple sucks :thumbup:
[SIGPIC][/SIGPIC]
Apple sucks :thumbup:
[SIGPIC][/SIGPIC]
|
|
|
#2
Posted 13 January 2010 - 07:24 AM
This may help, it's the documentation for extending Python through C++.
A man can be defined by what he does when no one is looking.
Science is only an educated theory, which we cannot disprove.
Science is only an educated theory, which we cannot disprove.
#3
Posted 13 January 2010 - 07:25 AM
#4
Posted 14 March 2010 - 07:01 PM
Yes you can run the python script file by calling it from the command line within the C++ program
#5
Posted 02 April 2010 - 05:30 PM
You can also use distutils to compile C/C++ code and import it as a Python module(.pyd), and you can also call Python inside a C/C++ application and use the returned PyObjects* with the C Python API.
basically... the link thegamemaker gave you :D
basically... the link thegamemaker gave you :D


Sign In
Create Account


Back to top









