-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for animate package #327
Comments
This was previously (briefly?) discussed in #314 I believe.
As far as I can tell, this would require embedding a javascript engine in pympress, so not a tiny task. Also opens up a whole can of worms in terms of security, etc.
Definitely not, you can embed media files in a PDF. Use the autoplay example from the README, as you can see the
There’s a number of options, see e.g. this tex.se question. I understand this makes the pipeline a little more complex, but that could be automated by a Makefile or similar tool that handles dependencies.
|
Note that I’m not saying this can’t or shouldn’t be done, it would also support other javascript use cases such as some implementations of autoplay. But seen as a) there are viable workarounds for all use cases so far, b) it would be a huge investment in development time, and c) other large changes like porting to Gtk 4 (#267) that are also waiting, it’s quite unlikely this happens any time soon. One starting point to explore feasability would be to find options for a javascript engine/interpreter/library that pympress could use. Something either smallish or existing in the Gtk world would be easiest to integrate – but hard to search for as search engines are flooded with the opposite association: using javascript to program a Gtk application. I think the most tedious part comes next, and would be setting up the PDF-compliant API: providing objects that code in PDFs expect, and the like. Again if there’s something open-source we can reuse that’s probably best and lowest overhead. Something standalone, or in the poppler space (what does Okular use?) could again be best. |
There's just a slight issue with the autoplay exemple in the README: the VLC option doesn't seem to support autoplay on page display and the |
Thanks, that I didn't know
I know that Mozillas pdf.js can (natively) show animations built with animate but I obviously don't know how big of a change that would be for pympress. Anyway, thank you for this undoubtfully awesome application I can totally understand that your priorities lie somewhere else and you don't want to cater to a single potential user :) |
@christophehenry Whether our VLC media backend honors autoplay or not (it should) is a different topic, and you may want to open a different issue if it appears not to work. I'd be surprised as that logic isn't backend-specific however. But first, and more relevant to this issue, you want your PDF to reliably contain the instruction to autoplay. Flash is deprecated now so media9 is dead. However the older movie15 is still perfectly functional, as it simply relies on static PDF annotations. Which is probably why no newer package has been created for this functionality. There's also this tex.se question discussing post-media9 solutions, with 2 standalone 20ish-line implementations of a media embed command, also using annotations. As to your dependency issue, I'm not sure what the details are, but movie15 installs fine on my distro. You may want to contact packagers of your OS, or start maintaining the OS package for that missing tex package - or even propose a newer package to CTAN based on the resources listed above. |
Hmm… You're right, I do have
Trying to define As for the VLC media backend, do you have an idea how to make it work? |
Is your feature request related to a problem? Please describe.
I have a lot of beamer slides using the animate package (
animategraphics
,animateinline
) which are not playing in pympress.Describe the solution you'd like
Animations build with the animate package should play out as intended.
Describe alternatives you've considered
Converting them to gifs/videos is not feasible due to the sheer amount of animations as well as the fact that they are built using TikZ and I'd like to (have to) keep the flexibility.
Edit: other alternatives are unfavorable as well. beamers
movie
command as well as the movie15 package need the file to be present next to the pdf and the media9 package requires Flash (huge red flag). Only the animate package can create hermetic and standalone pdfs.Additional context
None
The text was updated successfully, but these errors were encountered: