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 710269 - [Android] problem with egladaption/eglglessink on some devices/emulator and fatal error
[Android] problem with egladaption/eglglessink on some devices/emulator and f...
Status: RESOLVED NOTGNOME
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
unspecified
Other Linux
: Normal critical
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-10-16 13:16 UTC by distran.sensors
Modified: 2014-05-09 06:37 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Log for execution of tutorial 3 on Android Emulator (Api9) using GStreamer 0.10 (7.84 KB, text/plain)
2013-10-16 13:16 UTC, distran.sensors
Details

Description distran.sensors 2013-10-16 13:16:26 UTC
Created attachment 257418 [details]
Log for execution of tutorial 3 on Android Emulator (Api9) using GStreamer 0.10

Hey all.

I am a getting to know GStreamer. I was trying to develop a simple Android application that would receive a network stream generated on Desktop pc. I got stuck in displaying simple video (e.g. videotestsrc) on some of my Android devices and I have no clue where to go next.

First the description of my setup. For development I am using Nexus 10 (Android 4.3, API 18), Android emulators (different API's, tested on API's 9, 10, 16, 17) and a phone LG-P990 (Android 2.3.4, API 10). I develop on Ubuntu 13.04 (64 bit) and I am using Android NDK r9 (newest one). I was trying to run tutorial 3 from the website (http://docs.gstreamer.com/display/GstSDK/Android+tutorial+3%3A+Video) using two GStreamer SDK's:
- GStreamer SDK 2013.6 (Congo, avalible at http://cdn.gstreamer.com/android/arm/gstreamer-sdk-android-arm-debug-2013.6.tar.bz2)
- GStreamer 1.2 (newest one, avalible at http://gstreamer.freedesktop.org/data/pkg/android/1.2.0/gstreamer-1.0-android-arm-1.2.0-debug.tar.bz2)

Of course, running tutorial 3 using GStreamer 1.2 required some minor changes in code:
- Android.mk:
        change GSTREAMER_SDK_ROOT to GSTREAMER_ROOT, so that it fits the variable defined at gstreamer-1.0.mk
        change gstreamer.mk to gstreamer-1.0.mk and gstreamer-video-0.10 to gstreamer-video-1.0 (and also remove interfaces)
- tutorial-3.c
        change #include <gst/interfaces/xoverlay.h> to #include <gst/video/videooverlay.h>
        change all occurences of "x_overlay" string to "video_overlay"
        change ffmpegcolorspace to videoconvert

Taking into consideration those changes, I was able to run demos on LG-P990 phone (Android 2.3.4), but I was not able to make it work neither on Nexus 10 nor any of emulators. I get different errors from Nexus and from emulators, but I feel the origin of those errors is the same.

From what I inferred, the problem is connected with creating the surface to display video. In both cases (emulator and Nexus 10) the error is generated after invoking nativePause() in Tutorial3.java - line 108 (which invokes gst_native_pause of tutorial-3.c line 247, where gst_element_set_state (data->pipeline, GST_STATE_PAUSED) function is invoked).

I attach a log files, with a setting gst_debug_set_threshold_for_name("*egl*", 5).
Comment 1 distran.sensors 2013-10-16 13:35:17 UTC
I am adding logs that I've created.

I was running tests on Samsung Nexus 10 with Android 4.3 (API18), LG P990 with Android 2.3.4 (API 10) and Emulator (API 9) and two versions of GStreamer (1.2 - newest, and 0.10 from www.gstreamer.com).

In both cases (GStreamer 1.2 and 0.10) I could create surface and run tutorial 3 (as well as 4 and 5) on LG P990 (Android 2.3.4, API 10). However, I could not get it working on Nexus and Emulator, no matter which version of GStreamer I used.

https://www.dropbox.com/sh/eufnlxu8o0vfezf/e1SfrQMLBd/logs

Logs from LG P990 are divided on 2 parts, parat 2 is just a fragment, where I press play and pause to play a video for a while.

On Emulator application does not crash, but it doesn't display anything except play and pause buttons. On Nexus application closes instantly with an error "Unfortunately, GStreamer tutorial 3 has stopped".

I am also adding source codes I used for testing. These are source code from Android Tutorial 3 from www.gstreamer.com (catalog 'android-tutorial-3-gs0-10') and it's slightly altered version to fit version 1.2 of GStreamer (catalog 'android-tutorial-3').

https://www.dropbox.com/sh/eufnlxu8o0vfezf/a_mAgMRR6Y

Could any of you reproduce such error, or happened to see it before? Do you have any advice on how to proceed further (my aim is to get in running on Nexus 10 device, and running on emulator would be also nice). I have tried to research problem on the internet, but I couldn't find any information concerning those errors.

Thanks in advance for your help!

Regards,
Michal
Comment 2 Heiher 2014-05-09 02:29:42 UTC
We encounter similar problem with a sumsung SM-P600 pad. The following changes can walkaround this:
In ext/eglgles/gstegladaptation_egl.c, gst_egl_adaptation_query_par(), let it always go into the "if (ctx->eglglesctx->egl_major == 1 && ctx->eglglesctx->egl_minor < 2)" branch.

It seems it's a bug in the underling libraries, since the invocation "eglQuerySurface (ctx->eglglesctx->display, ctx->eglglesctx->surface, EGL_PIXEL_ASPECT_RATIO, &display_par)" triggers a "div 0" exception.
Comment 3 Sebastian Dröge (slomo) 2014-05-09 06:37:19 UTC
Ok, let's close this then and please report it to the manufacturer of your hardware.

Independent of that, eglglessink is deprecated (and removed) now and replaced by glimagesink in 1.3 and later versions.