After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 421883 - Video previewing doesn't function correctly
Video previewing doesn't function correctly
Status: RESOLVED FIXED
Product: gnome-subtitles
Classification: Other
Component: general
0.2.1
Other All
: Normal normal
: ---
Assigned To: Maintainers of GNOME subtitles
Maintainers of GNOME subtitles
Depends on:
Blocks:
 
 
Reported: 2007-03-23 13:22 UTC by Malte Skoruppa
Modified: 2007-03-25 02:06 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Malte Skoruppa 2007-03-23 13:22:13 UTC
Please describe the problem:
Hi,

it seems that video previewing isn't working for me. I can create a new subtitle file and open a video file, and even play the video without any problem, but when I play the video, the time at the left of the preview image which indicates the point in time, as well as the indicated length of the whole movie, are completely wrong. For example, I get a length of 12:47:12.000 for a video that has actually only 22 minutes 4 seconds.

Furthermore, the indicated time is also completely wrong. After one second, the indicated time is at 00:00:10.000, so it looks like it's 10 times faster than it should. Hence after 6 seconds, it's at 00:01:00.000, which doesn't make any sense. Of course, when subtitling using this preview (and the buttons to set the subtitle start and end), subtitles get completely unsynchronized. I can't use it like this :-(

What is more, I cannot rewind the movie using the rewind button below the preview image. Both buttons show no reaction whatsoever when the movie is playing. When I pause the movie, the fast-forward as well as the rewind button, when clicked upon, BOTH fast-forward the movie 1 second. I can only rewind it using the mplayer shortcuts (cursor keys) when the mouse is above the preview window, i.e. by hitting the "cursor left" key. However when I do that, sometimes the subtitles already written are not displayed any more, I have to click on pause two times to get them back.

All in all, I can't use the video previewing function like this. Here is a screenshot to show you:

http://hetzner.scummunity.de/~malte/screenshots/gnome-subtitles.png
(note: the screenshot doesn't show the window frames, which has probably to do with my window manager. Never mind...)

At the left you see a normal mplayer window playing the movie. I stopped it after 13 seconds. At the right you see gnome-subtitles, also paused after 13 seconds. You should see that it indicates 00:02:10.000

I have begun to write french subtitles for the movie using these weird times (I almost did 3 minutes before I noticed it was quite weird). Of course, when playing the video with mplayer and using the generated .srt file with the -sub option, the subtitles are completely and beyond despair out-of-sync. Impressingly enough, when I load the .srt file with gnome-subtitles and open the movie, the subtitles are synchronised, probably because gnome-subtitles really uses this timing internally somehow.


Steps to reproduce:
1. Start gnome-subtitles
2. Open/Create new subtitle file
3. Open the video
4. Play the video



Actual results:
I think I thoroughly described this above :-)

Expected results:
I would expect it to work as it should, i.e. with correct timings, with rewind and fast-forward buttons working and so forth.

Does this happen every time?
Yes.

Other information:
You might be interested in a few circumstances.

Using AMD 64 and Gentoo:
malte@ririu ~ $ uname -a
Linux ririu 2.6.18-gentoo-r6 #9 Fri Feb 23 12:15:50 CET 2007 x86_64 AMD Athlon(tm) 64 Processor 3000+ AuthenticAMD GNU/Linux

Both 32 bit and 64 bit versions of mplayer are installed:
malte@ririu ~ $ file /usr/bin/mplayer*
/usr/bin/mplayer:     ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), stripped
/usr/bin/mplayer-bin: Bourne-Again shell script text executable

I tried replacing mplayer with mplayer-bin, because I thought with a 32 bit version of mplayer it might work. But it doesn't make any difference.

Using Gnome-Subtitles 0.2.1 with SubLib 0.5

The video is:
malte@ririu ~/Desktop/Season 1 $ file How.I.Met.Your.Mother.S01E01.Pilot.avi 
How.I.Met.Your.Mother.S01E01.Pilot.avi: RIFF (little-endian) data, AVI, 624 x 352, 23.98 fps, video: XviD, audio: MPEG-1 Layer 3 (stereo, 48000 Hz)

I set the video frame rate correctly in the menu.
Comment 1 Pedro Castro 2007-03-23 18:21:52 UTC
Hi,

