Many iMX gstreamer plugins are blacklisted, beep.mp3 is missing entirely. How do I play MP3s?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Many iMX gstreamer plugins are blacklisted, beep.mp3 is missing entirely. How do I play MP3s?

Jump to solution
6,110 Views
ralph__
Contributor IV

I've got a Buildroot-based system running on my iMX Solo evaluation board.

I have Gstreamer installed along with all the iMX libs and iMX patches applied to Buildroot as per Buildroot (busybox) - [PATCH 0/14 v3] freescale: update userspace packages (branch yem/fsl-imx)

Whenever I run gstreamer to try and play back an MP3 I get this output (N.B. My GST_PLUGIN_PATH has been set up correctly):

gplay /usr/sample.mp3

(gst-plugin-scanner:216): GStreamer-CRITICAL **: gst_element_class_add_pad_template: assertion 'GST_IS_PAD_TEMPLATE (templ)' failed

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_h264dec.so': lib_H264_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

MAX resolution 1920x1080

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_audio_pp.so': lib_peq_arm11_elinux.so.1: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-CRITICAL **: gst_element_class_add_pad_template: assertion 'GST_IS_PAD_TEMPLATE (templ)' failed

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mpeg4aspdec.so': lib_MPEG4ASP_dec_arm11_elinux.so.1: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mp3enc.so': lib_mp3_enc_arm12_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mpeg2dec.so': lib_mpeg2_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_amrdec.so': lib_nb_amr_dec_arm9_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/lib_src_ppp_arm11_elinux.so': /usr/lib/imx-mm/audio-codec/lib_src_ppp_arm11_elinux.so: undefined symbol: src_up2_prefilter_proc

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_vorbisd_wrap_arm12_elinux.so': lib_oggvorbis_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_mp3d_wrap_arm12_elinux.so': lib_mp3_dec_arm12_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_aacd_wrap_arm11_elinux.so': lib_aac_dec_arm11_elinux.so.3: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_aacd_wrap_arm12_elinux.so': lib_aac_dec_arm12_elinux.so.3: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_aacd_wrap_arm9_elinux.so': lib_aac_dec_arm9_elinux.so.3: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_vorbisd_wrap_arm11_elinux.so': lib_oggvorbis_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_mp3d_wrap_arm9_elinux.so': lib_mp3_dec_arm9_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/imx-mm/audio-codec/wrap/lib_mp3d_wrap_arm11_elinux.so': lib_mp3_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_h264dec.so': lib_H264_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_audio_pp.so': lib_peq_arm11_elinux.so.1: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mpeg4aspdec.so': lib_MPEG4ASP_dec_arm11_elinux.so.1: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mp3enc.so': lib_mp3_enc_arm12_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mpeg2dec.so': lib_mpeg2_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:216): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_amrdec.so': lib_nb_amr_dec_arm9_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:218): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_mpeg2dec.so': lib_mpeg2_dec_arm11_elinux.so.2: cannot open shared object file: No such file or directory

(gst-plugin-scanner:218): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-0.10/libmfw_gst_amrdec.so': lib_nb_amr_dec_arm9_elinux.so.2: cannot open shared object file: No such file or directory

playbin2 is employed!

fsl_player_init(): Successfully initialize!

fsl_player_set_media_location(): filename=/usr/sample.mp3

[Stopped  ][Vol=01][00:00:00/00:00:00][fps:0]state change failed from 2 to 4

try to play failed

FSL_PLAYER_01.00_LINUX build on Sep 29 2014 22:06:59

        [h]display the operation Help

        [p]Play

        [s]Stop

        [e]Seek

        [a]Pause when playing, play when paused

        [v]Volume

        [m]Switch to mute or not

        [>]Play next file

        [<]Play previous file

        [r]Switch to repeated mode or not

        [f]Set full screen or not

        [z]resize the width and height

        [t]Rotate

        [c]Setting play rate

        [i]Display the metadata

        [x]eXit

[Stopped  ][Vol=01][00:00:00/00:00:00][fps:0] Aborted by signal[2] Interrupt...

FSL_PLAYER_UI_MSG_EXIT

fsl_player_stop()

player_exit(): No more multimedia files, exit.

Aborted by signal[2] Interrupt...

