Bug 303227 - Movie in pdf is not played if movie file path contains ./
Summary: Movie in pdf is not played if movie file path contains ./
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: PDF backend (show other bugs)
Version: 0.14.95
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-09 09:13 UTC by Oliver Sander
Modified: 2012-07-11 15:36 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
pdf containing the movie that won't play (121.62 KB, application/x-pdf)
2012-07-09 09:14 UTC, Oliver Sander
Details
Corresponding tex sources (266 bytes, text/x-tex)
2012-07-09 09:14 UTC, Oliver Sander
Details
Example movie file (121.88 KB, video/x-msvideo)
2012-07-09 09:15 UTC, Oliver Sander
Details
Patch to use KTemporaryFile (912 bytes, text/plain)
2012-07-11 14:39 UTC, Fabio D'Urso
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Sander 2012-07-09 09:13:10 UTC
I have a pdf file created with LaTeX + beamer.  It contains a movie file embedded using the movie15 package.  When I click on the rectangle where the movie should appear, the black viewer window appears, but the movie is not playing.

The reasons seems to be the file path of the movie file:

\includemovie[]{9.1cm}{5.5cm}{./smootherMG_low.avi}

Note the ./ in front of the file name.  If I omit the ./ then the movie plays just like it should.



Reproducible: Always
Comment 1 Oliver Sander 2012-07-09 09:14:18 UTC
Created attachment 72395 [details]
pdf containing the movie that won't play
Comment 2 Oliver Sander 2012-07-09 09:14:41 UTC
Created attachment 72396 [details]
Corresponding tex sources
Comment 3 Oliver Sander 2012-07-09 09:15:13 UTC
Created attachment 72397 [details]
Example movie file
Comment 4 Tobias Koenig 2012-07-11 10:26:08 UTC
Git commit 06b0cf86169a92802ff4e4df0e9d22bc67b387fb by Tobias Koenig.
Committed on 11/07/2012 at 12:24.
Pushed by tokoe into branch 'master'.

Always create temporary movie files with a sane name

M  +2    -1    core/movie.cpp

http://commits.kde.org/okular/06b0cf86169a92802ff4e4df0e9d22bc67b387fb
Comment 5 Oliver Sander 2012-07-11 13:05:50 UTC
Thanks, the movie plays now.  However, looking at the patch suggests a few ways to create other non-playing situations.  For example, having the filename start with ././ makes the movie not play again (admittedly, this is a bit contrived).  But less contrived: when I specify the movie file by absolute path okular won't play it either.
Comment 6 Fabio D'Urso 2012-07-11 14:39:04 UTC
Created attachment 72456 [details]
Patch to use KTemporaryFile

What about a plain KTemporaryFile?
Note that, with the attached diff, the extension is not preserved any more. However, it seems to work even without it.
Comment 7 Oliver Sander 2012-07-11 15:36:18 UTC
For the record: Tobias fixed this properly in commit 4c8f0bc5def7c755ab810adec78826fd51f713b1
Thanks!