Questions tagged [opengl-es]

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

Filter by
Sorted by
Tagged with
0 votes
1 answer
50 views

The performance gains of tiled rendering on mobile

I'm making an OpenGL es app on android and I'm trying to improve the performance of it. I found this technique called tiled rendering (not the same thing as tiled deffered rendering*) wich divides the ...
user avatar
  • 5
0 votes
0 answers
14 views

Trying to write to GL_R16UI buffer, but everything is zero

I've written some render data to an offscreen RGBA texture, and it works. However, I don't need a full 32 bits to hold this data, so I wanted to convert to a 16-bit buffer where I can just write ...
user avatar
0 votes
0 answers
83 views

What's the solution to this kind of shadow acne?

I'm working with a OpenGL ES/GLSL homebrew engine my company developed, in C++. Below is a screenshot of it rendering shadow acne. The light's direction is too perpendicular to the face of the curve ...
user avatar
0 votes
0 answers
25 views

Opengles glBindBufferBase has weird performance issue

I am now doing some optimization for rendering process. I notice that in my game some objects is totally static and never changed. In my old way, I will create a uniform buffer every frame, and put ...
user avatar
0 votes
1 answer
64 views

How to update constant buffer patially in OpenGLES

I am wondering what does glMapBufferRange actually do? I am accessing my constant buffer like this way: ...
user avatar
0 votes
0 answers
19 views

handling obj file without normal [duplicate]

I am trying to build an obj file loader and I have written code to read an obj file with face f with v/vt/vn - vertex, texture coordinate, and normal. While going through the obj file, there are so ...
user avatar
1 vote
0 answers
577 views

OpenGL Compute Shader vs Fragment Shader device support

I have a game with massively parallelizable logic, which I intend to write calculate on the GPU (Java/LibGDX). I am planning to implement a logic for it through a fragment shader, instead of a compute ...
user avatar
2 votes
1 answer
546 views

Any fast alternative to sine in GLSL?

Should I just use the built-in sin() function or my custom sine function? I'm concerned about performance here. I don't care about accuracy much here because I use it to just get wave effects in my ...
user avatar
0 votes
0 answers
43 views

Cuda API to render using Physically Based Rendering (PBR) in OpenGL-ES based project

I need to develop a OpenGL-ES based application to render a model using Physically based Rendering (PBR). Do I need to use Cuda API to render the computation intense PBR rendering? Is there any ...
user avatar
  • 115
0 votes
1 answer
88 views

OpenGL GLSL ES 3.10 - Referencing a uniform variable, causes the vertex shader to not draw anything

I have this project, that has a default shader, that just draws models and textures. Recently I decided to add a second shader that does a fancy effect, and is used only on some of the objects drawn. ...
user avatar
  • 4,218
1 vote
1 answer
52 views

Bind render result to texture id

I want to save the result screen of the rendering and then apply another shader on that result, the typical way is to read the screen using glReadPixels and then buffer that image to gpu and then ...
user avatar
0 votes
0 answers
30 views

NDK opengl-es unknown error

Projection matrix? Renderer? Where is the error? I recently started studying NDK to create better performing android games ... but ... An error I didn't expect to deal with appeared a few weeks ago ...
user avatar
  • 21
1 vote
0 answers
59 views

OpenGL ES - render to texture - how to preserve original depth buffer

I render to texture and attach my own depth buffer that has texture target. However, after I finish rendering I would like to set original depth buffer back. To start rendering to texture I do: ...
user avatar
  • 1,086
1 vote
1 answer
148 views

Why do I have additional glBindBuffer() calls?

I have a OpenGL2/OpenGLES2 application and it among others renders a sphere using the following pseudocode: Update vertices data on CPU call glBufferSubData(GL_ARRAY_BUFFER, ...) to update them on ...
user avatar
1 vote
0 answers
104 views

Techniques for cursor snap-to-vertex in WebGL or OpenGL?

What's a technique for snapping the mouse pointer to vertices in WebGL or OpenGL? All I need is the vertex position, no other info. Ideally, I'd like to do this without needing to keep positions and ...
user avatar
  • 147
0 votes
1 answer
383 views

How can I fix the artifacts near the shadow edges in my variance shadow map?

I'm trying to implement variance shadow mapping in my engine. I'm using WebGL 2 and now I have only one directional light source. It's working, but it has a serious issue near the shadow edges and I ...
user avatar
  • 31
0 votes
2 answers
147 views

OpenGL ES model loader is slow?

I'm trying to load a 3D model in OpenGL ES, and I managed to find a project on "sourceForge" that can do this job. When I downloaded it and played the app, it took 50 second to load a small object (...
user avatar
  • 11
