Subset of the OpenGL 3D graphics API designed for embedded devices such as mobile phones.

learn more… | top users | synonyms

0
votes
1answer
21 views

Point rotation around point, accuracy question

i study OpenGL ES 2.0. But it think it's more C++ question rather then OpenGL. I'am stuck with rotation question. It is known, that rotation transformation can be applied using this equations (for ...
2
votes
1answer
2k views

Android OpenGL ES RENDERMODE_WHEN_DIRTY implementation

I am trying to understand RENDERMODE_WHEN_DIRTY so that I could save battery life wherever possible.. I made this sample application so that GlSurfaceView is updated with random color only when the ...
6
votes
1answer
123 views

OpenGL 2.0 - Texture animation with 'pixelated' effect

I'm looking for a way to reproduce the effect I've tried to sketch in the image below with OpenGL ES 2.0. The idea is to let a drop of color fall over a cube which get filled with a kind of ...
6
votes
1answer
296 views

OpenGL ES object rotation around z axis

I have an object on my screen which is presented rotated and panned, But i have 2 problems regarding the z axis rotations. It's a bit tricky to explain so i uploaded 2 videos to describe each problem. ...
0
votes
1answer
30 views

Is ETC2 Texture Compression available in OpenGL ES 2.0?

However, I have an ES 2.0 app and would like to use ETC2 texture compression if it is available (i.e. I am running on a device that supports ES 3.0 standard). Is it possible to use ETC2 in ES ...
0
votes
1answer
624 views

Rendering Texture Quad to Screen or FBO (OpenGL ES)

I need to render the texture on the iOS device's screen or a render-to-texture frame buffer object. But it does not show any texture. It's all black. (I am loading texture with image myself for ...
2
votes
1answer
224 views

How to outline a 3D object with a cartoon style stroke? [duplicate]

How could I draw (stroke) the outline of a 3D object in a cartoon style with GLKit? I'm referring to something like this: However we can start with a simple line around the object and then try to ...
3
votes
2answers
1k views

Cocos2D: Upgrading from OpenGL ES 1.1 to 2.0

I have recently starting upgrading my ios game to the latest Cocos2D (2.0 rc), and I am having some difficulties upgrading my texture generation code to OpenGL 2.0. In the old version I generated ...
3
votes
1answer
632 views

How do I clip an image in OpenGL ES on Android?

My game involves "wiping off" an image by touch: After moving a finger over it, it looks like this: At the moment, I'm implementing it with Canvas, like this: 9Paint pTouch; 9int X = ...
1
vote
1answer
229 views

2D map/plane with nodes overlayed that supports panning, scaling and clicking on nodes

I'm trying my hand at Android development and seem to be running into an invisible ceiling in trying to get what I want accomplished. Basically I'm trying to create an app that renders a 2D surface ...
0
votes
0answers
46 views

How can I use a Seekbar as a brightness slider?

I am using the GLSurfaceView Renderer. I want changes to a seek bar's progress to increase the brightness of a GLSurfaceView proportionally. How do I apply a color matrix to a GLSurface view? Is ...
2
votes
1answer
96 views

How do I apply a texture over a material in OpenGL ES?

How can I apply a texture over a material? I've set up an object with the following material: GLKBaseEffect *effect; effect.colorMaterialEnabled = false; effect.material.ambientColor = ...
1
vote
1answer
131 views

Decoupling rendering pipeline (for UI responsiveness): Multithreading and multiple contexts?

Warning! Wall of text (see <TL;DR> paragraphs below for short version) I have been noticing something in quite many games (most recently in cutting-edge RTS games such as Uber Entertainment's ...
1
vote
0answers
93 views

iOS OpenGLES - Multithread Game loop - Render and Update

I am trying to implementing multi-threaded game loop in iOS. (Actaully, two thread - Render and Update) This is my structure. Update Loop Has logic and at the end of loop, save update state. ...
1
vote
1answer
107 views

Android Object get Jagged at the border

I am new to OpenGL ES 1 in android. My 3D Model border getting Jagged. Please help me to look like a smooth border instead of jagged. Screenshot : http://i.stack.imgur.com/1Gq83.png private class ...
0
votes
2answers
41 views

Texture size and scaling, 2D, for OpenGl ES 1.0/1.1

I read everywhere that you have to use a power of two size for your texture width and height, like 16, 32 or 64, but right now my sprite drawing is based on Grid.java from SpriteMethodTest, and I set ...
0
votes
0answers
16 views

Trying to use Sprite Batching with GL_COLOR_ARRAY in OpenGl ES 1.0/1.1

I'm trying to create a sprite batcher that uses GL10.GL_COLOR_ARRAY using OpenGl ES 1.0/1.1 on Android. I found two different sources that seem like they would work, they both have statements that ...
0
votes
1answer
65 views

“Quad” background showing on OpenGl ES 1.0/1.1 Sprites

I modeled my sprite drawing on Grid.java and GLSprite.java from SpriteMethodTest, using 2D OpenGl ES 1.0/1.1 on Android, but the "quad" sprite background shows when two sprites overlap each other. ...
2
votes
1answer
74 views

Texture mapping a complex object on openGL ES

I dont have much experience with openGL ES (or openGL), but i do get the general idea of texture mapping, which is each vertex should be mapped for the relevant UV coordinates of the texture we choose ...
0
votes
0answers
67 views

How do I “reset” the color in OpenGl ES 1.0/1.1?

In my 2D game I use glColor4f() to set the color and draw my screen border rectangles but when I try to start drawing my game objects, made up of a texture on a rectangular "quad", using ...
2
votes
1answer
171 views

How do I draw an animated object in OpenGL ES?

I have a VBO, which I initialise like this (just an example): - (void)setupVBOs { GLuint vertexBuffer; glGenBuffers(1, &vertexBuffer); glBindBuffer(GL_ARRAY_BUFFER, vertexBuffer); ...
4
votes
3answers
416 views

How long does it take for OpenGL to actually update the screen?

I have a simple OpenGL test app in C which draws different things in response to key input. (Mesa 8.0.4, tried with Mesa-EGL and with GLFW, Ubuntu 12.04LTS on a PC with NVIDIA GTX650). The draws are ...
0
votes
1answer
154 views

libgdx game process dies on loading texture atlases

I try to load a lot of texture atlases (10) with approximately 5 (~2048x~2048)(not using PoT) .pngs each. I'm using AssetManager and there is no trouble with it on my pc but when I try it on my tablet ...
2
votes
2answers
478 views

OpenGL texture on sphere

I want to create a rolling, textured ball in OpenGL ES 1.0 for Android. With this function I can create a sphere: public Ball(GL10 gl, float radius) { ByteBuffer bb = ...
2
votes
1answer
133 views

Color bleed on voxel edges when using anti-aliasing

My Minecraft-like game uses a texture containing four block IDs in each pixel (RGBA). These IDs are used in the shader to determine what color each whole block should be. I'm having an issue with ...
1
vote
0answers
72 views

iPhone 5S - GLSL problem [closed]

I have this shader precision highp float; precision highp int; attribute vec4 POSITION; attribute vec2 TEXCOORD0; attribute vec2 TEXCOORD1; attribute vec2 TEXCOORD2; attribute vec2 TEXCOORD3; ...
4
votes
1answer
134 views

GetData() error creating framebuffer [closed]

I'm currently porting a game written in C# with XNA library to Android with Monogame. I have a Texture2D and i'm trying to get an array of uint in this way: Texture2d textureDeform = ...
1
vote
1answer
194 views

How can I rotate a tile map (and all of it's individual tiles) around an arbitrary point? [duplicate]

I have a 3D tile map made up of individual billboards in OpenGL ES. Each tile is a two-triangle mesh with a 3D vector to determine position and another defining rotation. How can I rotate the entire ...
1
vote
1answer
199 views

Are interleaved vertex data formats better than non-interleaved formats?

I have been reading up on data formatting for 3D objects so that I can render my meshes as fast as possible in OpenGL. I am quite new to OpenGL so bear with me. The format for interleaving your ...
1
vote
1answer
117 views

How can I handle errors when there is no valid OpenGL context?

I'm writing cross-platform (iOS, Android, OSX, Windows) library code that draws its output using OpenGL. I expect my users will often try to call my library's rendering functions without a valid ...
1
vote
0answers
72 views

How to load all textures at startup in my game?

In my Android 2D game every level uses the same textures. Currently all my textures are loaded into memory in the onSurfaceCreated() method of my GLSurfaceView.Renderer when a level is choosen by ...
2
votes
4answers
2k views

Setting up OpenGL camera with off-center perspective

I'm using OpenGL ES (in iOS) and am struggling with setting up a viewport with an off-center distance point. Consider a game where you have a character in the left hand side of the screen, and some ...
3
votes
2answers
389 views

Identity matrix. Confusion. What does it really do

I understand identity matrix is like multiplying to 1. But i can't really understand why would you multiply an a matrix that will only result to the same. Also im messing up with an OpenGL code and ...
8
votes
1answer
544 views

what is world space and eye space in game development?

I'm reading a book about 3D stuff and OpenGL. The book often talks about world space and eye space. What exactly is the "world space?" Does the "eye space" mean the projection?
0
votes
1answer
172 views

What is Opengl ES ? What is gl and GLES20 mean?

I am new in opengl. I saw tutorial some have gl at the beginning and some have GLES20 at the beginner and some has GL10. What are the differences? Is GLES20 mean opengl es2 whereas GL10 mean version ...
-1
votes
3answers
235 views

OpenGL ES - read content of VBO

Is it possible to read back content of VBO in OpenGL ES 2.0 ? I have tried glMapBufferOES, but there is no READ flag. I dont want any answers, like "you shouldnt do it" or "keep copy of geometry in ...
2
votes
1answer
235 views

What is the correct and most efficient approach of streaming vertex data?

Usually, I do this in my current OpenGL ES project (for iOS): Initialization: Create two VBO's and one IndexBuffer (since I will use the same indices), same size. Create two VAO's and configure ...
1
vote
1answer
129 views

Pixmaps, ByteBuffers, and Textures…Oh my

My ultimate goal is to take a specific region of the screen, and redraw it somewhere else. For example, take a square from the upper left hand corner of the screen and redraw it on the lower right ...
1
vote
1answer
416 views

How to use mipmap in OpenGL-ES

I have recently entered in the OpenGL world. I am very pleased with the performance that I got with opengl compared to those obtained with a SurfaceView and its canvas. At the same time because of the ...
2
votes
1answer
299 views

OpenGL slower than Canvas

Up to 3 days ago I used a Canvas in a SurfaceView to do all the graphics operations but now I switched to OpenGL because my game went from 60FPS to 30/45 with the increase of the sprites in some ...
0
votes
1answer
83 views

How do I load BSP files in Android?

I understand that Opengl directly cannot load BSP files. How would I go about loading them into my Android game?
0
votes
1answer
1k views

How to do frame by frame animation in android using open gl es

I have application in some part i am using AndroidDrawable for animation but it giving jerking effect that why i planed to change the code to Open Gl ES for better performance .so far i have googled ...
7
votes
1answer
795 views

Optimizing performance of a heavy fragment shader

I need help optimizing the following set of shaders: Vertex: precision mediump float; uniform vec2 rubyTextureSize; attribute vec4 vPosition; attribute vec2 a_TexCoordinate; varying vec2 tc; ...
0
votes
0answers
140 views

Error when create FrameBuffer: GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS

I'm using libgdx, to create some program. I need used some operation in framebuffer. For this operation I create new framebuffer, after this operation I'm call in framebuffer dispose(). When I create ...
1
vote
1answer
311 views

rendering transparent meshes in LibGDX

Building open this tutorial - https://code.google.com/p/libgdx/wiki/ProjectionViewportCamera I have constructed a class for generating polygon meshes. But i cannot figure out how to render semi ...
1
vote
1answer
450 views

how to make cross platform 3d games using modern opengl? [closed]

How to create games that run on windows, Linux, mac os x, android, ios, wp8 etc.... using c/c++, opengl 3 or 4 and opengl es 2.0. any tutorials or videos on how to create cross-platform 3d games.
3
votes
1answer
457 views

Sprite sheet textures picking up edges of adjacent texture

I have a custom sprite routine (openGL 2.0) which uses a simple sprite sheet (my textures are arranged horizontally next to each other). So, for example, here is a test sprite sheet with 2 simple ...
-2
votes
2answers
126 views

In OpenGL, how to confirm a primitive is rendered properly

I have to confirm that a primitive (say triangle) is rendered properly in opengl. I can use the glGetError() after a opengl draw calls(glDrawElement/glDrawArrays) Is it enough to confirm ? Is there ...
1
vote
0answers
58 views

OpenGL ES - jagged edge [duplicate]

I need to render roads and some direction marks on top of them. I render roads as triangled geometry, same goes for marks (see picture - road is purple, mark is red, ignore z-fighting). Problem goes ...
0
votes
1answer
132 views

How to set tranparency for one image only in openGL ES in Android?

I code game on Android where I have several sprites. My goal is to set gl.glColor4f(1f, 1f, 1f, 0.2f) a.e. transparency only for specific image. (I don't like Photoshop). In my case its image that ...