Latest Tweets

Swfdecoder 0.60 is not capable of showing video but audio output.

The matter

Swfdecoder can be installed on any 64bit GNU/Linux distros to replace the awful mixture – due to memory lack issues and stability – of NspluginWrapper and “the official” Macromedia Flash Player which is, obviously, not open source. However, in some cases it is possible to find out that there’s no video  but audio output, or maybe just the other way around, when it comes to playing videos directly through it.

This issue can be applied to swfdec-mozilla, too, the plug-in based on swfdecoder API, so as to play Flash contents inside our Firefox browser.

How they all work

First of all, Swfdecoder uses GStreamer API to play audio and video contents. We can use “the player” directly from the command-prompt, or we can use our Firefox browser to watch Flash contents. In order to do so, we are in need of installing swfdec-mozilla , too.

Debugging swfdec-mozilla

After downloading and compiling the sources successfully, I started to play some Flash content in the browser. That’s what came out:

4 ** Message: PackageKit: Codec nice name: MPEG-4 AAC decoder
5 ** Message: PackageKit: structure: gstreamer0.10(decoder-audio/mpeg)(mpegversion=4)()(64bit)
6 ** Message: PackageKit: Codec nice name: H.264 decoder
7 ** Message: PackageKit: structure: gstreamer0.10(decoder-video/x-h264)()(64bit)
8 ** Message: PackageKit: Did not install codec: The name org.freedesktop.PackageKit was not provided by any .service fil    es
9 SWFDEC: ERROR: swfdec_codec_gst.c(211): swfdec_gst_decoder_init: failed to create decoder
10 SWFDEC: ERROR: swfdec_video_decoder.c(407): swfdec_video_decoder_errorv: error decoding video: no suitable decoder for     video codec 7

(…)
15 Loading stream: http://www.google.com/reviews/y/crossdomain.xml
16 Loading stream: http://www.google.com/crossdomain.xml

Take a look at lines 9,10. It seems quite obvious where the real problem dwells: that is, just in what video codec can be used in order to play the stream. In other words, as long as this concrete video codec is installed on the system, the video will be shown on the screen. If not, there will be no video output at all.

We do know the layer in charge of playing audio or video codecs: GStreamer, as briefly introduced previously. So, all I needed to do so as to fix this issue was  to install – using the yum command -, the next GStreamer package:

gstreamer-ffmpeg.x86_64

And that was all.

It seems quite clear to me that any issue concerning no audio or no video output with swfdecoder could be solved trying to determine whether a GStreamer plug-in is really installed or not, and, then, installing it using the package manager available on each GNU/Linux distro – say, apt-get, yum, or yast -.

References and external links

Swfdecoder

Swf-mozilla