¡@

Home 

2014/10/15 ¤U¤È 10:13:08

iphone Programming Glossary: raw

UIImagePickerController and extracting EXIF data from existing photos

http://stackoverflow.com/questions/1238838/uiimagepickercontroller-and-extracting-exif-data-from-existing-photos

on disk. I've explored file sizes but the original file is a JPEG whilst the returned image is a raw UIImage making it impossible to know the file size of the image that was selected. I'm considering making..

How to get the RGB values for a pixel on an image on the iphone

http://stackoverflow.com/questions/144250/how-to-get-the-rgb-values-for-a-pixel-on-an-image-on-the-iphone

Make sure we have our context if context free pixelData NSLog @ Context not created Draw the image to the bitmap context. The memory allocated for the context for rendering will then contain.. to the bitmap context. The memory allocated for the context for rendering will then contain the raw image pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage.. pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage context rect self.CGImage Now we can get a pointer to the image pixelData associated with the bitmap..

iPhone sending POST with NSURLConnection

http://stackoverflow.com/questions/2071788/iphone-sending-post-with-nsurlconnection

application xml then this data is not added to the _POST array in PHP. You will have to read the raw from the input stream. Try this NSString str NSString stringWithFormat @ xml version 1.0 n mydata @.. NSUTF8StringEncoding and on the server try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that.. try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that this only works if the HTTP header of your..

iPhone app in landscape mode

http://stackoverflow.com/questions/402/iphone-app-in-landscape-mode

first time has been resolved. As you can see in the demo project you can swap out leave only the raw app window and insert another landscape view with no problem. As of April 2011 there is no reason to..

iOS UIImagePickerController result image orientation after upload

http://stackoverflow.com/questions/5427656/ios-uiimagepickercontroller-result-image-orientation-after-upload

imageOrientation which instructs the UIImageView and other UIImage consumers to rotate the raw image data. There's a good chance that this flag is being saved to the exif data in the uploaded jpeg.. UIImageOrientationDown case UIImageOrientationLeft case UIImageOrientationRight break Now we draw the underlying CGImage into a new context applying the transform calculated above. CGContextRef ctx.. case UIImageOrientationRight case UIImageOrientationRightMirrored Grr... CGContextDrawImage ctx CGRectMake 0 0 self.size.height self.size.width self.CGImage break default CGContextDrawImage..

What's the easiest way to resize/optimize an image size with the iPhone SDK?

http://stackoverflow.com/questions/612131/whats-the-easiest-way-to-resize-optimize-an-image-size-with-the-iphone-sdk

UIImage image scaledToSize CGSize newSize UIGraphicsBeginImageContext newSize image drawInRect CGRectMake 0 0 newSize.width newSize.height UIImage newImage UIGraphicsGetImageFromCurrentImageContext.. UIImageJPEGRepresentation theImage 0.6 This creates an NSData instance containing the raw bytes for a JPEG image at a 60 quality setting. The contents of that NSData instance can then be written..

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

fast upload of camera frames to OpenGL ES but it can be used in reverse to get quick access to the raw pixels within an OpenGL ES texture. You can take advantage of this to grab the pixels for an OpenGL.. are optimized to use when encoding video so there's no need to do any color swizzling here. The raw BGRA pixels are just fed into the encoder to make the movie. Aside from the use of this in an AVAssetWriter.. Aside from the use of this in an AVAssetWriter I have some code in this answer that I've used for raw pixel extraction. It also experiences a significant speedup in practice when compared to using glReadPixels..

Reading HTML content from a UIWebView

http://stackoverflow.com/questions/992348/reading-html-content-from-a-uiwebview

HTML content from a UIWebView Is it possible to the raw HTML content of a web page that has been loaded into a UIWebView If not is there another way to pull.. content of a web page that has been loaded into a UIWebView If not is there another way to pull raw HTML content from a web page in the iPhone SDK such as an equivalent of the .NET WebClient openRead..

