opengl-es

What versions of GLSL can I use in OpenGL ES 2.0?

风格不统一 提交于 2019-12-12 07:10:04
问题 I can't seem to find a clear answer on this, despite hours of googling. Can someone just tell me what's going on? I get errors saying things like, "version 140 is not supported." Is this my device (Kindle Fire) or GL ES 2.0? Do I need to add libraries or anything? 回答1: you actually don't have to add any libraries, 140 is far too new for Kindle Fire. Either remove the version specification or decrement it until the shader compiles. You may need to fix some other errors in the shader as the

EGL_emulation failed to establish connection to host - android

我的未来我决定 提交于 2019-12-12 07:08:47
问题 I am trying to run a simple OpenGL program in Android. I am running this in an Android 4.1 emulator. I switched on its GPU emulation and it worked fine yesterday. When I ran that today, initially it was hanging saying, OpenGL taking time to render - Wait or Close dialog box . After few runs again it was crashing saying E/EGL_emulation(2637): Failed to establish connection with the host followed by 11-30 11:48:10.787: E/AndroidRuntime(2637): FATAL EXCEPTION: main 11-30 11:48:10.787: E

iPhone:Open-gl to start with..?

我与影子孤独终老i 提交于 2019-12-12 06:22:38
问题 I am developing several iPhone applications using UIKit. I want to learn and develop a simple and rich graphics iPhone game application using Open-gl library quickly. I googled it and got some links like below. http://maniacdev.com/2009/04/8-great-resources-for-learning-iphone-opengl-es/ But i want to hear from you experience people if you have any suggestions, please give me the link/any other resource where i can start with to create a simple and rich graphics game using open-gl for iPhone.

Android Camera Frame Rendering

穿精又带淫゛_ 提交于 2019-12-12 06:04:47
问题 I am trying to render my camera frames in Android and make use of canvas,bitmap,onDraw() to display the frames on my Surfaceview. However my code performance which does the rendering on the Native side is taking up to 70% of my cpu. The rendering speed is good but CPU consumption is bad.The problem is that I have another overlaying surfaceview(surfaceview2) to display something else while I am rendering and capturing camera. I was wondering how may I reduce the cpu consumption and make use of

timer driven or endless loop update?

对着背影说爱祢 提交于 2019-12-12 05:57:21
问题 I've been perplexed for a while, whether to run the rendering loop in an endless loop or whether to drive it with a timer (say, a 60 Hz timer). The endless loop seems a good idea, but I am worried it might leech a battery on portable devices faster than the timer approach. In general, consume more energy. I've seen both approaches used in practice, but can't decide on the positive and negative points of them. Can you please help me decide? Perhaps most portable devices are too primitive to

opengl GL.GetUniformLocation always returns ZERO (0)

元气小坏坏 提交于 2019-12-12 05:51:02
问题 Am using OpenGL ES30 with Xamarin/C#. My issue is that no matter what I do, when I call: OpenTK.Graphics.ES30.GL.GetUniformLocation(progID, "varName"); It ALWAYS returns ZERO. (not -1). The following statements all return 0: int RRRRRRRR = GL.GetUniformLocation(Terrain3D.TileShader.Id, "NOTVALIDNAME"); RRRRRRRR = GL.GetUniformLocation(-1, "ALSONOTVALID"); RRRRRRRR = GL.GetUniformLocation(-1, "BOGUSZZZZ"); RRRRRRRR = GL.GetUniformLocation(-1, ""); These are all bogus values (even for Program

How to enable skia with GPU backend on JB

ぐ巨炮叔叔 提交于 2019-12-12 05:29:34
问题 I heard Skia GPU acc was added in Android 3.0 but seems it was default disabled since Android 4.0 probably because of the shift to HWUI (openGL implementation of Canvas). How could I enable that again just for benchmark purpose. 回答1: I am unaware of any other method of hardware acceleration of Skia. Though for HWUI the developers documentation outlines this here: http://developer.android.com/guide/topics/graphics/hardware-accel.html Apologies if you are already aware of the implementation of

How to disable or configure clipping when rendering to texture using FBO in OpenGL?

泪湿孤枕 提交于 2019-12-12 05:24:54
问题 I have a question about the way the FBO clips the visible scene. All this happens in iPhone's OpenGL ES. I'm rendering in 2D and using render-to-texture with FBO. I find that when any part of the scene passes any side of the rectangle of screen size (480*320) that it appears clipped from the FBO generated texture. Why does it do that? How do I disable or configure it? I've tried disabling scissor test by lDisable(GL_SCISSOR_TEST); I've tried to set up needed section by `glEnable(GL_SCISSOR

iOS. OpenGL. Several views simultaneously

Deadly 提交于 2019-12-12 05:16:53
问题 a couple of days before i asked about filling space between two curve lines with gradient. Since that i've changed a lots of in my code - now i'm using shaders. The result is almost as i need. BUT! Again i have a problem with using several OpenGL views simultaneously in one controller but they must be absolutely independent between each other. So, thanks to unbelievable tutorial from raywenderlich.com and code example from bradley i have next situation: two custom objects of class

How is it possible to pause an action of an actor in LibGDX?

╄→尐↘猪︶ㄣ 提交于 2019-12-12 05:03:59
问题 I added the following action to my actor: this.addAction(sequence(delay(0.5f), alpha(1, 2), delay(2), alpha(0, 2))); Is there an easy way to pause this animation and then continue it when a button is clicked? 回答1: If your actor is only running action, I suggest to stop calling the act() method of the actor. Extend Actor to set a switch if needed. public void act(){ if(mUpdateAnimation){ this.act(delta) } } 回答2: Although the above answer is accepted, but when I tried the above solution, the