opengl-es-2.0

GLEW is just and extension library or it contains OpenGL ES 2.0 implementation as well?

南笙酒味 提交于 2020-01-05 15:14:41
问题 GLEW is just and extension library or it contains OpenGL ES 2.0 implementation as well? The OpenGL Extension Wrangler Library (GLEW) is a cross-platform open-source C/C++ extension loading library. GLEW provides efficient run-time mechanisms for determining which OpenGL extensions are supported on the target platform. OpenGL core and extension functionality is exposed in a single header file. I am confused as I find the following in glew.h : #define glLinkProgram GLEW_GET_FUN(_

Are CVOpenGL[ES]TextureCaches incompatible with floating point formats?

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-05 13:50:53
问题 On OSX10.4/iOS5 and onwards you can optimize your texture uploads and downloads using CVOpenGL[ES]TextureCaches . Instead of uploading textures with glTexImage2D and reading from the frame buffer with glReadPixels , you use a CVOpenGL[ES]TextureCache to translate your texture/FBO operations into the language of CoreVideo CVPixelBuffers . This works perfectly well with byte (and probably short) sized integer formats, but, apart from a fancy YUV pixel format, floats are decidedly under

Drift in rotation about z-axis

删除回忆录丶 提交于 2020-01-05 07:17:12
问题 In an application, while trying to rotate an object using touch, I noticed drift in position of object after sometime (without any translation applied !!). The rotation is only about z-axis and works perfectly, but drift happens only after few rotations. ds will be used for translation (using up-down button). _uNozzleCentreMatrix and _ModelMatrixNozzle will use ds if I correct this. private static final float[] _uNozzleCentre = new float[]{0.0f, 0.333605f, 0.0f, 1.0f}; protected static float[

Drift in rotation about z-axis

我是研究僧i 提交于 2020-01-05 07:17:08
问题 In an application, while trying to rotate an object using touch, I noticed drift in position of object after sometime (without any translation applied !!). The rotation is only about z-axis and works perfectly, but drift happens only after few rotations. ds will be used for translation (using up-down button). _uNozzleCentreMatrix and _ModelMatrixNozzle will use ds if I correct this. private static final float[] _uNozzleCentre = new float[]{0.0f, 0.333605f, 0.0f, 1.0f}; protected static float[

Maximum texture creation/deletion in Android OpenGL ES 2.0

余生长醉 提交于 2020-01-05 07:11:42
问题 I'm writing a game in native code and all graphics is done with OpenGL ES 2.0. I've tried sparing with the texture usage by repeatedly creating them and deleting when they're not needed (with glDeleteTextures). I noticed that the OpenGL will never reuse same texture id anyway and after exactly 192 texture creations the android screen turns white, (first partially, next load makes it fully) and it does not recover except by releasing app focus and getting it back. Is this a bug or feature?

OpenGL ES 2.0 textures for retina display?

Deadly 提交于 2020-01-05 05:27:42
问题 I have got a GLKView, where I try to draw a couple of cubes and I create textures from a view and map them onto the cubes. However, when I start the app on a retina device, the textures are correctly sized but they look terrible. I have tried to set the contentScaleFactor of the GLKView to the scale of the main screen - to no avail. I have also tried to multiply the the buffers dimensions by the scale, which resulted in textures that looked crisp, but were only 1/4 of the original size...

OpenGL ES 2.0 lighting not working in iOS app

余生长醉 提交于 2020-01-05 04:31:08
问题 I am currently learning OpenGL 2.0 and Im creating a basic iPhone app. I have created a model in blender and have exported it to a .obj file and have written a parser that pulls in the co-ordinates. The shape displays fine but with no colour (its black). This implies that there is something wrong with the normals. But I have check the normals and ant find anything wrong with them. Is there something missing from my code? I would be ever so grateful for any help with this! Screen shot here is

OpenGL ES 2.0 :glReadPixels() with float or half_float textures

╄→гoц情女王★ 提交于 2020-01-04 05:09:29
问题 I am writing an OpenGL ES 2.0 app for the iPhone (iOS 4.1). At the end of the computations, which are done in the shaders, i need to write back some data to the CPU. As far as I know this can be done by glReadPixels(). In order to keep precision, i want to use half_float or float textures between the shaders, which seem to be supported by extensions. Question: Is it possible to read float or half_float textures with glReadPixels() ? Thanks, Lars 回答1: I have faced up to this problem either.

GLES 2 Android Emulator

荒凉一梦 提交于 2020-01-04 02:29:08
问题 I keep on getting this error when trying to run an OpenGLES 2 application on the emulator it is running 4.0.3 with gpu emulation enabled: Failed to create Context 0x3005 emulator: WARNING: Could not initialize OpenglES emulation, using software renderer. could not get wglGetExtensionsStringARB could not get wglGetExtensionsStringARB could not get wglGetExtensionsStringARB could not get wglGetExtensionsStringARB could not get wglGetExtensionsStringARB could not get wglGetExtensionsStringARB

glkview drawinrect delegate method called only once

≯℡__Kan透↙ 提交于 2020-01-03 15:33:43
问题 I am trying to add GLKViewController to my UserInterfaceViewController.I am using the example project from raywenderlich tutorials(http://www.raywenderlich.com/5235/beginning-opengl-es-2-0-with-glkit-part-2) Here is my code snippet #import <UIKit/UIKit.h> @interface UserInterfaceViewController : UIViewController @end @implementation UserInterfaceViewController - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { self = [super initWithNibName:nibNameOrNil bundle