UIImagePickerController and extracting EXIF data from existing photos

http://stackoverflow.com/questions/1238838/uiimagepickercontroller-and-extracting-exif-data-from-existing-photos

a photo returned from the UIImagePickerController to a file on disk. I've explored file sizes but the original file is a JPEG whilst the returned image is a raw UIImage making it impossible to know the file size of the image that was selected. I'm considering making a table of hashes and matching against the first x pixels..

How to get the RGB values for a pixel on an image on the iphone

http://stackoverflow.com/questions/144250/how-to-get-the-rgb-values-for-a-pixel-on-an-image-on-the-iphone

bytesPerRow colorSpace kCGImageAlphaPremultipliedLast Make sure we have our context if context free pixelData NSLog @ Context not created Draw the image to the bitmap context. The memory allocated for the context for rendering will then contain the raw image pixelData in the specified color space. CGRect.. free pixelData NSLog @ Context not created Draw the image to the bitmap context. The memory allocated for the context for rendering will then contain the raw image pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage context rect self.CGImage Now we can get a pointer.. the context for rendering will then contain the raw image pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage context rect self.CGImage Now we can get a pointer to the image pixelData associated with the bitmap context. pixelData RGBAPixel CGBitmapContextGetData context..

iPhone sending POST with NSURLConnection

http://stackoverflow.com/questions/2071788/iphone-sending-post-with-nsurlconnection

However if you set a different HTTP Content Type like application xml then this data is not added to the _POST array in PHP. You will have to read the raw from the input stream. Try this NSString str NSString stringWithFormat @ xml version 1.0 n mydata @ mydata data request setHTTPMethod @ POST request setValue @.. @ Content Type request setHTTPBody str dataUsingEncoding NSUTF8StringEncoding and on the server try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that this only works if the HTTP header of your POST is not application.. str dataUsingEncoding NSUTF8StringEncoding and on the server try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that this only works if the HTTP header of your POST is not application x www form urlencoded. If it is..

iPhone app in landscape mode

http://stackoverflow.com/questions/402/iphone-app-in-landscape-mode

and the specific bad problem of landscape only working the first time has been resolved. As you can see in the demo project you can swap out leave only the raw app window and insert another landscape view with no problem. As of April 2011 there is no reason to support anything below 4.0 so the question is now only a historic..

iOS UIImagePickerController result image orientation after upload

http://stackoverflow.com/questions/5427656/ios-uiimagepickercontroller-result-image-orientation-after-upload

touch ios share improve this question A UIImage has a property imageOrientation which instructs the UIImageView and other UIImage consumers to rotate the raw image data. There's a good chance that this flag is being saved to the exif data in the uploaded jpeg image but the program you use to view it is not honoring that.. transform 1 1 break case UIImageOrientationUp case UIImageOrientationDown case UIImageOrientationLeft case UIImageOrientationRight break Now we draw the underlying CGImage into a new context applying the transform calculated above. CGContextRef ctx CGBitmapContextCreate NULL self.size.width self.size.height.. case UIImageOrientationLeft case UIImageOrientationLeftMirrored case UIImageOrientationRight case UIImageOrientationRightMirrored Grr... CGContextDrawImage ctx CGRectMake 0 0 self.size.height self.size.width self.CGImage break default CGContextDrawImage ctx CGRectMake 0 0 self.size.width self.size.height self.CGImage..

What's the easiest way to resize/optimize an image size with the iPhone SDK?

http://stackoverflow.com/questions/612131/whats-the-easiest-way-to-resize-optimize-an-image-size-with-the-iphone-sdk

described in this post with the relevant code UIImage imageWithImage UIImage image scaledToSize CGSize newSize UIGraphicsBeginImageContext newSize image drawInRect CGRectMake 0 0 newSize.width newSize.height UIImage newImage UIGraphicsGetImageFromCurrentImageContext UIGraphicsEndImageContext return newImage As far as.. you can take your UIImage and do the following NSData dataForJPEGFile UIImageJPEGRepresentation theImage 0.6 This creates an NSData instance containing the raw bytes for a JPEG image at a 60 quality setting. The contents of that NSData instance can then be written to disk or cached in memory. share improve this answer..

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

