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 736184 - Error on loading video
Error on loading video
Status: RESOLVED NOTGNOME
Product: gaupol
Classification: Other
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gaupol-maint@gnome.bugs
gaupol-maint@gnome.bugs
Depends on:
Blocks:
 
 
Reported: 2014-09-06 11:47 UTC by ashalimov
Modified: 2014-09-14 04:56 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Gaupol strout & stderr (2.70 KB, text/plain)
2014-09-10 14:19 UTC, ashalimov
Details

Description ashalimov 2014-09-06 11:47:50 UTC
First loaded subtitles, then tried to load video (mkv). Got error:

Traceback

File: /usr/share/gaupol/gaupol/player.py
Line: 204
In: _on_bus_sync_message

    message.src.set_window_handle(self._xid)

AttributeError: '__main__.GstPlaySink' object has no attribute 'set_window_handle'

Environment

Platform: Linux-3.11.0-26-generic-x86_64-with-Ubuntu-13.10-saucy
Locale: en_US.utf_8

Libraries

Python: 3.3.2
GTK+: 3.8.6
PyGObject: 3.10.0
GStreamer: 1.2.0.0

Python Packages

aeidon: 0.24
gaupol: 0.24
enchant: 1.6.5
gtkspellcheck: 3.0
chardet: 2.0.1
Comment 1 Osmo Salomaa 2014-09-06 17:22:13 UTC
On my Debian unstable with GStreamer 1.4.1 it seems the video doesn't load at all and Gaupol just freezes. If I remove the subtitle and timecode overlays, it works fine. There's probably been some backwards-incompatible changes in GStreamer 1.2 and/or 1.4. I'll look into it.
Comment 2 Osmo Salomaa 2014-09-07 18:15:05 UTC
It seems what I'm experiencing is bug #735800, which is due to textoverlay changes in GStreamer 1.4. That should be fixed in the next release of GStreamer.

What you're experiencing is something different and all I can say now is that I cannot reproduce it. I'll try again when GStreamer 1.4.2 comes out, but I don't expect it to affect this, since everything works fine for me if I drop the timecode overlay to work around that bug #735800.
Comment 3 ashalimov 2014-09-08 17:05:35 UTC
If you could tell me how to remove subtitle and timecode overlays, I'll try to check if it will allow to work around this bug. I have mkvtools installed and can install other programs if needed.
Comment 4 Osmo Salomaa 2014-09-08 17:26:53 UTC
(In reply to comment #3)
> If you could tell me how to remove subtitle and timecode overlays, I'll try to
> check if it will allow to work around this bug. I have mkvtools installed and
> can install other programs if needed.

Those overlays are part of the GStreamer pipeline defined in Gaupol's code.

If you're using GStreamer 1.2, those overlays shouldn't be a problem for you. You can easily test with the following command (you need package gstreamer1.0-tools installed). If it shows you video, text and timecode, all is well.

gst-launch-1.0 videotestsrc ! textoverlay text=Foo ! timeoverlay ! autovideosink
Comment 5 Osmo Salomaa 2014-09-08 20:56:39 UTC
Something sensible that you can test is setting the environment variable GST_DEBUG and seeing if there's any output, i.e. at a terminal window run commands

    export GST_DEBUG="*:2"
    gaupol

and try to load a video file. Copy any output here, particularly warnings and errors.
Comment 6 ashalimov 2014-09-10 14:19:04 UTC
The first command resulted in a window with test pattern, time and text "Foo". I've launched gaupol with GST_DEBUG, and output (both stdout & stderr) are in attached file gaupol.out. However, I've found an interesting thing. If I press "Quit" or "Close" button in error dialog, gaupol just exits. But if I close this window via titlebar button, a standalone player window (detached from gaupol) appears, and video starts playing. Also, the sound is playing via wrong output. Could it be a problem with gaupol using oss or alsa, and I'm using pulseaudio? If needed, I can attach output in this case as well.
Comment 7 ashalimov 2014-09-10 14:19:53 UTC
Created attachment 285826 [details]
Gaupol strout & stderr
Comment 8 Osmo Salomaa 2014-09-10 19:17:56 UTC
(In reply to comment #6)
> The first command resulted in a window with test pattern, time and text "Foo".

Then that worked fine.

> I've launched gaupol with GST_DEBUG, and output (both stdout & stderr) are in
> attached file gaupol.out.

> ERROR:root:Could not find any typelib for GstPbutils

Pbutils is not strictly required (it's just used to check the video framerate), but this could mean your GStreamer installation has something missing or broken. Do you have packages "gir1.2-gst-plugins-base-1.0" and "gstreamer1.0-plugins-base" installed?

> error: Could not open audio device for playback.

I don't really know, but as you suggest, there could be something wrong with initializing the audio output, such that it prevents playback entirely. Gaupol should use whatever GStreamer considers to be the default audio output device.

To check if there's some general problem with your GStreamer installation, try gst-launch from the command line to try to play the offending file:

    export GST_DEBUG="*:2"
    gst-launch-1.0 playbin uri="file:///home/USERNAME/.../VIDEO.mkv"

It should play the video in a separate window. Gaupol uses the playbin element as well, so it should be similar conditions. If it doesn't work, there's something wrong with your GStreamer, in which case you could also try some GStreamer-based video player, e.g. Totem.
Comment 9 ashalimov 2014-09-11 14:18:39 UTC
> Do you have packages "gir1.2-gst-plugins-base-1.0" and
"gstreamer1.0-plugins-base" installed?
gstreamer1.0-plugins-base was installed, but gir1.2-gst-plugins-base-1.0 wasn't. After manually installing it there's no more error messages, and player window is integrated into gaupol windows, but audio is still using wrong output.

> gst-launch-1.0 playbin uri="file:///home/USERNAME/.../VIDEO.mkv"
This plays video in a separate window, but also using wrong audio output. I've tried everything I could find on the net (installing gstreamer0.10-good-plugins, installing gstreamer-properties and configuring gstreamer audio properties) — nothing helps. I've tried to play this video through Totem, but it also uses wrong audio output (without any means to configure). Well, I guess I'm out of luck.
Comment 10 Osmo Salomaa 2014-09-11 19:02:11 UTC
(In reply to comment #9)
> gstreamer1.0-plugins-base was installed, but gir1.2-gst-plugins-base-1.0
> wasn't. After manually installing it there's no more error messages, and player
> window is integrated into gaupol windows

I filed a bug report against the gaupol package in Debian to fix those GStreamer dependencies. I assume any such fixes will propagate to Ubuntu as well.

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=761218

> > gst-launch-1.0 playbin uri="file:///home/USERNAME/.../VIDEO.mkv"
> This plays video in a separate window, but also using wrong audio output.

Regarding audio I can only suggest you turn to Ubuntu's mailing lists, wiki, forums, or whatever suitable. My understanding is that most modern distros use PulseAudio and distros should have it configured so that it just works. The lack of audio output device configuration in Gaupol, Totem, etc. is intentional -- it shouldn't be needed anymore these days.
Comment 11 ashalimov 2014-09-14 04:56:12 UTC
Understood. Thanks for help!