Aborted by signal[2] Interrupt...

Aborted by signal[2] Interrupt...

Aborted by signal[2] Interrupt...

g_main_loop_thread_fun() quit!

fsl_player_deinit

When I run gst-inspect-0.10 I get:

# gst-inspect-0.10 | grep imx

beep.imx: ac3: ac3

beep.imx: 3ca: ac3

beep.imx:  beepdec: beep audio decoder

isink.imx:  mfw_isink: IPU-based video sink

tvsrc.imx:  tvsrc: v4l2 based tv src

vpu.imx:  vpudec: VPU-based video decoder

vpu.imx:  vpuenc: VPU-based video encoder

aiur.imx: webm: webm

aiur.imx:  aiurdemux: aiur universal demuxer

ipucsc.imx:  mfw_ipucsc: IPU-based video converter

v4lsrc.imx:  mfw_v4lsrc: v4l2 based camera src

v4lsink.imx:  mfw_v4lsink: v4l2 video sink

But most people seem to have beep.mp3 there too. Any idea why it isn't there?

Finally, here is my list of blacklisted plugins in case it helps anyone diagnose my problem:

# gst-inspect-0.10 -b

Blacklisted files:

  libmfw_gst_amrdec.so

  libmfw_gst_mpeg2dec.so

  libmfw_gst_mp3enc.so

  libmfw_gst_mpeg4aspdec.so

  libmfw_gst_audio_pp.so

  libmfw_gst_h264dec.so

  lib_g.729ab_dec_arm11_elinux.so

  lib_g.723.1_dec_arm11_elinux.so

  lib_wb_amr_dec_arm9_elinux.so

  lib_g.726_enc_arm11_elinux.so

  lib_mp3_enc_arm9_elinux.so

  lib_g.726_dec_arm11_elinux.so

  lib_mp3_dec_arm12_elinux.so

  lib_mp3_dec_arm9_elinux.so

  lib_g.729ab_enc_arm11_elinux.so

  lib_g.711_dec_arm11_elinux.so

  lib_bsac_dec_arm11_elinux.so

  lib_g.723.1_dec_arm9_elinux.so

  lib_mp3d_wrap_arm11_elinux.so

  lib_mp3d_wrap_arm9_elinux.so

  lib_vorbisd_wrap_arm11_elinux.so

  lib_aacd_wrap_arm9_elinux.so

  lib_aacd_wrap_arm12_elinux.so

  lib_aacd_wrap_arm11_elinux.so

  lib_mp3d_wrap_arm12_elinux.so

  lib_vorbisd_wrap_arm12_elinux.so

  lib_sbc_enc_arm11_elinux.so

  lib_g.711_enc_arm11_elinux.so

  lib_nb_amr_enc_arm9_elinux.so

  lib_g.729ab_dec_arm9_elinux.so

  lib_peq_arm11_elinux.so

  lib_g.726_enc_arm9_elinux.so

  lib_nb_amr_dec_arm11_elinux.so

  lib_g.711_dec_arm9_elinux.so

  lib_g.726_dec_arm9_elinux.so

  lib_aac_dec_arm12_elinux.so

  lib_g.729ab_enc_arm9_elinux.so

  lib_wb_amr_enc_arm9_elinux.so

  lib_g.723.1_enc_arm11_elinux.so

  lib_mp3_enc_arm12_elinux.so

  lib_nb_amr_enc_arm11_elinux.so

  lib_flac_dec_arm9_elinux.so

  lib_oggvorbis_dec_arm11_elinux.so

  lib_src_ppp_arm11_elinux.so

  lib_nb_amr_dec_arm9_elinux.so

  lib_g.723.1_enc_arm9_elinux.so

  lib_aac_dec_arm9_elinux.so

  lib_aac_dec_arm11_elinux.so

  lib_flac_dec_arm11_elinux.so

  lib_sbc_enc_arm9_elinux.so

  lib_mp3_dec_arm11_elinux.so

  lib_mp3_enc_arm11_elinux.so

  lib_g.711_enc_arm9_elinux.so

  lib_gif_dec_arm11_elinux.so

  lib_MPEG4ASP_dec_arm11_elinux.so

  lib_H264_dec_arm11_elinux.so

  lib_jpeg_dec_arm11_elinux.so

  lib_H264_dec_arm9_elinux.so

  lib_bmp_dec_arm11_elinux.so

  lib_MPEG4ASP_dec_arm9_elinux.so

  lib_png_dec_arm11_elinux.so

  lib_jpeg_enc_arm11_elinux.so

  lib_mpeg2_dec_arm11_elinux.so

  lib_deinterlace_arm11_elinux.so

  lib_jpeg_dec_arm9_elinux.so