cache support added in iOS 5.0 doesn't just work for fast upload of camera frames to OpenGL ES but it can be used in reverse to get quick access to the raw pixels within an OpenGL ES texture. You can take advantage of this to grab the pixels for an OpenGL ES rendering by using a framebuffer object FBO with an attached.. are natively in BGRA format which is what AVAssetWriters are optimized to use when encoding video so there's no need to do any color swizzling here. The raw BGRA pixels are just fed into the encoder to make the movie. Aside from the use of this in an AVAssetWriter I have some code in this answer that I've used for raw.. BGRA pixels are just fed into the encoder to make the movie. Aside from the use of this in an AVAssetWriter I have some code in this answer that I've used for raw pixel extraction. It also experiences a significant speedup in practice when compared to using glReadPixels although less than I see with the pixel buffer pool..

Reading HTML content from a UIWebView

http://stackoverflow.com/questions/992348/reading-html-content-from-a-uiwebview

HTML content from a UIWebView Is it possible to the raw HTML content of a web page that has been loaded into a UIWebView If not is there another way to pull raw HTML content from a web page in the iPhone SDK such as.. HTML content from a UIWebView Is it possible to the raw HTML content of a web page that has been loaded into a UIWebView If not is there another way to pull raw HTML content from a web page in the iPhone SDK such as an equivalent of the .NET WebClient openRead Thanks in advance html iphone uiwebview share improve this..

How does the iOS app Display Recorder record the screen without using private API?

http://stackoverflow.com/questions/11090184/how-does-the-ios-app-display-recorder-record-the-screen-without-using-private-ap

It does look like my initial suspicion was correct it is using IOSurface to sneak past sandbox restrictions to have raw screen access. It also uses UIGetScreenImage which I assume is for the second method of generating video. It also uses some..

UIImagePickerController and extracting EXIF data from existing photos

http://stackoverflow.com/questions/1238838/uiimagepickercontroller-and-extracting-exif-data-from-existing-photos

to a file on disk. I've explored file sizes but the original file is a JPEG whilst the returned image is a raw UIImage making it impossible to know the file size of the image that was selected. I'm considering making a table of hashes..

How to get the RGB values for a pixel on an image on the iphone

http://stackoverflow.com/questions/144250/how-to-get-the-rgb-values-for-a-pixel-on-an-image-on-the-iphone

Make sure we have our context if context free pixelData NSLog @ Context not created Draw the image to the bitmap context. The memory allocated for the context for rendering will then contain the raw image pixelData.. Draw the image to the bitmap context. The memory allocated for the context for rendering will then contain the raw image pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage context.. the raw image pixelData in the specified color space. CGRect rect 0 0 self.size.width self.size.height CGContextDrawImage context rect self.CGImage Now we can get a pointer to the image pixelData associated with the bitmap context. pixelData..

MPMediaItems raw song data

http://stackoverflow.com/questions/1656124/mpmediaitems-raw-song-data

raw song data I was wondering how to access an MPMediaItem's raw data. Any ideas iphone iphone sdk 3.0 mpmediapickercontroller.. raw song data I was wondering how to access an MPMediaItem's raw data. Any ideas iphone iphone sdk 3.0 mpmediapickercontroller mpmediaitem share improve this question you can obtain..

iPhone sending POST with NSURLConnection

http://stackoverflow.com/questions/2071788/iphone-sending-post-with-nsurlconnection

