diff options
author | jaseg <code@jaseg.net> | 2017-08-03 12:37:55 +0200 |
---|---|---|
committer | jaseg <code@jaseg.net> | 2017-08-03 12:39:44 +0200 |
commit | 48eb88ef549002c66b59ba96418f77fb9515222e (patch) | |
tree | dafa2b17238b5655e3bbf86a646e85ccfd4b3080 /README.rst | |
parent | 1582390031e4891d88424ea1b958aeb67a075385 (diff) | |
download | python-mpv-48eb88ef549002c66b59ba96418f77fb9515222e.tar.gz python-mpv-48eb88ef549002c66b59ba96418f77fb9515222e.tar.bz2 python-mpv-48eb88ef549002c66b59ba96418f77fb9515222e.zip |
Add pillow-based screenshot_raw command
Diffstat (limited to 'README.rst')
-rw-r--r-- | README.rst | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -90,6 +90,12 @@ Advanced Usage print('THERE IS NO ESCAPE') player.register_key_binding('q', my_q_binding) + def my_s_binding(state, key): + if state[0] == 'd': + pillow_img = player.screenshot_raw() + pillow_img.save('screenshot.png') + player.register_key_binding('s', my_s_binding) + player.play('https://youtu.be/DLzxrzFCyOs') player.wait_for_playback() |