Bug 77966 - Trails / Tracks when rendering OpenGL ES 2 moving objects (Android-x86 / Mesa 10.0.4/5)
Summary: Trails / Tracks when rendering OpenGL ES 2 moving objects (Android-x86 / Mesa...
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: EGL (show other bugs)
Version: 10.0
Hardware: x86-64 (AMD64) other
: low minor
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-26 12:10 UTC by pstglia
Modified: 2014-07-21 10:55 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
logs for "Learn OpenGL ES 2.0" Samples (debug.egl.trace 1) (464.48 KB, text/plain)
2014-04-26 12:10 UTC, pstglia
Details
logs for "Live Ocean Benchmark" (which renders correctly) (465.47 KB, text/plain)
2014-04-26 12:13 UTC, pstglia
Details
Image showing the problem (114.54 KB, text/plain)
2014-04-26 12:15 UTC, pstglia
Details
Live Ocean Benchmark screenshot (renders without problems) (963.58 KB, text/plain)
2014-04-26 12:42 UTC, pstglia
Details
Learn OpenGL ES 2 screenshot (redraw problem) (114.54 KB, image/png)
2014-04-26 12:49 UTC, pstglia
Details
Live Ocean Benchmark screenshot (renders without problems) (963.58 KB, image/png)
2014-04-26 12:51 UTC, pstglia
Details
Patch (766 bytes, patch)
2014-04-28 23:48 UTC, pstglia
Details | Splinter Review

Description pstglia 2014-04-26 12:10:37 UTC
Created attachment 98023 [details]
logs for "Learn OpenGL ES 2.0" Samples (debug.egl.trace 1)

Hi,

I'm running the latest version of Android-x86 ( Kitkat RC1 ), but replaced bundled Mesa 9.2.1 by 10.0.4 and latter by 10.0.5 (See the procedure on https://groups.google.com/forum/#!topic/android-x86/lKPmDXtNzjM).

This replacement gives support to my Radeon (7660D IGP). However, some OpenGL ES 2 apps have a problem when rendering a sequence of moving objects. Seems previous frame is not clean, keeping a trail / track of the previous image.

A example of this is "Learn OpenGL ES 2" sample tutorial apps (http://www.learnopengles.com/). I attached 2 pics showing the problem.

Other apps using OpenGL ES 2 render correctly without problems. I got a picture from an app called "Live Ocean Benchmark", which works perfectly. Also, Play Store games like "Lawless" and "Angry Birds Star Wars" works correctly, except for the very first logos (they also have this redraw problem).

I turned on "debug.egl.trace" and generated logs to compare a working app (Live Ocean Benchmark) with a problematic one (Learn OpenGL ES 2). I attached them.

Could you say if this is a known problem with these versions of OpenGL? 
Couldn't test 10.1 on Android source tree to compare (Compiling errors).

Here's the full specs of machine/environment I tested:
CPU: AMD A10 5800K
VGA: Radeon 7660D (IGP - Integrated to the processor)
MEM: 8 Gb RAM (Corsair Vengeance 1600)

SO: Android-x86 ("KitKat - RC1" - Kernel 3.10.30 - 32 bits)
Mesa versions tested: 
 - 9.2.1 (Doesn't support my IGP) 
 - 10.0.4 (problem described above)
 - 10.0.5 (same as 10.0.4)

"OpenGL driver version" on Android Settings show this:
GL Vendor: X.org
GL Renderer: Gallium 0.4 on AMD ARUBA
GL Version: OpenGL ES 2.0 Mesa 10.0.4
  
Note: I created a bootable iso image to test it:
https://drive.google.com/file/d/0BxO6THtB865fanJ3MVdXWUplams/edit?usp=sharing

Thanks in advance
Comment 1 pstglia 2014-04-26 12:13:30 UTC
Created attachment 98024 [details]
logs for "Live Ocean Benchmark" (which renders correctly)

A working app to compare OpenGL calls
Comment 2 pstglia 2014-04-26 12:15:44 UTC
Created attachment 98025 [details]
Image showing the problem

Note: This sample works properly on other hardware configs
Comment 3 pstglia 2014-04-26 12:42:03 UTC
Created attachment 98026 [details]
Live Ocean Benchmark screenshot (renders without problems)

Basically use the same OpenGL calls, but renders correctly.
Comment 4 pstglia 2014-04-26 12:49:31 UTC
Created attachment 98029 [details]
Learn OpenGL ES 2 screenshot (redraw problem)

Image showing the problem. 
Note: Works properly on other hardware configs (e.g Intel GMA 3150, supported by Mesa Classic Drivers)
Comment 5 pstglia 2014-04-26 12:51:24 UTC
Created attachment 98031 [details]
Live Ocean Benchmark screenshot (renders without problems)

Live Ocean Benchmark screenshot (renders without problems)
Comment 6 pstglia 2014-04-28 03:40:23 UTC
Compiled 10.1.1 today. The same issue. This is the android 4.4 bootable iso I created, in case you have a similar hardware and want to test it by yourselves:

https://drive.google.com/file/d/0BxO6THtB865fMHpKb204ZUVRTGM/edit?usp=sharing
Comment 7 Michel Dänzer 2014-04-28 09:03:42 UTC
Looks like bug 72889. I guess src/gallium/state_trackers/egl/android/native_android.cpp needs to be fixed similarly.
Comment 8 pstglia 2014-04-28 23:48:18 UTC
Created attachment 98144 [details] [review]
Patch

Thanks for the info. I did the changes attached on native_android.cpp and they worked for me.

I based this on Martin Andersson patch (bug 72889) and on commit 6349b3235cc07d396325863ece9ca6261daf8e77.

Although it worked for me, don't know if this is the best way of doing this fix.

Some of you guys could check it out please?

Thanks!
pstglia
Comment 9 Michel Dänzer 2014-05-02 03:52:16 UTC
Might it be better to handle this in android_surface_enqueue_buffer() instead?

Anyway, please submit the patch to the mesa-dev mailing list for review. Preferably using git send-email, but at least using git format-patch.
Comment 10 Emil Velikov 2014-07-21 10:55:38 UTC
Paulo

Afaics your patch has landed in master a while back plus I've sent some of the fixes linked for inclusion to master+stable.

Feel free to open a new bug(s) for the remaining build problems.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.