iphone Programming Glossary: cvpixelbufferlockbaseaddress
OpenGL ES 2d rendering into image http://stackoverflow.com/questions/10455329/opengl-es-2d-rendering-into-image read directly from the bytes that back this texture in BGRA format not the RGBA of glReadPixels using something like CVPixelBufferLockBaseAddress renderTarget 0 _rawBytesForImage GLubyte CVPixelBufferGetBaseAddress renderTarget Do something with the bytes CVPixelBufferUnlockBaseAddress..
how to convert a CVImageBufferRef to UIImage http://stackoverflow.com/questions/3152259/how-to-convert-a-cvimagebufferref-to-uiimage connection CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer Lock the image buffer CVPixelBufferLockBaseAddress imageBuffer 0 Get information about the image uint8_t baseAddress uint8_t CVPixelBufferGetBaseAddress imageBuffer size_t..
UIImage created from CMSampleBufferRef not displayed in UIImageView? http://stackoverflow.com/questions/3305862/uiimage-created-from-cmsamplebufferref-not-displayed-in-uiimageview Create a CGImageRef from sample buffer data CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer CVPixelBufferLockBaseAddress imageBuffer 0 Lock the image buffer uint8_t baseAddress uint8_t CVPixelBufferGetBaseAddressOfPlane imageBuffer 0 Get information..
How do I export UIImage array as a movie? http://stackoverflow.com/questions/3741323/how-do-i-export-uiimage-array-as-a-movie kCVPixelFormatType_32ARGB CFDictionaryRef options pxbuffer NSParameterAssert status kCVReturnSuccess pxbuffer NULL CVPixelBufferLockBaseAddress pxbuffer 0 void pxdata CVPixelBufferGetBaseAddress pxbuffer NSParameterAssert pxdata NULL CGColorSpaceRef rgbColorSpace..
ASSETWriterInput for making Video from UIImages on Iphone Issues http://stackoverflow.com/questions/3983882/assetwriterinput-for-making-video-from-uiimages-on-iphone-issues Added to make the stupid compiler not show a stupid warning. NSParameterAssert status kCVReturnSuccess pxbuffer NULL CVPixelBufferLockBaseAddress pxbuffer 0 void pxdata CVPixelBufferGetBaseAddress pxbuffer NSParameterAssert pxdata NULL CGColorSpaceRef rgbColorSpace..
How to get the Y component from CMSampleBuffer resulted from the AVCaptureSession? http://stackoverflow.com/questions/4085474/how-to-get-the-y-component-from-cmsamplebuffer-resulted-from-the-avcapturesessio fromConnection AVCaptureConnection connection CVImageBufferRef pixelBuffer CMSampleBufferGetImageBuffer sampleBuffer CVPixelBufferLockBaseAddress pixelBuffer 0 unsigned char rawPixelBase unsigned char CVPixelBufferGetBaseAddress pixelBuffer Do something with the raw..
AVFoundation + AssetWriter: Generate Movie With Images and Audio http://stackoverflow.com/questions/5640657/avfoundation-assetwriter-generate-movie-with-images-and-audio kCVPixelFormatType_32ARGB CFDictionaryRef options pxbuffer NSParameterAssert status kCVReturnSuccess pxbuffer NULL CVPixelBufferLockBaseAddress pxbuffer 0 void pxdata CVPixelBufferGetBaseAddress pxbuffer NSParameterAssert pxdata NULL CGColorSpaceRef rgbColorSpace..
AVAssetWriter Woes http://stackoverflow.com/questions/6189535/avassetwriter-woes kCVPixelFormatType_32ARGB CFDictionaryRef options pxbuffer NSParameterAssert status kCVReturnSuccess pxbuffer NULL CVPixelBufferLockBaseAddress pxbuffer 0 void pxdata CVPixelBufferGetBaseAddress pxbuffer NSParameterAssert pxdata NULL CGColorSpaceRef rgbColorSpace.. instead CVPixelBufferRef pixelBuffer NULL CVPixelBufferPoolCreatePixelBuffer NULL adaptor.pixelBufferPool pixelBuffer CVPixelBufferLockBaseAddress pixelBuffer 0 ...fill the pixelbuffer here CVPixelBufferUnlockBaseAddress pixelBuffer 0 CMTime frameTime CMTimeMake frameCount..
iOS CVImageBuffer distorted from AVCaptureSessionDataOutput with AVCaptureSessionPresetPhoto http://stackoverflow.com/questions/6540710/ios-cvimagebuffer-distorted-from-avcapturesessiondataoutput-with-avcapturesessio pixelBuffer 6 Then the delegate processes draws them void processNewCameraFrame CVImageBufferRef cameraFrame CVPixelBufferLockBaseAddress cameraFrame 0 int bufferHeight CVPixelBufferGetHeight cameraFrame int bufferWidth CVPixelBufferGetWidth cameraFrame glClear..
iPhone Watermark on recorded Video. http://stackoverflow.com/questions/7205820/iphone-watermark-on-recorded-video Create a CGImageRef from sample buffer data CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer CVPixelBufferLockBaseAddress imageBuffer 0 Lock the image buffer uint8_t baseAddress uint8_t CVPixelBufferGetBaseAddressOfPlane imageBuffer 0 Get information..
kCVPixelFormatType_420YpCbCr8BiPlanarFullRange frame to UIImage conversion http://stackoverflow.com/questions/8838481/kcvpixelformattype-420ypcbcr8biplanarfullrange-frame-to-uiimage-conversion data CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer Lock the base address of the pixel buffer CVPixelBufferLockBaseAddress imageBuffer 0 Get the number of bytes per row for the pixel buffer void baseAddress CVPixelBufferGetBaseAddress imageBuffer.. a biplanar Y CbCr image to RGB in iOS. However you should be able to perform the conversion yourself in software e.g. CVPixelBufferLockBaseAddress imageBuffer 0 size_t width CVPixelBufferGetWidth imageBuffer size_t height CVPixelBufferGetHeight imageBuffer uint8_t baseAddress..
iPhone take augmented reality screenshot with AVCaptureVideoPreviewLayer http://stackoverflow.com/questions/8980847/iphone-take-augmented-reality-screenshot-with-avcapturevideopreviewlayer sampleBuffer if CVPixelBufferGetPixelFormatType imageBuffer kCVPixelFormatType_32BGRA return CVPixelBufferLockBaseAddress imageBuffer 0 uint8_t baseAddress uint8_t CVPixelBufferGetBaseAddress imageBuffer size_t bytesPerRow CVPixelBufferGetBytesPerRow..
AVCaptureSession specify resolution and quality of captured images obj-c iphone app http://stackoverflow.com/questions/9312832/avcapturesession-specify-resolution-and-quality-of-captured-images-obj-c-iphone data CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer Lock the base address of the pixel buffer CVPixelBufferLockBaseAddress imageBuffer 0 Get the number of bytes per row for the pixel buffer void baseAddress CVPixelBufferGetBaseAddress imageBuffer..
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 and uses that texture as a target for my FBO. Once I've rendered a frame I lock the base address of the pixel buffer CVPixelBufferLockBaseAddress pixel_buffer 0 and then simply feed it into my asset writer to be encoded CMTime currentTime CMTimeMakeWithSeconds NSDate..
How can I mute the capture sound in AVFoundation? http://stackoverflow.com/questions/9557081/how-can-i-mute-the-capture-sound-in-avfoundation alloc init CVImageBufferRef imageBuffer CMSampleBufferGetImageBuffer sampleBuffer Lock the image buffer CVPixelBufferLockBaseAddress imageBuffer 0 Get information about the image uint8_t baseAddress uint8_t CVPixelBufferGetBaseAddress imageBuffer size_t..
Record the drawing as a m4v video file - OpenGL http://stackoverflow.com/questions/9661259/record-the-drawing-as-a-m4v-video-file-opengl NULL assetWriterPixelBufferInput pixelBufferPool pixel_buffer if pixel_buffer NULL status kCVReturnSuccess return else CVPixelBufferLockBaseAddress pixel_buffer 0 GLubyte pixelBufferData GLubyte CVPixelBufferGetBaseAddress pixel_buffer glReadPixels 0 0 videoSize.width..
|