Gstreamer with Jelly Bean and IMX6.

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

Gstreamer with Jelly Bean and IMX6.

Jump to solution
6,885 Views
by
Contributor II

Good morning,

     I want to use gstreamer on IMX6Q ( plateform Saber Lite ) with the Jelly Bean ( 4.2.2 ). I ve downloaded the tutorial of Gstreamer and compile it (http://docs.gstreamer.com/display/GstSDK/Android+tutorial+5%3A+A+Complete+media+player) . Gstreamer use the openMAX interface to access the hardware acceleration. The tutorial application stop the movie play with the message : can't configure supporting library.

The GStreamer tutorial works well with a Jelly Bean and another tablet. So I suspect that there's something wrong between the openMAX interface and the FSL. Do you have any hint of what it could be, or what I could do?

                      Thanks,

                        

                                   Yves

The error is :

I/GStreamer( 4030): GStreamer initialized:

I/GStreamer( 4030):   playing:false position:0 uri: file:///sdcard/Videos/star_trek2_tlr3-1080p-HDTN.mp4

D/GStreamer+tutorial-5( 4030): 0:01:20.830646010 0x40d6b880 jni/tutorial-5.c:444:gst_native_set_uri Setting URI to file:///sdcard/Videos/star_trek2_tlr3-1080p-HDTN.mp4

D/GStreamer+tutorial-5( 4030): 0:01:20.830870010 0x40d6b880 jni/tutorial-5.c:479:gst_native_set_position Scheduling seek to 0:00:00.000000000 for later

D/GStreamer+tutorial-5( 4030): 0:01:20.830953010 0x40d6b880 jni/tutorial-5.c:466:gst_native_pause Setting state to PAUSED

D/GStreamer+tutorial-5( 4030): 0:01:20.831329343 0x635e8860 jni/tutorial-5.c:104:set_ui_message Setting message to: State changed to READY

E/BufferQueue( 2431): [com.gst_sdk_tutorials.tutorial_5/com.gst_sdk_tutorials.tutorial_5.Tutorial5] dequeueBuffer: can't dequeue multiple buffers without setting the buffer count

W/GStreamer+qtdemux( 4030): 0:01:20.935713010 0x636cc8f0 qtdemux_types.c:192:qtdemux_type_get unknown QuickTime node type avc1

W/GStreamer+qtdemux( 4030): 0:01:20.937303343 0x636cc8f0 qtdemux_types.c:192:qtdemux_type_get unknown QuickTime node type avcC

W/GStreamer+qtdemux( 4030): 0:01:20.938214343 0x636cc8f0 qtdemux_types.c:192:qtdemux_type_get unknown QuickTime node type avc1

W/GStreamer+qtdemux( 4030): 0:01:20.938432676 0x636cc8f0 qtdemux_types.c:192:qtdemux_type_get unknown QuickTime node type avcC

W/GStreamer+qtdemux( 4030): 0:01:20.946673010 0x636cc8f0 qtdemux.c:7106:qtdemux_parse_trak:<qtdemux0> unknown version 00000000

I/OMXClient( 4030): Using client-side OMX mux.

I/OMXClient( 4030): Using client-side OMX mux.

I/vpu-lib ( 2434): Product Info: i.MX6Q/D/S

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.streaming.sw-based' already exists, ignoring this one.

E/OMXMaster( 4030): A component of name 'OMX.Freescale.std.parser.fsl.sw-based' already exists, ignoring this one.

E/OMXNodeInstance( 4030): OMX_GetExtensionIndex failed

I/SoftAAC2( 4030): Downmixing multichannel AAC to stereo

I/SoftAAC2( 4030): Reconfiguring decoder: 48000 Hz, 2 channels

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3c166e0, paddr: 0x395da000, vaddr: 0x454b7000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3d3b260, paddr: 0x3c12b000, vaddr: 0x48008000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3422b40, paddr: 0x3cf7b000, vaddr: 0x48e58000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd6831ee0, paddr: 0x3e374000, vaddr: 0x4a251000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd683d620, paddr: 0x36d55000, vaddr: 0x42c32000

I/vpu-lib ( 2434): bitstreamMode 1, chromaInterleave 0, mapType 0, tiled2LinearEnable 0

I/vpu-lib ( 2434): <gpu> free handle: 0xd3c166e0, paddr: 0x395da000, vaddr: 0x454b7000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3d3b260, paddr: 0x3c12b000, vaddr: 0x48008000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3422b40, paddr: 0x3cf7b000, vaddr: 0x48e58000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3c166e0, paddr: 0x395da000, vaddr: 0x454b7000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3d3b260, paddr: 0x3c12b000, vaddr: 0x48008000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3422b40, paddr: 0x3cf7b000, vaddr: 0x48e58000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3f7e9c0, paddr: 0x3d1c5000, vaddr: 0x490a2000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3f7e5c0, paddr: 0x3d40f000, vaddr: 0x492ec000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3f7eac0, paddr: 0x3d9b8000, vaddr: 0x49895000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd355a0a0, paddr: 0x3dc02000, vaddr: 0x49adf000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3d3b6e0, paddr: 0x3e874000, vaddr: 0x4a751000

I/vpu-lib ( 2434): <gpu> alloc handle: 0xd3d3b8e0, paddr: 0x3ee71000, vaddr: 0x4ad4e000

W/libOpenSLES( 4030): Leaving Object::GetInterface (SL_RESULT_FEATURE_UNSUPPORTED)

E/GStreamer+opensles_sink( 4030): 0:01:25.826698344 0x63a56920 openslessink.c:152:_opensles_query_capabilities:<GstOpenSLESSink@0x63bb27f8> engine.GetInterface(IODeviceCapabilities) failed(0x0000000c)

W/libOpenSLES( 4030): Leaving OutputMix::GetDestinationOutputDeviceIDs (SL_RESULT_BUFFER_INSUFFICIENT)

E/GStreamer+amcvideodec( 4030): 0:01:25.973212344 0x63a56920 gstamcvideodec.c:774:gst_amc_video_dec_fill_buffer:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> Slice height not set

W/GStreamer+amcvideodec( 4030): 0:01:25.974369344 0x63a56920 gstamcvideodec.c:1175:gst_amc_video_dec_loop:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> error: Invalid sized input buffer

D/GStreamer+tutorial-5( 4030): 0:01:25.974784010 0x635e8860 jni/tutorial-5.c:104:set_ui_message Setting message to: Error received from element amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1: Could not configure supporting library.

E/GStreamer+amcaudiodec( 4030): 0:01:25.976972677 0x64c76320 gstamcaudiodec.c:1128:gst_amc_audio_dec_handle_frame:<amcaudiodec-omxgoogleaacdecoder1> Downstream returned wrong-state

W/SoftAAC2( 4030): AAC decoder returned error 4098, substituting silence

E/GStreamer+amcvideodec( 4030): 0:01:25.977958677 0x63abf200 gstamcvideodec.c:1520:gst_amc_video_dec_handle_frame:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> Downstream returned not-negotiated

E/GStreamer+amc( 4030): 0:01:25.987239677 0x637a3b50 gstamc.c:701:gst_amc_codec_dequeue_output_buffer Failed to call Java method

D/dalvikvm( 4030): threadid=18: thread exiting, not yet detached (count=0)

I/vpu-lib ( 2434): <gpu> free handle: 0xd3d3b6e0, paddr: 0x3e874000, vaddr: 0x4a751000

I/vpu-lib ( 2434): <gpu> free handle: 0xd355a0a0, paddr: 0x3dc02000, vaddr: 0x49adf000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3f7eac0, paddr: 0x3d9b8000, vaddr: 0x49895000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3f7e5c0, paddr: 0x3d40f000, vaddr: 0x492ec000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3f7e9c0, paddr: 0x3d1c5000, vaddr: 0x490a2000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3422b40, paddr: 0x3cf7b000, vaddr: 0x48e58000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3d3b260, paddr: 0x3c12b000, vaddr: 0x48008000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3c166e0, paddr: 0x395da000, vaddr: 0x454b7000

D/dalvikvm( 4030): threadid=19: thread exiting, not yet detached (count=0)

D/dalvikvm( 4030): threadid=14: thread exiting, not yet detached (count=0)

D/dalvikvm( 4030): threadid=13: thread exiting, not yet detached (count=0)

W/ThrottleService( 2716): unable to find stats for iface rmnet0

D/dalvikvm( 2716): GC_CONCURRENT freed 708K, 13% free 6523K/7492K, paused 5ms+5ms, total 46ms

D/dalvikvm( 2716): GC_FOR_ALLOC freed 502K, 14% free 6507K/7492K, paused 44ms, total 44ms

I/ActivityManager( 2716): START u0 {act=com.android.systemui.recent.action.TOGGLE_RECENTS flg=0x10800000 cmp=com.android.systemui/.recent.RecentsActivity (has extras)} from pid 2847

D/dalvikvm( 2716): GC_FOR_ALLOC freed 107K, 14% free 6476K/7492K, paused 37ms, total 37ms

D/dalvikvm( 2716): GC_FOR_ALLOC freed 3K, 13% free 6534K/7492K, paused 35ms, total 35ms

I/dalvikvm-heap( 2716): Grow heap (frag case) to 6.618MB for 69908-byte allocation

D/dalvikvm( 2716): GC_FOR_ALLOC freed <1K, 13% free 6603K/7564K, paused 35ms, total 35ms

E/BufferQueue( 2431): [com.android.systemui/com.android.systemui.recent.RecentsActivity] dequeueBuffer: can't dequeue multiple buffers without setting the buffer count

D/GStreamer( 4030): Surface destroyed

D/GStreamer+tutorial-5( 4030): 0:13:59.518345434 0x40d6b880 jni/tutorial-5.c:531:gst_native_surface_finalize Releasing Native Window 0x6390bd28

D/GStreamer+tutorial-5( 4030): 0:13:59.519244100 0x635e8860 jni/tutorial-5.c:104:set_ui_message Setting message to: State changed to READY

D/GStreamer( 4030): Saving state, playing:true position:0 duration: 0 uri: file:///sdcard/Videos/star_trek2_tlr3-1080p-HDTN.mp4

I/ActivityManager( 2716): Killing 4030:com.gst_sdk_tutorials.tutorial_5/u0a10038: remove task

E/OMXNodeInstance( 2434): !!! Observer died. Quickly, do something, ... anything...

W/InputDispatcher( 2716): channel '4142ad38 com.gst_sdk_tutorials.tutorial_5/com.gst_sdk_tutorials.tutorial_5.Tutorial5 (server)' ~ Consumer closed input channel or an error occurred. events=0x9

E/InputDispatcher( 2716): channel '4142ad38 com.gst_sdk_tutorials.tutorial_5/com.gst_sdk_tutorials.tutorial_5.Tutorial5 (server)' ~ Channel is unrecoverably broken and will be disposed!

I/vpu-lib ( 2434): <gpu> free handle: 0xd683d620, paddr: 0x36d55000, vaddr: 0x42c32000

I/vpu-lib ( 2434): <gpu> free handle: 0xd6831ee0, paddr: 0x3e374000, vaddr: 0x4a251000

I/vpu-lib ( 2434): <gpu> free handle: 0xd3d3b8e0, paddr: 0x3ee71000, vaddr: 0x4ad4e000

E/OMXNodeInstance( 2434): !!! Observer died. Quickly, do something, ... anything...

I/vpu-lib ( 2434): <gpu> free handle: 0xd3df7b20, paddr: 0x36224000, vaddr: 0x42101000

I/vpu-lib ( 2434): <gpu> free handle: 0xd6831260, paddr: 0x3de74000, vaddr: 0x49d51000

I/vpu-lib ( 2434): <gpu> free handle: 0xd6831660, paddr: 0x3eb64000, vaddr: 0x4aa41000

W/InputDispatcher( 2716): Attempted to unregister already unregistered input channel '4142ad38 com.gst_sdk_tutorials.tutorial_5/com.gst_sdk_tutorials.tutorial_5.Tutorial5 (server)'


Labels (3)
Tags (1)
1 Solution
2,316 Views
varsmolta
Contributor V

i believe gstreamer/gst-omx - OpenMAX IL GStreamer wrapper plugin can be used to access the openmax IL layer to access the HW coder from gstreamer. However, gstreamer 1.0 must be used as the base since gst-omx won't work with gstreamer 10.36, which is what gst-fsl-plugins is on right now.

Also, here is a pdf which explains some of it: http://elinux.org/images/e/e0/Gst-openmax.pdf

View solution in original post

0 Kudos
13 Replies
2,316 Views
tamilarasum
Contributor I

Hi All

                    I have downloaded gstreamer sdk (gstreamer-1.0-android-arm-1.0.7-debug) and I added gst-omx.

the pipe line I used is

data->pipeline = gst_parse_launch ("filesrc location=/sdcard/DCIM/Aasai.mp4 ! qtdemux ! h264parse ! omxh264dec ! autovideosink sync=false", &error);

While playing the video I am getting below mentioned error

E/GStreamer+omx( 5297): 0:00:19.110730003 0x51b59150 gstomx.c:1905:gst_omx_port_set_enabled_unlocked:<omxh264dec-omxh264dec0> Failed to send enable/disable command to hw-based port 1: Not ready (0x80001010)

W/GStreamer+videodecoder( 5297): 0:00:19.110932003 0x51b59150 gstvideodecoder.c:803:gst_video_decoder_setcaps:<omxh264dec-omxh264dec0> Subclass refused caps

W/GStreamer+videodecoder( 5297): 0:00:19.111177336 0x51b59150 gstvideodecoder.c:1983:gst_video_decoder_chain:<omxh264dec-omxh264dec0> error: encoder not initialized

D/GStreamer+tutorial-3( 5297): 0:00:19.111853003 0x51b8b400 jni/tutorial-3.c:92:set_ui_message Setting message to: Error received from element omxh264dec-omxh264dec0: GStreamer error: negotiation problem.

Kindly Help me on this

Regards,

Tamil.M

0 Kudos
2,316 Views
by
Contributor II

Hi All,

   Actually I used the 1.2.0 gstreamer part (http://gstreamer.freedesktop.org/src/http://gstreamer.freedesktop.org/src/). It was a pain to compile and to make it work. Now I ve got an H264 video which could be played with gstreamer.

What I ve done :

- I use the last gstreamer

- gstreamer 1.2 ( http://gstreamer.freedesktop.org/data/pkg/android/1.2.0/ ) use androidmedia which use OpenMax.

- you have to have at least use the JellyBean to have hardware acceleration ( as indicated in the gstreamer mailling list ( http://lists.freedesktop.org/archives/gstreamer-android/2013-October/thread.html ).

- There's a patch to apply to one of the androidmedia file to make it works ( else there's a slice bug )

=> So if you try without source modification, I doubt it will works. I prefer ( have to in fact ) post the patch in the mailling list of gstreamer, and it's not the point. When I answers last time it was still not so good. It was just gst-inspect which was working quite well. Now it works but the hardware acceleration is not so good ( ie some lag ).

-"decobin  !  autovideosink" works well with androidmedia. In fact decodebin choose for you the rigth decoder to use.

- I can't help with gst-omx, but in : http://gstreamer-devel.966125.n4.nabble.com/Hardware-decoding-on-android-using-GStreamer-td4660630.h...http://gstreamer-devel.966125.n4.nabble.com/Hardware-decoding-on-android-using-GStreamer-td4660630.h.... Mr Dröge suggest to use androidmedia. This plugin has the capacity to guess the hardware decoder name. My guess is that gst-omx was the first attempt to make an android plugin.

So : Can't help with your gstreamer 1.0.7 and gst-omx configuration.

You could also post your question on the gstreamer mailling list. Can't help much more.

 

          Yves

2,316 Views
gdm
Contributor II

Hi Yves,

how did you cross-compile the 1.2.0 gstreamer? Did u use the Cerbero tool? ...seems like Cerbero does not support Jelly Bean.

Also, where can I find the patch you are talking about? Would you post the URL?

Or, do you know if that patched code is now part of the latest release?

Thank you.

Giuseppe

0 Kudos
2,316 Views
LeonardoSandova
Specialist I

Log indicates a caps negotiation problem, I am not sure if the problem is between parse & dec or dec & sink. Are  you sure autovideosink is the right element for video sink? On linux we use other FSL elements, which takes advantages of HW (alias IPU). I got no experience on OpenMax, so I can't suggest the right element.

Leo

0 Kudos
2,316 Views
tamilarasum
Contributor I

Hi

                            I am using gstreame with Android running on  IMX6 board .I have downloaded gstreamer sdk and running the tutorial5 on IMX6 board.When i played the HD video ,I got the same issue you faced .           

E/GStreamer+amcvideodec( 4030): 0:01:25.973212344 0x63a56920 gstamcvideodec.c:774:gst_amc_video_dec_fill_buffer:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> Slice height not set

W/GStreamer+amcvideodec( 4030): 0:01:25.974369344 0x63a56920 gstamcvideodec.c:1175:gst_amc_video_dec_loop:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> error: Invalid sized input buffer

D/GStreamer+tutorial-5( 4030): 0:01:25.974784010 0x635e8860 jni/tutorial-5.c:104:set_ui_message Setting message to: Error received from element amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1: Could not configure supporting library.

E/GStreamer+amcaudiodec( 4030): 0:01:25.976972677 0x64c76320 gstamcaudiodec.c:1128:gst_amc_audio_dec_handle_frame:<amcaudiodec-omxgoogleaacdecoder1> Downstream returned wrong-state

W/SoftAAC2( 4030): AAC decoder returned error 4098, substituting silence

E/GStreamer+amcvideodec( 4030): 0:01:25.977958677 0x63abf200 gstamcvideodec.c:1520:gst_amc_video_dec_handle_frame:<amcvideodec-omxfreescalestdvideodecoderavcv3hwbased1> Downstream returned not-negotiated

E/GStreamer+amc( 4030): 0:01:25.987239677 0x637a3b50 gstamc.c:701:gst_amc_codec_dequeue_output_buffer Failed to call Java method

Did you get any solution to this issue.

Kindly Help me on this

Thanks and regards,

Tamil

0 Kudos
2,316 Views
LeonardoSandova
Specialist I

My 2-cents: I know GStreamer is more versatile, modular, friendly than OpenMAX, but if case you do not have a strong reason to use GStreamer, you will find much less surprises using OpenMAX.

0 Kudos
2,316 Views
by
Contributor II

Hi,

     The sdk is with the version 0.10. There's a version 1.10 which is available on freedesktop. This version is working a lot better. gstreamer use the plugin androidmedia which in fact use openmax. You could try using the 1.10 version with the sample and of the 0.10.

For my part, I have to use gstreamer, and using openmax is not a possibility.

hope it's Help,

                                   Yves

0 Kudos
2,316 Views
tamilarasum
Contributor I

HI,

                         I did not get the sdk verion 1.10. Could you give me the link?

Thanks and regards,

Tamil.m

0 Kudos
2,316 Views
varsmolta
Contributor V

are you able to run the simple "Hello World" gstreamer android app: Android tutorial 1: Link against GStreamer - GStreamer SDK documentation - GStreamer SDK documentati... without any errors?

0 Kudos
2,316 Views
by
Contributor II

Hello,

     In fact, yes. I'm able to build and run till the Android tutorial 3. They work fine. The 4 and the 5 did not work properly. There's perhaps some hidden error on the log for the 3 first app. I should check it.

0 Kudos
2,316 Views
jojorong
Contributor IV

Hi,

     I try to use gstreamer project to invoke HW codecs but meet this issue also, it looks like do not use HW codec when i play H264 movie,

do you fix this issue ? I use the tutorial-5 example here.

0 Kudos
2,317 Views
varsmolta
Contributor V

i believe gstreamer/gst-omx - OpenMAX IL GStreamer wrapper plugin can be used to access the openmax IL layer to access the HW coder from gstreamer. However, gstreamer 1.0 must be used as the base since gst-omx won't work with gstreamer 10.36, which is what gst-fsl-plugins is on right now.

Also, here is a pdf which explains some of it: http://elinux.org/images/e/e0/Gst-openmax.pdf

0 Kudos
2,316 Views
jojorong
Contributor IV

The gstreamer project can use "android media codec" aka "amc" to decode in native code,

BTW, someone has tested with "com.android.media.codec" module in the IMX6* for HW codec ?

0 Kudos