Feature request: Support for embedded media
It would be nice to have the possibility to play media or follow links embedded in the document. A small example can be found on https://www.dropbox.com/s/isefuecod62m1mo/xmpl_pres.tar.gz?dl=0 The example contains a tiny .tex file (beamer presentation) using the movie15 package to include a video file. As mouse clicks trigger slide-changes in DS PDF Viewer, the video can not be played in the presentation. It would be therefore nice to have a key combination to access media.
While I fear I'll not be able to implement this myself, I think it'd be a really nice feature. Who knows, maybe one day dspdfviewer might be feature-complete in rendering what latex-beamer can generate : )
First question is: How do other pdf-viewers handle this situation? Right now I can imagine four different ways to render videos
- Include a full media player (with demux, codecs, video and audio drivers and everything) to ensure same output on all platforms, to render it inside the window and have full control over the rendering
- Use a multi-platform library to render inside the window and hope this library has all the codecs
- Use different platform-specific libraries, increasing code size and making porting more difficult
- Call an external program as a new window, having almost no control over the rendering process
I will try to render your provided example with some programs and see what they do. Can you name programs with which you have used in-pdf-videos before?
PS: I don't know how long dropbox will keep the file available - is it allright with you if I mirror it on github/gist?
Of course, you´re free to mirror it.. it is just some tiny example I created with a stupid countdown video because I couldn´t find anything better... :D I have tried it with evince (standard pdf viewer in linux mint and some other distributions) and Sumatra PDF for Windows. Both treat the integrated video file as a link and open external programs to play it (which is still kind of okay-ish..) There are also different latex packages for video integration, but I have only tried movie15. Maybe other packages offer better options (with movie15 you can visualize controls and autostart/stop the video at a specific time stamp, alledgedly, but my viewers weren´t able to show any of that.. ) I can try some other pdf viewers as well and let you know if I find one that can handle media content properly.
Cheers, Mareike
On 02/02/2015 11:56 AM, Danny Edel wrote:
While I fear I'll not be able to implement this myself, I think it'd be a really nice feature. Who knows, maybe one day dspdfviewer might be feature-complete in rendering what latex-beamer can generate : )
First question is: How do other pdf-viewers handle this situation? Right now I can imagine four different ways to render videos
- Include a full media player (with demux, codecs, video and audio drivers and everything) to ensure same output on all platforms, to render it inside the window and have full control over the rendering
- Use a multi-platform library to render inside the window and hope this library has all the codecs
- Use different platform-specific libraries, increasing code size and making porting more difficult
- Call an external program as a new window, having almost no control over the rendering process
I will try to render your provided example with some programs and see what they do. Can you name programs with which you have used in-pdf-videos before?
PS: I don't know how long dropbox will keep the file available - is it allright with you if I mirror it on github/gist?
Reply to this email directly or view it on GitHub: https://github.com/dannyedel/dspdfviewer/issues/22#issuecomment-72438615
Additional Info: have just tried to open the pdf with Okular, and it shows the video as well as controls (as specified in the includemovie options) embedded in the pdf. Using the controls works well, clicking on the video/the placeholder image will open an external viewer, however.
Cheers, Mareike
On 02/02/2015 11:56 AM, Danny Edel wrote:
While I fear I'll not be able to implement this myself, I think it'd be a really nice feature. Who knows, maybe one day dspdfviewer might be feature-complete in rendering what latex-beamer can generate : )
First question is: How do other pdf-viewers handle this situation? Right now I can imagine four different ways to render videos
- Include a full media player (with demux, codecs, video and audio drivers and everything) to ensure same output on all platforms, to render it inside the window and have full control over the rendering
- Use a multi-platform library to render inside the window and hope this library has all the codecs
- Use different platform-specific libraries, increasing code size and making porting more difficult
- Call an external program as a new window, having almost no control over the rendering process
I will try to render your provided example with some programs and see what they do. Can you name programs with which you have used in-pdf-videos before?
PS: I don't know how long dropbox will keep the file available - is it allright with you if I mirror it on github/gist?
Reply to this email directly or view it on GitHub: https://github.com/dannyedel/dspdfviewer/issues/22#issuecomment-72438615
The gist mirror is on https://gist.github.com/dannyedel/a79afab438c9655b9f99 (I had to strip the vid/ directory for gist to accept it, but at least its mirrored for safekeeping)
I will try to figure out if there is a standard-way to do "Launch default program to view annot.avi" since I guess that should be reasonably easy to implement as a first step, but if the control things are specified then I suppose it's worth implementing them sooner or later.
I have installed okular now and It pulled phonon as a dependency, which is a rather large multimedia library. On my system, launching Okular immediatly starts the video playback embedded, and clicking the video starts vlc as an external program. (This seems a bit confusing to me)
I suppose its worth reading into phonon, since it is a Qt/KDE library and thus I should™ somehow be able to integrate it into the program. (Probably behind a compile-time switch, since the phonon dependency tree pulls a few hundred megabytes on a non-kde system)
One caveat which I have encountered is that the vlc player aswell as the integrated phonon seem to be pointed towards the external file (the path vid/annot.avi was apparently coded in the pdf, instead of a copy). I will have to read up whether they can also be embedded, because at the moment the whole PDF file is cached in memory. If we use PDFs with large multimedia objects embedded, they will quickly grow so I'll have to re-work that part aswell.
Still, if anyone with more multimedia programming experience is reading this, speak up : )
Hi, I think you should look at pdfpc implementation of embeded video. It's uses links to video files in file system, so pdf size is small. Also it's include embeded video player based on gstreamer. Only a git version of pdfpc can play video. I can give some working latex examples if you need them. Project page: https://github.com/davvil/pdfpc
Hi, is there any progress on this one?