Issues importing gtstreamer in python

人盡茶涼 提交于 2019-12-13 02:55:14

问题


I've run the windows installer, but I'm unsure how to begin using gtstreamer. The tutorials I've read simply instruct me to install the package and then import the module pygst, but when I try that I get an ImportError: No module named pygst.

I've searched my C drive. and it seems to have installed to /program files/OSSBuild/GStreamer, but I'm unsure how to access it. To date, every module I've installed automatically adds itself to lib/site packages or has the setup.py file. This one does not, so it's a bit foreign to me.

How do I get up and running..?


回答1:


You may want to try editing the PYTHONPATH environment variable to include that directory (separate the paths by semicolons). Example: Add C:\program files\OSSBuild\GStreamer to the end C:\Python27\Lib;C:\other-python-files-etc;C:\program files\OSSBuild\GStreamer

Per this answer here: https://stackoverflow.com/a/4855685/1124529

Also, you may want to check to make sure that in that GStreamer folder there is a file called pygst.py since that is how the module will look. If not, you may have downloaded the wrong thing.



来源:https://stackoverflow.com/questions/14064611/issues-importing-gtstreamer-in-python

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!