summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorjaseg <code@jaseg.net>2016-08-13 19:07:44 +0200
committerjaseg <code@jaseg.net>2016-08-13 19:14:14 +0200
commitde7b6711035a187492f9753fc8808d9c2ad1dd55 (patch)
tree92feb473a2e3b258db1ae7e55465938bb550b49a /README.md
parent4d6c17d342582827f8989331f8800fd96d735e8b (diff)
downloadpython-mpv-de7b6711035a187492f9753fc8808d9c2ad1dd55.tar.gz
python-mpv-de7b6711035a187492f9753fc8808d9c2ad1dd55.tar.bz2
python-mpv-de7b6711035a187492f9753fc8808d9c2ad1dd55.zip
Finally add node handling, fix ALL THE THINGS
* New node handling * Add remaining properties * Improve property type handling (no more ynbool!) * Add pröper option access * Add a whole bunch of tests
Diffstat (limited to 'README.md')
-rw-r--r--README.md3
1 files changed, 3 insertions, 0 deletions
diff --git a/README.md b/README.md
index bbdac86..2a3b61c 100644
--- a/README.md
+++ b/README.md
@@ -32,9 +32,12 @@ def my_log(loglevel, component, message):
player = mpv.MPV(log_handler=my_log, ytdl=True)
+# Property access, these can be changed at runtime
player.observe_property('time-pos', lambda _property, pos: print('Now playing at {:.2f}s'.format(pos)))
player.fullscreen = True
player.loop = 'inf'
+# Option access, in general these require the core to reinitialize
+player['vo'] = 'opengl'
player.play('https://youtu.be/DLzxrzFCyOs')
player.wait_for_playback()