Many thanks.

Ralph

Tags (3)
1 Solution
3,004 Views
ralph__
Contributor IV

I've finally got this working after a somewhat epic struggle.

Basically, the gst-fsl-plugins 3.0.11 makefile was not including the mp3decoder directory when it was being built and so.... the mp3 decoder never got built.

After this it was just a matter of getting the build dependencies right between qt and the gstreamer packages.

In the end, beepdec.mp3 was not the correct mp3 plugin to use and in fact the correct plugin to use was mfw_mp3decoder. I have no idea why other people are using this beepdec.mp3 plugin as it seems deprecated.

Finally, I had wrong paths in my beep_registry.arm12.cf file. Slightly confusing how this was required even though I wasn't using the beepdec.mp3 codec.

View solution in original post

5 Replies
3,004 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Ralph,

Besides checking the gstreamer group I would recommend checking which BSP and images are showing the complete list to compare and determine where the difference may rely. There are some considering differences between the Community BSP and the BSP Release as I mentioned but also on packages available on each image.

Let us know if you are able to compare these images with the correct plugin list!

0 Kudos
Reply
3,004 Views
ralph__
Contributor IV

Okay, I'm going to install a demo image and report back. Thanks.

0 Kudos
Reply
3,004 Views
ralph__
Contributor IV

I managed to get mp3s playing using an old Yocto image:

http://boundarydevices.com/yocto-kernel-3-10-17-beta/#comment-591212

which is a start.

I then went back to my own build system and through much googling realised that the Makefile for gst-fsl-plugins was missing some important paths for MP3 decode.

In gst-fsl-plugins/Makefile.am, I added MP3DEC_DIR to line 930 (below the "if PLATFORM_IS_MX6" line):

SUBDIRS = $(AUDIODIRS)  $(LIBSDIRS) $(BASEDIRS) $(VPUWRAPDIRS) $(WMA8ENC_DIR) $(MP3ENC_DIR) $(MP3DEC_DIR) \

$(H264DEC_DIR) $(MPEG2DEC_DIR) $(MPEG4DEC_DIR) $(WMV9MPDEC_DIR) $(WMV78DEC_DIR) \

$(DOWNMIX_DIR) $(AMRDEC_DIR) $(IPUDIRS) $(TOOLDIRS)

When I rebuilt and rebooted the system I now had "beepdec.mp3" listed in my plugins using gst-inspect-0.10. The output from gst-inspect-0.10 beepdec.mp3 was even identical to the output on the working Yocto image system, except the codec version number had increased from 3.0.10 (on Yocto) to 3.0.11 on my system.

# gst-inspect-0.10 beepdec.mp3

Factory Details:

  Long name:    MP3 decoder

  Class:        Codec/Decoder/Audio

  Description:  Decode MP3 compressed audio to raw data

  Author(s):    Multimedia Team <shmmmw@freescale.com>

  Rank:         secondary + 2 (130)

Plugin Details:

  Name:                 beep.imx

  Description:          universal audio codec

  Filename:             /usr/lib/gstreamer-0.10/libmfw_gst_beep.so

  Version:              3.0.11

  License:              LGPL

  Source module:        gst-fsl-plugins

  Binary package:       Freescle Gstreamer Multimedia Plugins

  Origin URL:           http://www.freescale.com

GObject

+----GstObject

       +----GstElement

             +----GstBeepdec1

Pad Templates:

  SINK template: 'sink'

    Availability: Always

    Capabilities:

      audio/mpeg

            mpegversion: 1

  SRC template: 'src'

    Availability: Always

    Capabilities:

      audio/x-raw-int

                  width: { 16, 24, 32 }

                  depth: { 16, 24, 32 }

                   rate: { 7350, 8000, 11025, 12000, 16000, 22050, 24000, 32000, 44100, 48000, 64000, 88200, 96000 }

               channels: [ 1, 8 ]

Element Flags:

  no flags set

Element Implementation:

  Has change_state() function: gst_beepdec_state_change

Element has no clocking capabilities.

Element has no indexing capabilities.

Element has no URI handling capabilities.

Pads:

  SRC: 'src'

    Implementation:

      Has custom eventfunc(): gst_pad_event_default

      Has custom queryfunc(): gst_pad_query_default

        Provides query types:

                (2):    duration (Total duration)

      Has custom iterintlinkfunc(): gst_pad_iterate_internal_links_default

      Has getcapsfunc(): gst_pad_get_fixed_caps_func

      Has acceptcapsfunc(): gst_pad_acceptcaps_default

    Pad Template: 'src'

  SINK: 'sink'

    Implementation:

      Has chainfunc(): gst_beepdec_chain

      Has custom eventfunc(): gst_beepdec_sink_event

      Has custom queryfunc(): gst_pad_query_default

      Has custom iterintlinkfunc(): gst_pad_iterate_internal_links_default

      Has setcapsfunc(): gst_beepdec_setcaps

      Has acceptcapsfunc(): gst_pad_acceptcaps_default

    Pad Template: 'sink'

Element Properties:

  name                : The name of the object

                        flags: readable, writable

                        String. Default: "beepdec10"

  resync-threshold    : set threshold for resync timestamp: -1, disable resync

                        flags: readable, writable

                        Integer64. Range: -1 - 9223372036854775807 Default: 2000000000

  reset-when-resync   : enable/disable reset when resync

                        flags: readable, writable

                        Boolean. Default: true

  set-layout          : enable/disable set output channel layout

                        flags: readable, writable

                        Boolean. Default: true

Sadly, I still can't play back MP3s using gplay (or using Qt for that matter). Here is the output:

# gplay /usr/sample.mp3

playbin2 is employed!

fsl_player_init(): Successfully initialize!

fsl_player_set_media_location(): filename=/usr/sample.mp3

[Stopped  ][Vol=01][00:00:00/00:00:00][fps:0]state change failed from 2 to 4

try to play failed

get GST_MESSAGE_ELEMENT missing-plugin, type=(string)decoder, detail=(GstCaps)application/x-id3, name=(string)"ID3\ tag\ demuxer";

Debug: gstdecodebin2.c(3576): gst_decode_bin_expose (): /GstPlayBin2:playbin0/GstURIDecodeBin:uridecodebin0/GstDecodeBin2:decodebin20:

no suitable plugins found

Error: Your GStreamer installation is missing a plug-in.

fsl_player_stop()

FSL_PLAYER_UI_MSG_INTERNAL_ERROR: internal error message received.

fsl_player_stop()

player_exit(): No more multimedia files, exit.

FSL_PLAYER_01.00_LINUX build on Oct 27 2014 19:42:55

        [h]display the operation Help

        [p]Play

        [s]Stop

        [e]Seek

        [a]Pause when playing, play when paused

        [v]Volume

        [m]Switch to mute or not

        [>]Play next file

        [<]Play previous file

        [r]Switch to repeated mode or not

        [f]Set full screen or not

        [z]resize the width and height

        [t]Rotate

        [c]Setting play rate

        [i]Display the metadata

        [x]eXit

g_main_loop_thread_fun() quit!

fsl_player_deinit

0 Kudos
Reply
3,005 Views
ralph__
Contributor IV

I've finally got this working after a somewhat epic struggle.

Basically, the gst-fsl-plugins 3.0.11 makefile was not including the mp3decoder directory when it was being built and so.... the mp3 decoder never got built.

After this it was just a matter of getting the build dependencies right between qt and the gstreamer packages.

In the end, beepdec.mp3 was not the correct mp3 plugin to use and in fact the correct plugin to use was mfw_mp3decoder. I have no idea why other people are using this beepdec.mp3 plugin as it seems deprecated.

Finally, I had wrong paths in my beep_registry.arm12.cf file. Slightly confusing how this was required even though I wasn't using the beepdec.mp3 codec.

3,004 Views
gusarambula
NXP TechSupport
NXP TechSupport

Thank you for posting your findings! I’m sure they will help other users on the communities!

0 Kudos
Reply