Can you try the latest SVN trunk version? I can give you detailed instructions if you need them. This most probably corresponds to a bug that has already been reported and fixed.
Comment 2 Malte Skoruppa 2007-03-24 13:47:52 UTC
Hi,

I'm afraid I'm having problems compiling the SVN version. After checking out the SVN trunk, setting the GTKSHARP_CFLAGS and GTKSHARP_LIBS manually (the configure script of the SVN trunk wouldn't detect them; I just set them using 'export' and using the values of the Makefile of the 0.2.1 version, where the configure script detected them properly), as well as copying over the build/ directory with the .exe and .dll files from the 0.2.1 version to the SVN trunk directory, and executing ./autogen.sh (which finally ran through without errors), then when I typed make, I got:

ririu gnome-subtitles # make
Making all in .
make[1]: Entering directory `/root/gnome-subtitles'
make[1]: Für das Ziel »all-am« ist nichts zu tun.
make[1]: Leaving directory `/root/gnome-subtitles'
Making all in src
make[1]: Entering directory `/root/gnome-subtitles/src'
/usr/bin/gmcs  -target:winexe -out:./../build/gnome-subtitles.exe -r:./../build/sublib.dll -r:Mono.Posix.dll -r:/usr/lib64/mono/gtk-sharp-2.0/pango-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/atk-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/gdk-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/gtk-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/glib-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/glade-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/gnome-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/art-sharp.dll -r:/usr/lib64/mono/gtk-sharp-2.0/gnome-vfs-sharp.dll -resource:./Glade/AboutDialog.glade -resource:./Glade/EncodingsDialog.glade -resource:./Glade/FileOpenDialog.glade -resource:./Glade/FileOpenErrorDialog.glade -resource:./Glade/FileSaveAsDialog.glade -resource:./Glade/HeadersDialog.glade -resource:./Glade/MainWindow.glade -resource:./Glade/PreferencesDialog.glade -resource:./Glade/ReportBugWindow.glade -resource:./Glade/SearchDialog.glade -resource:./Glade/TimingsAdjustDialog.glade -resource:./Glade/TimingsShiftDialog.glade -resource:./Glade/VideoOpenDialog.glade -resource:./../data/gnome-subtitles.png -resource:./../data/gnome-subtitles-logo.png -resource:./../data/video-set-subtitle-end-16x.png -resource:./../data/video-set-subtitle-start-16x.png ./External/Freedesktop.RecentFiles/*.cs ./GnomeSubtitles/Commands/*.cs ./GnomeSubtitles/Core/*.cs ./GnomeSubtitles/Dialogs/*.cs ./GnomeSubtitles/Exception/*.cs ./GnomeSubtitles/Execution/*.cs
./GnomeSubtitles/Core/Config.cs(20,7): error CS0246: The type or namespace name `GConf' could not be found. Are you missing a using directive or an assembly reference?
./GnomeSubtitles/Core/Config.cs(20,1): error CS0246: The type or namespace name `GConf' could not be found. Are you missing a using directive or an assembly reference?
./GnomeSubtitles/Core/Config.cs(20,7): error CS0246: The type or namespace name `GConf' could not be found. Are you missing a using directive or an assembly reference?
./GnomeSubtitles/Core/Config.cs(20,1): error CS0246: The type or namespace name `GConf' could not be found. Are you missing a using directive or an assembly reference?
Compilation failed: 4 error(s), 0 warnings
make[1]: *** [../build/gnome-subtitles.exe] Fehler 1
make[1]: Leaving directory `/root/gnome-subtitles/src'
make: *** [all-recursive] Fehler 1

I guess I'm doing something wrong... what should I do?

Thanks,
Malte
Comment 3 Pedro Castro 2007-03-24 14:18:45 UTC
Malte,

This shouldn't happen. What versions are you using for automake and autoconf?
Comment 4 Malte Skoruppa 2007-03-24 17:26:23 UTC
ririu gnome-subtitles # autoconf --version
autoconf (GNU Autoconf) 2.61
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software.  You may redistribute copies of it under the terms of
the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
There is NO WARRANTY, to the extent permitted by law.

Written by David J. MacKenzie and Akim Demaille.
ririu gnome-subtitles # automake --version
automake (GNU automake) 1.10
Written by Tom Tromey <tromey@redhat.com>
       and Alexandre Duret-Lutz <adl@gnu.org>.

Copyright 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I doubt this is because of automake or autoconf. gnome-subtitles 0.2.1 compiled fine, too. That 'GConf' namespace is posing problems and it wasn't there in the old version:

ririu gnome-subtitles # grep "using GConf" /root/gnome-subtitles-0.2.1/src/GnomeSubtitles/Core/*
ririu gnome-subtitles # grep "using GConf" /root/gnome-subtitles/src/GnomeSubtitles/Core/*
/root/gnome-subtitles/src/GnomeSubtitles/Core/Config.cs:using GConf;

Actually the whole Config.cs file is new, it isn't even there in the 0.2.1 version, but whom do I tell this...

Now, I don't know anything about C#, but I can tell that if a namespace is to be used, it has to be imported from somewhere, and it doesn't seem to be present on my system. Maybe there's just some package I have to install on my system (but I have gconf installed). Or maybe it's there, but make doesn't find it. Maybe it is possible to change that in the Makefile?
Comment 5 Pedro Castro 2007-03-24 17:52:59 UTC
Malte,

The problem is right at tthe start, with GTKSHARP_LIBS not being correctly set. This is known to happen with automake < 1.7, which isn't the case.

The change from version 0.2.1 was minor, it just has a check for gconf-sharp now. I've tried uninstalling it and the configure script correctly reports it. Can you paste the log of running autogen.sh?
Comment 6 Malte Skoruppa 2007-03-24 18:21:22 UTC
Pedro,

thanks a lot. I found the error: gconf-sharp simply wasn't installed on my system!

The output of autogen.sh indicated this; it failed when "checking for GTKSHARP...". However, I had gtksharp installed, just not gconf-sharp, so I didn't suspect it was because of gconf-sharp (I didn't even know of this package before). Hence I set the GTKLIBS manually, which was wrong indeed. Rather, I had to install gconf-sharp, then run autogen.sh and so forth. Anyways, it works now :-)

