Commit graph

158 commits

Author SHA1 Message Date
jaseg
16cd0b338e Windows: Look for mpv.dll next to mpv.py 2024-08-14 11:05:01 +02:00
jaseg
3d09f5199e Windows: Improve DLL loading error messages 2024-08-14 10:55:51 +02:00
jaseg
ef3f47c3ec Fix quit and quit_watch_later commands 2024-08-14 10:48:37 +02:00
jaseg
f4086d4bb4 Add API to set dict-valued properties 2024-07-15 14:52:59 +02:00
jaseg
e1ae4f7da6 Version 1.0.7 2024-06-21 16:23:54 +02:00
jaseg
f1621b629d Fix race condition in property observer code leading to futures.InvalidStateError
Previously, prepare_and_wait_for_property was slightly confused on the
lifetime of that future.

This closes #282
2024-06-21 16:14:37 +02:00
jaseg
16093073b0 Version 1.0.6 2024-04-20 12:51:15 +02:00
jaseg
d96eaf7e64 Fix loadfile for mpv v0.38.0
mpv v0.38.0 added an argument to the loadfile command. Unfortunately the
parsing logic isn't very smart, and now mis-interprets the old argument
format, and breaks literally everything written against older versions
that used the `options` kv dict.

This commit adds a kludge that uses the right variant depending on the
mpv version.
2024-04-20 12:48:58 +02:00
jaseg
b6ab5a4ab0 play_bytes: Add docstring. 2024-01-22 11:55:03 +01:00
jaseg
4e76f01ecc mpv.py: Add play_bytes convenience function 2024-01-22 11:53:02 +01:00
jaseg
141ec7d372 mpv.py: Add play_context convenience function 2024-01-22 11:53:02 +01:00
jaseg
c52a07e862 Version 1.0.5 2023-11-18 11:57:40 +01:00
jaseg
93cf60e109 Add libmpv-2.dll to windows library search list 2023-11-18 11:45:07 +01:00
jaseg
03947f272b Add missing fields to MpvEventEndFile 2023-07-22 14:37:52 +02:00
Carsen Yates
2d787a977d Add field "playlist_entry_id" to MpvEventEndFile 2023-07-22 14:32:53 +02:00
sdaqo
f6d1269531 Add 'self' to mouse function 2023-06-03 18:31:40 +02:00
jaseg
5a1a2734f2 Add __version__ field to module
Closes #248.
2023-03-30 13:57:01 +02:00
jaseg
7343604f10 Add tests and fix error handling for stream callbacks 2023-02-26 20:15:27 +01:00
jaseg
f9a655e7ca Add cross-thread exception handling for event loop and stream callbacks 2023-02-26 19:47:20 +01:00
jaseg
6625a3900d Update license header with dual-license information
Closes #206
2023-02-26 13:07:54 +01:00
jaseg
2330fcd416 Fix typo in repr format string
fixes #231
2022-08-16 16:44:27 +02:00
Elias Müller
91422de05a Fix show_text level default parameter 2022-07-11 12:37:36 +02:00
Naglis Jonaitis
20ec2a74b8 Fix observe_property() docstring
1. Fix decorator name - the decorator for property observation handlers is `@property_observer()`.
2. Fix handler's unregistration method name
3. Fix handler function signature - the signature is ``fun(property_name, new_value)`` and we can't have a bare `*` with no names after it.
4. Fix undefined variable in the example
2022-06-17 00:13:21 +02:00
James Gerity
4a8554319f Error for known-incompatible libmpv (closes #223) 2022-06-17 00:10:01 +02:00
jaseg
bd46633641 Add cancel handling to streams 2022-04-24 13:43:44 +02:00
jaseg
5f4cf600b5 Add event queue overflow handling 2022-04-24 13:43:44 +02:00
jaseg
3cb1196621 Finish event infrastructure rework. 2022-04-22 23:24:10 +02:00
jaseg
85ad2a6aa6 Finish rewriting event infrastructure 2022-04-22 23:18:48 +02:00
jaseg
c90a5f692f Continue reworking event infrastrucutre.
Note: We do not decode property values by default anymore.
2022-04-22 23:01:13 +02:00
jaseg
2d87c897e2 Update event wrapper classes 2022-04-22 21:53:10 +02:00
jaseg
341f4c5c16 Remove deprecated libmpv API 2022-04-22 21:53:08 +02:00
jaseg
116c756fa4 add albumart arg to video_add 2022-04-22 21:52:51 +02:00
DepFA
0f48db6398
Remove MpvSubApi wrapper 2022-04-20 13:57:56 +01:00
DepFA
87559cde89
Remove dropped mpv-2 api methods. 2022-04-20 13:55:22 +01:00
jaseg
9fbe39d3b4 Add some useful input commands 2022-04-18 00:31:33 +02:00
jaseg
be1e78158a Add keyword argument command interface 2022-04-18 00:26:47 +02:00
jaseg
6cc0b23114 Update copyright headers 2022-04-18 00:00:19 +02:00
jaseg
607bd3ff12 Add missing new event types 2022-04-17 23:52:29 +02:00
jaseg
8d448d49f1 Add future-based async command API 2022-04-17 23:52:12 +02:00
Elias Müller
d28f135382 mpv.py: add default error handler for failed async commands 2022-04-17 22:51:06 +02:00
Elias Müller
107c563f8d mpv.py: add support for asynchronous commands 2022-04-17 22:51:06 +02:00
jaseg
e8c8736a1a Default to node_command and rename old command to string_command 2022-04-17 22:49:20 +02:00
Kira
2b3249a73d mpv.py: change mpv_detach_destroy to mpv_destroy 2022-04-17 22:42:40 +02:00
jaseg
c12e1ed8a1 porcelain: Add fancy wait_for_event/property future handling 2022-04-17 22:37:10 +02:00
jaseg
0cda09c628 Add timeouts and error forwarding to wait_for_{property,event} conditions 2022-03-26 14:23:04 +01:00
jaseg
518421a127 use daemon = True instead of setDaemon 2022-03-26 14:23:04 +01:00
Marcel Moreaux
b5f03dd2b7 Fix handling of c_void_p args in MpvRenderParam.__init__()
Handling of c_void_p args (x11_display, wl_display) was broken.
Added a case to correctly handle the c_void_p constructor case.
See https://github.com/jaseg/python-mpv/issues/169
2021-07-28 12:37:55 +02:00
hixz00
3105db35a4 mpv.py: update: Use ctypes.memmove to speed up 2021-01-19 18:59:59 +01:00
Dziqs
035e1db1db Fixing typo in keep_playlist causing NameError 2020-07-25 23:42:26 +02:00
jaseg
1f2b0058b3 mpv.py: terminate: Raise warning when called from event thread. 2020-07-19 22:34:24 +02:00