I am hoping that someone can help with a Python bindings output question (using vlc.py)
I have a basic test script that uses vlc.py which runs but does not play the video.
import vlc
def setup_player(filename):
vlc_instance = vlc.Instance('--no-audio', '--fullscreen')
player = vlc_instance.media_player_new()
media = vlc_instance.media_new(filename)
player.set_media(media)
print media.get_mrl() # File location to get title
print player.get_length() #Time duration of file -1 means there is no media
print player.get_state() #Player's state
player.play()
setup_player('foo.mp4')
This outputs
file:///Users/admin/Sites/pythontest/foo.mp4
-1
State.NothingSpecial
I am unsure where to install the vlc.py module and hoping someone can help. I'm on MacOs, VLC 2.0.9, Python 2.7.3. Running python through the terminal.
At the moment I have the vlc.py module in the same directory as my test script - and outside of the VLC.app directories and although the script is executing without errors it isn't playing the video or returning any parameters about the specified mp4 file.
Apologies for a banal question! Any help very gratefully received.