java - Android OpenGL ES 1.1 Combine Multiple Textures -


i'm developing android game using java, , on trying figure out efficient way of rendering necessary textures. suppose have grid, similar checkers board layout, , tiles fill grid, in each square on board. concept of displayed. currently, drawing each tile 1 one. of texture loading done upon creation , done once, not upon drawing. now, want do. i've noticed drawing 1 one, although fast i'm doing, can glitchy. in game, user has ability drag "board" view different areas. of right now, i'm allowing necessary tiles drawn depending on location of top left visible tile. said, works quite fast, but, once user starts interacting more or dragging faster, rendering starts have difficulties , isn't fast should be. causes little separation in between tiles. it's not large, large enough noticeable. want place each texture in location defined grid, creating new texture containing viewable area, , render entire area opposed render each tile separately. i've done lot of research , looked @ many questions, still have not found cause. i've read rendering texture using framebuffer may help, haven't found easy-to-follow tutorials or examples, lot "here's code, no explanation" or "here's similar want, it's using different things." so, if point me towards tutorial/example, or post valuable answer, grateful. i'm avoiding opengl es 2.0 because want game compatible many devices, , i'm doing, 2.0 not necessary.

for quick summary of code further explanation:

for(go through visible rows){    for(go through visible columns){       drawtile(); //does texture binding , drawing each tile    } } 

what want:

for(go through visible rows){    for(go through visible columns){       loadtiletextureintogridtexture();       //i want combine textures 1 texture    } }  drawgridtexture(); 

doing second way have 1 whole texture render opposed visiblerows*visiblecolumns textures render.


Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

jsf - How to ajax update an item in the footer of a PrimeFaces dataTable? -

django - CSRF verification failed. Request aborted. CSRF cookie not set -