3 votes
2 answers
1k views

How to preserve EGL context when pausing Android ndk app

I am trying to improve openframeworks so that the GL context is preserved when pausing and resuming my game. So that I don't have to reload all textures after each pause. I don't expect you to know ...
user avatar
  • 61
0 votes
1 answer
97 views

OpenGL ES, object intersection artifacts

I was developing a C++ implementation of OpenGL for Android and I noticed those weird artifacts that formed between 2 intersecting objects (or triangles) : [Here are the artifacts on Android] The ...
user avatar
0 votes
0 answers
102 views

How do i update opengl lightning equation in my fragment shader to make my texture less glossy and more like a fabric

I built a model in blender, and am currently trying to import it into my android app using assimp together with opengl, i dont have any issues with the importing but my goal is to make the object look ...
user avatar
  • 101
0 votes
1 answer
198 views

PVRCT Texture Format with glTexStorage2D on Open GL 3.0 ES How?

I've looked everywhere and I can't seem to find the answer. How can I use glTexStorage2D with PVRCT textures? I've done this: ...
user avatar
  • 1
0 votes
2 answers
479 views

Rotating a Quad in Shader

I'm working Opengles2 and I have a just a texture ID and a quad from an SDK and its shader, and I can not access their code, just the vertex and pixel shader. The quad from the SDK is rotated and ...
user avatar
1 vote
2 answers
303 views

Draw text in OpenGL ES 3D game?

I am making a game using OpenGL ES 1.0 and I want to keep player score. So I need to draw text dinamically. What is the best approach? Some library, textures, bitmaps? I tried to use TextView but ...
user avatar
  • 11
3 votes
2 answers
1k views

How to make the camera follow the player in Libgdx?

In Play class I have the viewport of game height=320 and game width=240unitswith camera cam. I have set the camera(cam) viewport width to 10 and viewport height to 7.I have another camera hud whose ...
user avatar
  • 35
2 votes
1 answer
792 views

How to associate multiple arrays of vertex data and uv data with an attribute? OpenGL ES

I create the buffers to to put on them the vertex data and uv data: ...
user avatar
2 votes
1 answer
39 views

How to transform only part of an array in OpenGL ES?

I have one texture atlas of which I select the "non-animated textures", I put all vertex and UV coordinates in two array: ...
user avatar
0 votes
1 answer
584 views

Black screen when trying to render multiple textures

I generate an array for two textures: ...
user avatar
0 votes
1 answer
154 views

OpenGL ES texture rendered not as expected with disproportional aspect ratio triangles

I cannot seem to understand how texture coordinates work. I try to render a texture into two triangles and this is what I get Where the expected output is a normal continuous image as you can imagine....
user avatar
3 votes
1 answer
461 views

OpenGL ES 2.0 cannot understand how to use 2D ortho projection and shaders

I am migrating an app that draws on OpenGL ES 1.0 to OpenGL ES 2.0. The app used to draw multiple 2D triangles, as a vertex array, where the vertices matched the pixels on screen. I made a sample ...
user avatar
0 votes
1 answer
179 views

Issues to display a texture loaded with libPNG with opengles 3.0

I'm trying to load a texture loaded with libPNG on a XY coordinates. I know the width and the height of the texture (32x32). The texture is already loaded successfully and I have his Id. Here is my ...
user avatar
0 votes
0 answers
59 views

Rendering artifacts on edges in Cardboard VR OpenGL ES 2

Unity beginner here. I've encountered this weird rendering artifacts in my Cardboard VR app on Android OpenGL ES 2: https://youtu.be/uJm4d3MwbRo It doesn't occur in WebGL build: http://senovsky.wz.cz/...
user avatar
2 votes
3 answers
1k views

What are "free vertex indices" in WebGL 2 and how do they relate to geometry shaders?

In January Notch tweeted about WebGL 2: WebGL 2 is happening. Bye, compatibility! Hello, 3d textures and pixel buffers! oh god it's got free vertex indices in the shader. That is basically a geometry ...
user avatar
  • 23
1 vote
1 answer
94 views

Texture does not fit the screen

Hi guys I am really new in OpenGL-ES and I am developing a simple android application with NDK, and I just want to ask why the image is not fit after I set the width and height of it. this is my <...
user avatar
1 vote
0 answers
78 views

How to update FBO's depth texture?

I have an FBO with only 16-bit depth attachment: glTexImage2D(GL_TEXTURE_2D, 0, GL_DEPTH_COMPONENT16, w, h, 0, GL_DEPTH_COMPONENT, GL_UNSIGNED_SHORT, nullptr); I ...
user avatar
  • 131
