Options for offscreen rendering on Android with OpenGL ES 1.0? -


i'm working on implementing picking opengl game i'm writing android. it's using "unique color" method of drawing each touchable object solid color unique each object. user input reads glreadpixels() @ location of touch. i've gotten coloring working, , glreadpixels working, have been unable separate "color" rendering main actual rendering, complicated use of glreadpixels.

supposedly trick working render second scene (for input) offscreen buffer, seems bit problematic. i've investigated using opengl es1.1 fbo's act offscreen buffer, seems handset (samsung galaxy s vibrant (2.2)) not support fbo's. i'm @ loss how correctly render scene (and run glreadpixels on it) without user witnessing it.

any ideas how offscreen rendering of sort can done?

if fbo not supported, can resort rendering normal back-buffer.

typical usage be:

  • clear back-buffer
  • draw "color-as-id" objects
  • clear back-buffer
  • draw normal
  • swapbuffers

the second clear make sure picking code not show on final image.


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -