This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Samsung Galaxy Note 2 Mali GPU Problem with Opengl es2.0 in Android

Note: This was originally posted on 20th June 2013 at http://forums.arm.com

Hi Everyone,

I have created an android app for drawing of lines,circles.. by using GLSurfaceView in OpenGLES 2.0 like an Auto cad app.

The app works well with Google Nexus 7, in the sense that if we draw a line & then a circle the line doesn't get erased in surface view. But with Samsung Galaxy Note II, it is entirely different.

The line previously drawn before a circle being drawn, gets erased. i.e., each time if we draw a new line or circle, the previous one gets erased.I can draw only one image at a time. What I need is the same output which I get in Google Nexus 7 in Samsung Galaxy Note II.i.e.I want to draw more than one image in the GLSurfaceView at a time.

Note : Both the Android OS in Google Nexus 7 and Samsung Galaxy Note II are Jelly Bean 4.2. But both devices are different GPU. Google Nexus 7 GPU is ULP GeForce & Samsung Galaxy Note II is Mali400MP.

Would this be an issue in the rendering of output of the Surfaceview ?

Should we take into account of GPU while Coding ?

Can anyone tell me why this problem of different output in different devices ?

I  Posted this Problem in stackoverflow also. i got one reply. but, i cant solve out my issue..
this link having some sample code also for understanding..
http://stackoverflow.com/questions/17187032/why-my-opengl-output-differs-for-various-devices

Thanks Advance
  • Note: This was originally posted on 24th June 2013 at http://forums.arm.com

    Hi Harihrishnan,

    Do you have a reproducer app that we could test on our end?
    This will help us identify what the problem is, what the solution may be, and any workarounds that may be of use.

    Thanks in advance,


    McGeagh



    Hi Everyone,

    I have created an android app for drawing of lines,circles.. by using GLSurfaceView in OpenGLES 2.0 like an Auto cad app.

    The app works well with Google Nexus 7, in the sense that if we draw a line & then a circle the line doesn't get erased in surface view. But with Samsung Galaxy Note II, it is entirely different.

    The line previously drawn before a circle being drawn, gets erased. i.e., each time if we draw a new line or circle, the previous one gets erased.I can draw only one image at a time. What I need is the same output which I get in Google Nexus 7 in Samsung Galaxy Note II.i.e.I want to draw more than one image in the GLSurfaceView at a time.

    Note : Both the Android OS in Google Nexus 7 and Samsung Galaxy Note II are Jelly Bean 4.2. But both devices are different GPU. Google Nexus 7 GPU is ULP GeForce & Samsung Galaxy Note II is Mali400MP.

    Would this be an issue in the rendering of output of the Surfaceview ?

    Should we take into account of GPU while Coding ?

    Can anyone tell me why this problem of different output in different devices ?

    I  Posted this Problem in stackoverflow also. i got one reply. but, i cant solve out my issue..
    this link having some sample code also for understanding..
    http://stackoverflow...various-devices

    Thanks Advance

  • Note: This was originally posted on 12th July 2013 at http://forums.arm.com

    Hi McGeagh,
                             This is my Sample code here..

    http://www.mediafire.com/download/09f9q51xnqhq2l7/LineDraw_samplecode.zip

    my app apk file..
    http://www.mediafire.com/download/3w423jqfr1eord4/LineDraw_Test.apk

    please execute this code on Samsung Galaxy note II. then you will understand my problem..

    if you want any other clarification regarding my issue, please mail me instantly i reply for you..

    I am doing one project. i am stuck in this place. if possible please mail me for solution.kindly, i am waiting your reply...

    Thanks for your Reply McGeagh
    Harikrishnan.V
    vhkrishnan.v@gmail.com
    91- 9994310981
    my blog: http://www.hariandroid.wordpress.com/                       


    Hi Harihrishnan,

    Do you have a reproducer app that we could test on our end?
    This will help us identify what the problem is, what the solution may be, and any workarounds that may be of use.

    Thanks in advance,


    McGeagh



  • Note: This was originally posted on 15th July 2013 at http://forums.arm.com


    Hi McGeagh,
                             This is my Sample code here..

    http://www.mediafire..._samplecode.zip

    my app apk file..
    http://www.mediafire...neDraw_Test.apk

    please execute this code on Samsung Galaxy note II. then you will understand my problem..

    if you want any other clarification regarding my issue, please mail me instantly i reply for you..

    I am doing one project. i am stuck in this place. if possible please mail me for solution.kindly, i am waiting your reply...

    Thanks for your Reply McGeagh
    Harikrishnan.V
    vhkrishnan.v@gmail.com
    91- 9994310981
    my blog: http://www.hariandroid.wordpress.com/                 




    Hi Harikrishnan,

    Apologies for the delayed response.  I have attempted to download the linked source code and apk, however, mediafire says that the files are no longer available.

    I believe the issue you are experiencing, and the reason you code works correctly on the ULP GeForce is the underlying architecture of the GPU running your code.

    The ULP GeForce is an immediate renderer, meaning by default, it will preserve your buffers beyond GLswapbuffers.  Mali, however, is a Tile-Based renderer and does not default to this behaviour as it can cause undesired effects if used unintentionally.  Mali can, however, be made to preserve buffers in the same way by setting the EGL Preserve flag.

    There is an SDK example, EGL Preserve - '[color=#444444][font=arial][size=2]Color buffer preservation example'[/size][/font][/color], available at http://malideveloper.arm.com/develop-for-mali/sdks/opengl-es-2-sdk-for-android/ which you can look at to see how to configure for this option.

    This should help you resolve your issue.  If you try this and still experience problems, feel free to resend you application and I can trace through execution and try and help resolve your issue.

    Kind Regards,
    Rich
  • Note: This was originally posted on 15th July 2013 at http://forums.arm.com

    Note that color buffer preservation is not "free" as far as the GPU will generally need to read back the previous frame as the output window surface for the next frame is usually different due the pipeline behavior (i.e. they are N-buffered).

    If you only actually need to preserve a small area of the screen then it can be more efficient just to explicitly redraw using draw operations in the application.


    HTH,
    Iso