¡@

Home 

2014/10/15 ¤U¤È 10:15:45

iphone Programming Glossary: vertexbuffer

OpenGL ES Simple Undo Last Drawing

http://stackoverflow.com/questions/2708055/opengl-es-simple-undo-last-drawing

GL_FRAMEBUFFER_OES viewFramebuffer I then prepare the vertex array and draw this way glVertexPointer 2 GL_FLOAT 0 vertexBuffer glDrawArrays GL_POINTS 0 vertexCount glBindRenderbufferOES GL_RENDERBUFFER_OES viewRenderbuffer context presentRenderbuffer..

Use of VAO around VBO in Open ES iPhone app Causes EXC_BAD_ACCESS When Call to glDrawElements

http://stackoverflow.com/questions/6240863/use-of-vao-around-vbo-in-open-es-iphone-app-causes-exc-bad-access-when-call-to-g

glEnableVertexAttribArray texCoordSlot glGenVertexArraysOES 1 arrayObject glBindVertexArrayOES arrayObject GLuint vertexBuffer glGenBuffers 1 vertexBuffer glBindBuffer GL_ARRAY_BUFFER vertexBuffer glBufferData GL_ARRAY_BUFFER sizeof Vertices Vertices.. texCoordSlot glGenVertexArraysOES 1 arrayObject glBindVertexArrayOES arrayObject GLuint vertexBuffer glGenBuffers 1 vertexBuffer glBindBuffer GL_ARRAY_BUFFER vertexBuffer glBufferData GL_ARRAY_BUFFER sizeof Vertices Vertices GL_STATIC_DRAW glVertexAttribPointer.. glBindVertexArrayOES arrayObject GLuint vertexBuffer glGenBuffers 1 vertexBuffer glBindBuffer GL_ARRAY_BUFFER vertexBuffer glBufferData GL_ARRAY_BUFFER sizeof Vertices Vertices GL_STATIC_DRAW glVertexAttribPointer positionSlot 3 GL_FLOAT GL_FALSE..

iOS CVImageBuffer distorted from AVCaptureSessionDataOutput with AVCaptureSessionPresetPhoto

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

bufferHeight 0 GL_BGRA GL_UNSIGNED_BYTE CVPixelBufferGetBaseAddress cameraFrame glBindBuffer GL_ARRAY_BUFFER self vertexBuffer glBindBuffer GL_ELEMENT_ARRAY_BUFFER self indexBuffer glDrawElements GL_TRIANGLE_STRIP 4 GL_UNSIGNED_SHORT BUFFER_OFFSET..

Save OpenGL Drawn item as a Image

http://stackoverflow.com/questions/9660723/save-opengl-drawn-item-as-a-image

onscreen based on where the user touches void renderLineFromPoint CGPoint start toPoint CGPoint end static GLfloat vertexBuffer NULL static NSUInteger vertexMax 64 NSUInteger vertexCount 0 count i EAGLContext setCurrentContext context glBindFramebufferOES.. scale self.contentScaleFactor start.x scale start.y scale end.x scale end.y scale Allocate vertex array buffer if vertexBuffer NULL vertexBuffer malloc vertexMax 2 sizeof GLfloat Add points to the buffer so there are drawing points every X pixels.. start.x scale start.y scale end.x scale end.y scale Allocate vertex array buffer if vertexBuffer NULL vertexBuffer malloc vertexMax 2 sizeof GLfloat Add points to the buffer so there are drawing points every X pixels count MAX ceilf sqrtf..

Record the drawing as a m4v video file - OpenGL

http://stackoverflow.com/questions/9661259/record-the-drawing-as-a-m4v-video-file-opengl

onscreen based on where the user touches void renderLineFromPoint CGPoint start toPoint CGPoint end static GLfloat vertexBuffer NULL static NSUInteger vertexMax 64 NSUInteger vertexCount 0 count i EAGLContext setCurrentContext context glBindFramebufferOES.. scale self.contentScaleFactor start.x scale start.y scale end.x scale end.y scale Allocate vertex array buffer if vertexBuffer NULL vertexBuffer malloc vertexMax 2 sizeof GLfloat Add points to the buffer so there are drawing points every X pixels.. start.x scale start.y scale end.x scale end.y scale Allocate vertex array buffer if vertexBuffer NULL vertexBuffer malloc vertexMax 2 sizeof GLfloat Add points to the buffer so there are drawing points every X pixels count MAX ceilf sqrtf..