Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 460375
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T22:52:03+00:00 2026-05-12T22:52:03+00:00

I write graphics apps for the iPhone and I’m looking to port my most

  • 0

I write graphics apps for the iPhone and I’m looking to port my most recent app, ‘Layers,’ to the Android platform. Layers is painting app that allows users to draw on the screen and create multi-layered paintings with different brushes, colors, etc… and export to PSD. It’s got desktop sync, a smudge tool, lots of good stuff… http://www.layersforiphone.com/

I started looking at the Android platform Monday and I’ve run into a major problem. I use OpenGL to do all the drawing because it offers the best performance. However, there are several places where I need to render into a texture and then use the texture. For example:

  1. Use brush texture and a line of sprites to create a black paint stroke in texture A
  2. Put brush color+alpha in glColor4f and then draw texture A onto the screen.

On the iPhone, I do this continually as the user’s finger moves and I am able to achieve 12-15fps on a 1st gen iPod Touch. It’s necessary because applying color and alpha to the individual sprites making up the brush stroke doesn’t produce the right result (since sprites overlap and make the stroke too dark).

The android platform supports OpenGL ES 1.0 but seems to omit key functions for dealing with framebuffers. I can’t find a way to bind a texture to the framebuffer and draw into it using OpenGL.

Here’s how I’d normally go about it on the iPhone:

// generate a secondary framebuffer and bind it to OpenGL so we don't mess with existing output.
glGenFramebuffers(1, &compositingFramebuffer);
glBindFramebuffer(GL_FRAMEBUFFER, compositingFramebuffer);

// attach a texture to the framebuffer.
glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture, 0);

// subsequent drawing operations are rendered into the texture

// restore the primary framebuffer and (possibly) draw the rendered texture
glBindFramebuffer(GL_FRAMEBUFFER, originalActiveFramebuffer);

Is there anything like this on the Android platform? On the iPhone, OpenGL is significantly faster than software-based drawing and is the only viable solution (trust me – I wrote a CoreGraphics painting app too…). Maybe there’s another route I could take on Android? I’m willing to jump through whatever hoops are necessary, but I won’t publish the app unless performance is good (10fps+ as you’re drawing on the screen).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T22:52:03+00:00Added an answer on May 12, 2026 at 10:52 pm

    I’m skeptical that all Android devices would support the exact same set of OpenGL ES extensions, or that they’d all support the exact same version of OpenGL ES.

    Framebuffer objects (FBOs) are a part of the OpenGL ES 2.0 core specification; if your android device supports ES 2.0, then it supports FBOs.

    If your android device supports ES 1.1, then check the extension string for GL_OES_framebuffer_object using glGetString(GL_EXTENSIONS).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to write an android app that basically layers an overlay on
I've made a couple of apps for android, but none used graphics that much.
I'm trying to write an iPhone app that takes PNG tilesets and displays segments
I'm looking for a 3D graphics library for a Java web app. Could use
I'm trying to write a simple painting app for iOS as a first non-trivial
Back Story: I was approached to write an app, but iOS isn't something that
You write a function and, looking at the resulting assembly, you see it can
I write my app in VS 2008 and so use all the fanciful stuffs
Please write a list of tasks that a copy constructor and assignment operator need
I write a large static method that takes a generic as a parameter argument.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.