1 vote
2 answers
941 views

Correct normal map for rotated sprites

I am trying to find the best way to correctly do normal mapping in a 2D batched sprite renderer. For each sprite sheet (aka texture atlas) I render all sprites as a textured quads with a single <...
user avatar
  • 131
5 votes
1 answer
208 views

OpenGL self-test in a mobile game

I've made an Android game that uses no/custom game engine. It renders using OpenGL ES 2.0 and optionally uses some extensions for optimization or extra effects. Over the time I have dealt with various ...
user avatar
  • 166
0 votes
1 answer
311 views

GLSL - Stencil buffer - instanced geometry

I have geometry that have attached some "ID" data. I have generated stencil buffer, that holds these IDs. Now, in second pass, I render different geometry, but this time I need to mask it with ...
user avatar
  • 1,086
1 vote
1 answer
112 views

How can I port my Gear VR app (Java, OpenGL ES) to Unity?

I want to port my Gear VR app (created in Java using the official framework) to Unity, so I can also support Microsoft's new-ish VR headsets (not talking about the Hololens!). In my current app I'm ...
user avatar
  • 267
1 vote
3 answers
489 views

Android: 2d scrolling background

I am a very beginner in game development. All I want to achieve in the beginning is a free scrollable background like in a strategy game with my custom graphics. In my case it is supposed to be a 2d ...
user avatar
0 votes
1 answer
306 views

Most efficient way of drawing a lot of cubes OpenGL ES

I have to draw a lot of cubes in my OpenGL programme for android. All the cubes have the same size but different colors. I know that calling glDrawArrays is expensive operation so I should call it ...
user avatar
  • 17
4 votes
1 answer
76 views

How can I simulate a crash of OpenGL in GLKViewController to help track down a user's problem?

I am using GLKViewController for iOS app. On some devices, there are problems (possibly with OpenGL), that I am unable to solve, because I dont see this problem on ...
user avatar
  • 1,086
0 votes
3 answers
2k views

OpenGL ES 2.0 Shadow Mapping - depth only FBO not working due to GL_FRAMEBUFFER_INCOMPLETE_ATTACHMEN

I am trying to add simple shadow mapping to my friends gles 2.0 app. It is based on gles 2.0 and PowerVR SDK. The problem I encounter is that FBO is not valid due to ...
user avatar
1 vote
0 answers
95 views

Android - OpenGL - detect slow GPU

I have app for Android with OpenGL. It uses GPU-heavy effects and on "slow" GPUs this leads to low FPS. Is there a way, how to detect "slow" GPU during app start and disable those effects and generate ...
user avatar
  • 1,086
1 vote
1 answer
253 views

Is Opengl 2.x still usable? [closed]

i've used opengl core profile for a while now and i was wondering if it was possible to create a "decent" application (like a game/game engine) with good graphics. I have a machine which can run only ...
user avatar
0 votes
1 answer
574 views

GLfloat vs GLfixed vs GLint performance in 2017

Some people claim that floats should be used for rendering vertices in modern graphics cards, because graphics cards are optimized for floating-point arithmetic and therefore, integer calculations are ...
user avatar
1 vote
1 answer
506 views

OpenGL ES 1.1: Is it more efficient to use glClear or use glDrawArrays with primitives that render over used frames?

For example, if I have several figures rendered over a black background, is it more efficient to call glClear(GL_COLOR_BUFFER_BIT) each frame, or render black triangles over artifacts from the past ...
user avatar
1 vote
1 answer
7k views

OpenGL calculate UV sphere vertices

I am trying to implement a class Sphere in C++. Therefore I want to calculate the vertices in the constructor of the class (or in a seperate function..). Although ...
user avatar
0 votes
1 answer
72 views

Should I draw a button using a single shape (triangle list) and draw call, or multiple shapes and draw calls (triangle strip and line lists)?

I know this is too simple for performance improvements to make much of a difference, but I find that knowing this information would be simple for many future scenarios. Basically, what I am trying to ...
user avatar
-1 votes
1 answer
3k views

Shader FloodFill Alogrithm

I'm new to openGL and shaders. Is there a way to implement shader algorithms for floodfills? Basically, I have a picture with outlines and i want to fill the insides of where the user touches it
user avatar
1 vote
1 answer
111 views

OpenGL Is High Efficiency For Large Number of Vertices Necessarily Highly Efficient For Low Numbers of Vertices

To test my program, I rendered hundreds of times more vertices than the program will ever actually have (about 5000 vertices total for the exaggerated version). The exaggerated program lagged when ...
user avatar

1
2 3 4 5
10