¡@

Home 

2014/10/15 ¤U¤È 10:09:50

iphone Programming Glossary: gl_texture_2d

OpenGL ES Render to Texture

http://stackoverflow.com/questions/1024603/opengl-es-render-to-texture

textureFrameBuffer attach renderbuffer glFramebufferTexture2DOES GL_FRAMEBUFFER_OES GL_COLOR_ATTACHMENT0_OES GL_TEXTURE_2D texture.name 0 unbind frame buffer glBindFramebufferOES GL_FRAMEBUFFER_OES 0 Every time I want to render to the texture..

OpenGL ES 2d rendering into image

http://stackoverflow.com/questions/10455329/opengl-es-2d-rendering-into-image

kCFAllocatorDefault rawDataTextureCache renderTarget NULL texture attributes GL_TEXTURE_2D GL_RGBA opengl format int imageSize.width int imageSize.height GL_BGRA native iOS format GL_UNSIGNED_BYTE.. empty glBindTexture CVOpenGLESTextureGetTarget renderTexture CVOpenGLESTextureGetName renderTexture glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE glFramebufferTexture2D.. renderTexture glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE glFramebufferTexture2D GL_FRAMEBUFFER GL_COLOR_ATTACHMENT0 GL_TEXTURE_2D CVOpenGLESTextureGetName..

fastest way to draw a screen buffer on the iphone

http://stackoverflow.com/questions/2395650/fastest-way-to-draw-a-screen-buffer-on-the-iphone

method I got 17fps... I used a 512x512 texture because it needs to be a power of two just the call of glTexSubImage2D GL_TEXTURE_2D 0 0 0 512 512 GL_RGBA GL_UNSIGNED_BYTE baseWindowGUI GetBuffer seemed pretty much responsible for ALL the slow down. commenting..

Rendering to non-power-of-two texture on iPhone

http://stackoverflow.com/questions/4760174/rendering-to-non-power-of-two-texture-on-iphone

should then be able to use non power of two textures as long as you set the proper texture wrapping glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE Unfortunately this example.. you set the proper texture wrapping glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE Unfortunately this example application that I have which renders to a non power of two..

iOS CVImageBuffer distorted from AVCaptureSessionDataOutput with AVCaptureSessionPresetPhoto

http://stackoverflow.com/questions/6540710/ios-cvimagebuffer-distorted-from-avcapturesessiondataoutput-with-avcapturesessio

CVPixelBufferGetWidth cameraFrame glClear GL_COLOR_BUFFER_BIT glGenTextures 1 videoFrameTexture_ glBindTexture GL_TEXTURE_2D videoFrameTexture_ glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MIN_FILTER GL_LINEAR glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MAG_FILTER.. GL_COLOR_BUFFER_BIT glGenTextures 1 videoFrameTexture_ glBindTexture GL_TEXTURE_2D videoFrameTexture_ glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MIN_FILTER GL_LINEAR glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MAG_FILTER GL_LINEAR glTexParameteri GL_TEXTURE_2D.. GL_TEXTURE_2D videoFrameTexture_ glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MIN_FILTER GL_LINEAR glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MAG_FILTER GL_LINEAR glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameteri GL_TEXTURE_2D..

Faster alternative to glReadPixels in iPhone OpenGL ES 2.0

http://stackoverflow.com/questions/9550297/faster-alternative-to-glreadpixels-in-iphone-opengl-es-2-0

kCFAllocatorDefault coreVideoTextureCache renderTarget NULL texture attributes GL_TEXTURE_2D GL_RGBA opengl format int videoSize.width int videoSize.height GL_BGRA native iOS format GL_UNSIGNED_BYTE.. glBindTexture CVOpenGLESTextureGetTarget renderTexture CVOpenGLESTextureGetName renderTexture glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE glFramebufferTexture2D.. renderTexture glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_S GL_CLAMP_TO_EDGE glTexParameterf GL_TEXTURE_2D GL_TEXTURE_WRAP_T GL_CLAMP_TO_EDGE glFramebufferTexture2D GL_FRAMEBUFFER GL_COLOR_ATTACHMENT0 GL_TEXTURE_2D CVOpenGLESTextureGetName..