Content Type like application xml then this data is not added to the _POST array in PHP. You will have to read the raw from the input stream. Try this NSString str NSString stringWithFormat @ xml version 1.0 n mydata @ mydata data request.. str dataUsingEncoding NSUTF8StringEncoding and on the server try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that this only works if.. and on the server try the following PHP handle fopen php input rb http_raw_post_data '' while feof handle http_raw_post_data . fread handle 8192 fclose handle Please note that this only works if the HTTP header of your POST is not application..

Get Pixel color of UIImage

http://stackoverflow.com/questions/3284185/get-pixel-color-of-uiimage

of a particular pixel in a UIImage iphone uiimage rgb pixel share improve this question You can't access the raw data directly but by getting the CGImage of this image you can access it. here is a link to another question that answers..

How should I store UIImages within my Core Data database?

http://stackoverflow.com/questions/3908910/how-should-i-store-uiimages-within-my-core-data-database

class BOOL allowsReverseTransformation return YES id transformedValue id value if value nil return nil I pass in raw data when generating the image save that directly to the database if value isKindOfClass NSData class return value return..

iPhone app in landscape mode

http://stackoverflow.com/questions/402/iphone-app-in-landscape-mode

only working the first time has been resolved. As you can see in the demo project you can swap out leave only the raw app window and insert another landscape view with no problem. As of April 2011 there is no reason to support anything below..

CGContextDrawImage draws image upside down when passed UIImage.CGImage

http://stackoverflow.com/questions/506622/cgcontextdrawimage-draws-image-upside-down-when-passed-uiimage-cgimage

draws image upside down when passed UIImage.CGImage Does anyone know why CGContextDrawImage would be drawing my image.. draws image upside down when passed UIImage.CGImage Does anyone know why CGContextDrawImage would be drawing my image upside.. draws image upside down when passed UIImage.CGImage Does anyone know why CGContextDrawImage would be drawing my image upside down I am loading an image in from my application UIImage image UIImage imageNamed..

How to apply “filters” to AVCaptureVideoPreviewLayer

http://stackoverflow.com/questions/5156872/how-to-apply-filters-to-avcapturevideopreviewlayer

to apply &ldquo filters&rdquo to AVCaptureVideoPreviewLayer My app is currently using AVFoundation to take the raw camera data from the rear camera of an iPhone and display it on an AVCaptureVideoPreviewLayer in real time. My goal is to..

iOS UIImagePickerController result image orientation after upload

http://stackoverflow.com/questions/5427656/ios-uiimagepickercontroller-result-image-orientation-after-upload

A UIImage has a property imageOrientation which instructs the UIImageView and other UIImage consumers to rotate the raw image data. There's a good chance that this flag is being saved to the exif data in the uploaded jpeg image but the program.. case UIImageOrientationDown case UIImageOrientationLeft case UIImageOrientationRight break Now we draw the underlying CGImage into a new context applying the transform calculated above. CGContextRef ctx CGBitmapContextCreate.. UIImageOrientationLeftMirrored case UIImageOrientationRight case UIImageOrientationRightMirrored Grr... CGContextDrawImage ctx CGRectMake 0 0 self.size.height self.size.width self.CGImage break default CGContextDrawImage ctx CGRectMake 0..

What's the easiest way to resize/optimize an image size with the iPhone SDK?

http://stackoverflow.com/questions/612131/whats-the-easiest-way-to-resize-optimize-an-image-size-with-the-iphone-sdk

code UIImage imageWithImage UIImage image scaledToSize CGSize newSize UIGraphicsBeginImageContext newSize image drawInRect CGRectMake 0 0 newSize.width newSize.height UIImage newImage UIGraphicsGetImageFromCurrentImageContext UIGraphicsEndImageContext.. following NSData dataForJPEGFile UIImageJPEGRepresentation theImage 0.6 This creates an NSData instance containing the raw bytes for a JPEG image at a 60 quality setting. The contents of that NSData instance can then be written to disk or cached..

Are the Core Image filters in iOS 5.0 fast enough for realtime video processing?

http://stackoverflow.com/questions/6625888/are-the-core-image-filters-in-ios-5-0-fast-enough-for-realtime-video-processing