As for the bug, yes, in the SVN version the indicated time now is correct. This is the most important part of my bug report.

However, the rewind button still doesn't work. I can still use neither of the buttons (rewind or fast-forward) while the movie is playing (that doesn't bother me at all, though), and when the movie is paused, I can fast-forward it using the fast-forward button, but when I click on the rewind button, it instead fast-forwards the movie too, hence both buttons are fast-forward buttons; this bothers me a little, because sometimes when writing subtitles, you just want to go back a little in order to catch the right moment when to start some subtitle. It's not that bad, as I can still use the left cursor button on the preview, which is the mplayer short key for rewinding a few seconds (I guess you know that), but it would be nice if it worked.

Anyways, this already helped me a lot. I can now use gnome-subtitles to write my subtitles :-) Thanks for this. GnomeSubtitles is the only good program I found to do this. Most other programs have no built-in video preview function, so I have no use for them as of now. They may be nice to edit or translate or convert subtitles, but to create them from scratch, you just need a preview function. I even searched for windows software, but there is none that's good either (I was using SubCreator in a VMWare Windows guest system, but really, using GnomeSubtitles is a lot more comfortable than that). So thanks for the great software, keep going! ;-)
Comment 7 Pedro Castro 2007-03-24 21:41:37 UTC
Marcin

Good thing we cleared that one. You did spot a new bug, though. I can verify that when using a different locale - french, for instance - forward and rewind don't work properly. I'll try to fix this soon.

And thank you for your words. It's always great to have feedback, and even more when it's interesting as yours.
Comment 8 Malte Skoruppa 2007-03-25 01:26:10 UTC
Indeed, you're right. It suffices to start gnome-subtitles with the locale set to e.g. en_US and the rewind button works all fine... thanks for the workaround! I can use this until you have that bug fixed, so it's really not that urgent, take your time...  thanks again! :-)

Malte

Comment 9 Pedro Castro 2007-03-25 01:46:42 UTC
OK, this is now fixed in the SVN. Can you try it?
Comment 10 Malte Skoruppa 2007-03-25 01:57:36 UTC
Man, that was fast! Great! I wish bugs always got fixed that fast when I report them ;-) Yes, it does work now. Looking forward to writing some subtitles here...

I can still think of a few feature requests, but I'll do it in other threads. And not today. For now I'm going to call it a night...
Comment 11 Pedro Castro 2007-03-25 02:06:40 UTC
Thanks for the feedback, and be free to suggest feature requests. Also, expect a new version of GS to be out soon.