Reputation: 392
I am on Windows, and I wish to use Python Bindings for VLC. I've already downloaded the module from https://github.com/geoffsalmon/vlc-python , and did as per the read me. But, still I'm stuck at importing the module. The error looks like this :
Traceback (most recent call last):
File "<pyshell#5>", line 1, in <module>
import vlc
File "c:\python27\python-vlc-1.1.2\vlc.py", line 173, in <module>
dll, plugin_path = find_lib()
File "c:\python27\python-vlc-1.1.2\vlc.py", line 150, in find_lib
dll = ctypes.CDLL('libvlc.dll')
File "C:\Python27\lib\ctypes\__init__.py", line 353, in __init__
self._handle = _dlopen(self._name, mode)
WindowsError: [Error 126] The specified module could not be found
Any Solution on where to place the module ? My main aim is to play MP3 audio files through vlc, which would be part of some other activity.
Upvotes: 4
Views: 4559
Reputation: 34
I paired with 64bit I solved as follows. Of course
# first set the environment which is required from vlc.py
import os
os.environ['PYTHON_VLC_MODULE_PATH'] = """C:\Program Files\VideoLan"""
os.environ['PYTHON_VLC_LIB_PATH'] = """C:\Program Files\VideoLan\VLC\libvlc.dll"""
# now you can import vlc
import vlc
Upvotes: 0
Reputation: 58
I had same problem. It turns out for me if you have 64bit python, you need 64bit vlc player. If you have 32bit python, you need 32bit vlc player.
Hope that works for you too.
Upvotes: 4