I created a benchmark application as part of the testing for my GPUImage framework and profiled the performance of raw CPU based filters Core Image filters and GPUImage filters with live video feeds. The following were the times in milliseconds..

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

just work for fast upload of camera frames to OpenGL ES but it can be used in reverse to get quick access to the raw pixels within an OpenGL ES texture. You can take advantage of this to grab the pixels for an OpenGL ES rendering by using.. is what AVAssetWriters are optimized to use when encoding video so there's no need to do any color swizzling here. The raw BGRA pixels are just fed into the encoder to make the movie. Aside from the use of this in an AVAssetWriter I have some.. to make the movie. Aside from the use of this in an AVAssetWriter I have some code in this answer that I've used for raw pixel extraction. It also experiences a significant speedup in practice when compared to using glReadPixels although less..

Reading HTML content from a UIWebView

http://stackoverflow.com/questions/992348/reading-html-content-from-a-uiwebview

HTML content from a UIWebView Is it possible to the raw HTML content of a web page that has been loaded into a UIWebView If not is there another way to pull raw HTML content from.. to the raw HTML content of a web page that has been loaded into a UIWebView If not is there another way to pull raw HTML content from a web page in the iPhone SDK such as an equivalent of the .NET WebClient openRead Thanks in advance html..

Converting Raw RSA Key value to SecKeyRef Object for Encryption

http://stackoverflow.com/questions/1536894/converting-raw-rsa-key-value-to-seckeyref-object-for-encryption

Raw RSA Key value to SecKeyRef Object for Encryption Hi I have a RSa publicKey value in base64 how do i convert to SecKeyRef.. I have a RSa publicKey value in base64 how do i convert to SecKeyRef Object without adding to Keychain Can i add a RSA Raw value to Keychain which is not in X509 format thanks in advance iphone share improve this question The following code..

Fast and Lean PDF Viewer for iPhone / iPad / iOs - tips and hints?

http://stackoverflow.com/questions/3889634/fast-and-lean-pdf-viewer-for-iphone-ipad-ios-tips-and-hints

the link Getting the page number from the Dest array Getting a table of contents Document title and Keywords Getting Raw Text and here and Here and here positioning focused Searching and here doesn't work with all PDFs some just show weird characters..

iPhone Entitlements problem with XCode 4 for Ad Hoc distribution

http://stackoverflow.com/questions/5449487/iphone-entitlements-problem-with-xcode-4-for-ad-hoc-distribution

to the iPhone Update In XCode 4.0.1 there is a menu option when the Entitlements.plist is being edited Editor Show Raw Keys and Values which will toggle the key from 'Can be debugged' to 'get task allow' iphone code signing adhoc entitlements..

update frequency set for deviceMotionUpdateInterval it's the actual frequency?

http://stackoverflow.com/questions/6777799/update-frequency-set-for-devicemotionupdateinterval-its-the-actual-frequency

which way you go. Push or pull i.e. handler callback or own timer loop iOS 4.2x iOS 4.3x Update tested with pull only Raw sensor data or Device Motion Gyroscope or accelerometer Running it in a separate thread I assume it is a little bug in the..

Version vs build in XCode 4

http://stackoverflow.com/questions/6851660/version-vs-build-in-xcode-4

textboxes on the Summary tab they are the same values. When viewing the Info tab if you right click and select Show Raw Keys Values you'll see the actual names are CFBundleShortVersionString Version and CFBundleVersion Build . The Version is..

Making use of velocityInView with UIPanGestureRecognizer

http://stackoverflow.com/questions/9093544/making-use-of-velocityinview-with-uipangesturerecognizer

for fast panning 2.0 is more reasonable changedLevel ceilf xTranslation panThreshold originalLevel int changedLevel Raw velocity seems to go from around 3 slow to over 200 fast NSLog @ raw velocity f xVelocity if changedLevel 15 changedLevel..