pympress
pympress copied to clipboard
Bundle gstreamer in Windows installers to support media out of the box without VLC
[This comes from https://github.com/Cimbali/pympress/issues/212#issuecomment-961458672.]
The attached PDF document contains a video on the second page that should autostart as the page is entered (and autostop as the page is left).
@Cimbali, reports that video autostart should work fine with latest version (1.7b1). I cannot make it work with these Windows binaries.
The video doesn’t play at all, not even by clicking on it. I guess this might be related to GStreamer and its Python bindings.
Do you have VLC on your system, and if so can you try with enabled=on
under [vlc]
in %APPDATA%\pympress.ini
?
If that works the issue is probably limited to packaging the GStreamer dependencies.
I don’t have it on the Windows system I use, but I can fake it with a portable installation.
IMHO, packaging the GStreamer dependencies would be great to have a complete solution (and portable too).
The goal is to indeed package the gstreamer dependencies, I’m just trying to confirm that’s the only thing going wrong. If you don’t have VLC don’t worry though I’ll test it at some point.
Many thanks for commit d989d639927a5cd6a7da1f2b9248f96b370d331f.
I’m afraid I don’t get the video playing (not even clicking on it).
I’m going to check it with the new beta (once it’s available).
The gstreamer backend works with on windows msys for non-frozen packages, but doesn’t seem to survive to the “freezing” (i.e. building the .exe) process. All I get are the following errors:
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: cannot register existing type 'GWin32RegistryKey'
Gst.init(gst_opts)
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: cannot add private field to invalid (non-instantiatable) type '<invalid>'
Gst.init(gst_opts)
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: cannot register existing type 'GInitable'
Gst.init(gst_opts)
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: g_type_interface_add_prerequisite: assertion 'G_TYPE_IS_INTERFACE (interface_type)' failed
Gst.init(gst_opts)
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: g_once_init_leave: assertion 'result != 0' failed
Gst.init(gst_opts)
C:/msys64\home\me\pympress/pympress/media_overlays/gst_backend.py:181: Warning: g_type_add_interface_static: assertion 'G_TYPE_IS_INSTANTIATABLE (instance_type)' failed
Gst.init(gst_opts)
For now, media backends on windows will have to be limited to VLC.
I’m repurposing this issue for the gstreamer bundling.
I’ve tested both playing and auto-playing of media, which both work with v1.7.0b3 on Windows provided VLC is installed.