JDK-8147888 : [Linux] JavaFX Media does not run on Ubuntu 14.10 or later
  • Type: Bug
  • Component: javafx
  • Sub-Component: media
  • Affected Version: 8u60,9
  • Priority: P2
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2016-01-20
  • Updated: 2016-09-20
  • Resolved: 2016-02-19
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 9
9Resolved
Related Reports
Blocks :  
Blocks :  
Relates :  
Description
JavaFX media does not work on Ubuntu 15.10 because it ships with a newer, incomaptible version of libavformat and libavcodec, and the older ones are not available on newer versions of Ubuntu. It appears that Ubuntu 14.10 and 15.04 have the same issue.

The Ensemble media samples, such as "Advanced Media" silently fail to play, and the HelloMedia example program prints the following error message and then exits:

$ java hello.HelloMedia
>>> MediaView ERR: javafx.scene.media.MediaErrorEvent[source=MediaView@49cb2444[styleClass=media-view]]: source MediaView@49cb2444[styleClass=media-view]; target MediaView@49cb2444[styleClass=media-view]; error MediaException: MEDIA_UNSUPPORTED : [] ERROR_MEDIA_AUDIO_FORMAT_UNSUPPORTED: ERROR_MEDIA_AUDIO_FORMAT_UNSUPPORTED


Ubuntu 15.10 has only the following libavcodec and libavformat packages:

libavcodec-ffmpeg-dev
libavcodec-ffmpeg56
libavcodec-dev
libavcodec-extra
libavcodec-ffmpeg-extra56

libavformat-ffmpeg56
libavformat-dev
libavformat-ffmpeg-dev

We will first need support to build and run on libavcodec 56 -- see JDK-8136920.

We will then need to deliver an FX media wrapper library that supports libavcodec 56, libavplugin-56.so (and maybe also *-55.so in case that is used by a non-Ubuntu Linux distro).

This may need to be backported to JDK 8u if support for newer Ubuntu releases is desired.
Comments
This is duplicate of JDK-8136920.
19-02-2016

Note: as a workaround, it might be possible to install the older packages from the 14.04 repository (14.04 is an LTS version) on a newer Ubuntu installation, but I have not tried this.
20-01-2016