uiimage

How can I display my UIImage on an EAGLView (iPhone)?

I have a UIImage. I have an EAGLView in my app, which is a derivative of the GLPaint ("Shake Me!") sample program. The UIImage is full-screen (320x480.) Actually, it's a screen-capture of the EAGLView's image from earlier in the program (like in this question.) I'd like to set the layer-contents of the EAGLView to the image, and then...

UIImageView: Rotated and Scaled. How do I save the results ??

Hi All, I am trying to save a rotated and scaled UIImageView as an UIImage in the position and with the zoom scale that the user edited too. But I can only manage to save the original image as it was before editing. How can I save the image as it is shown in the UIImageView with the same scaling and rotation? I have read that I need to u...

Image on uitableview lost after scrolling

in my application, i'm loading images to the cells of a table. But, when i scroll the table, the image goes out of sight of the table(goes up), it wont be there even if i scroll back. customCell.h #import <UIKit/UIKit.h> @interface CustomCell : UITableViewCell<UINavigationControllerDelegate, UIImagePickerControllerDelegate> { UIViewCon...

Http Posting An Image From Iphone

NSMutableString *url = [[NSMutableString alloc] init]; [url appendString:@"uploadImage.do"]; NSData *imageData = UIImageJPEGRepresentation(selectedImage,1.0); // setting up the request object now NSMutableURLRequest *request = [[[NSMutableURLRequest alloc] init] autorelease]; [request setURL:[NSURL URLWithString:url]]; [request se...

How to save a GIF on the iPhone?

Hi, how can I save a GIF on the iPhone? The SDK includes only UIImageJPEGRepresentation and UIImagePNGRepresentation but nothing for GIFs or other image formats, is there a way to convert a UIImage to a GIF and save it? GM ...

Why is scaling down a UIImage from the camera so slow?

resizing a camera UIImage returned by the UIImagePickerController takes a ridiculously long time if you do it the usual way as in this post. [update: last call for creative ideas here! my next option is to go ask Apple, I guess.] Yes, it's a lot of pixels, but the graphics hardware on the iPhone is perfectly capable of drawing lots of...

Get the identity of the image loaded at the centre of the screen currently?

I have a uiscrollview with contentsize 1280*1280 and 25 images of equal size loaded in it. When i scroll and meet an end, I want to know the identity of the image which is currently present at the screen centre. Given below is the code that i used to load the images into the scrollView. How can i figure it out? for (i = 0; i < 5; i...

Duplicating the pinpoint feature of mapkit in an imageView application?

I load a set of images in my screen. When it loads on one image I want a pin to be pointed with some value written in the blackbox on that image. But how to get a blackbox like the one we see, when we click on the pinpoint of a map? And how to keep that image or whatever it is on that image ...

How can we clear the cached images when we clos the app?

I cache the images to the document directory of my app using the following code. NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *saveDirectory = [paths objectAtIndex:0]; But even after I close the application, its still there. How can I clear it when I lose my app. I am doing...

How do I use a mask to punch out my image?

I have a mask (loaded from a 256 grey PNG) that I want to apply to an image that's being used as part of my process for drawing a UITableViewCell's imageView.image property. When the cell isn't selected/highlighted, I CGImageCreateWithMask with a square of the proper color and the mask, then drawAtPoint: it into the image I'm building. ...

Crop a UIImage from the Center outwards?

I am making a camera app which includes digital zoom. I have a slider (zoomSlider) that has a minimum value of 1 and a maximum value of 4. When the user taps the camera button, it takes a picture, and then I crop it for the zooming. I have two problems: How do I crop the exact middle of the image? (eg. 2x zoom, Rect would be centered wi...

How to save aUIImage using NSUserDefaults

How do I save an Image to User Defaults ...

Driving me crazy! animationImages always shows a memory leak

I must have tried over a dozen incarnations of this code. And looked at +100 answers. IT SHOULD BE so simple. A real basic animation, (using IB this time) but ALWAYS shows a memory leak. NO matter where I put my nil, my release, tried a zillion combinations. // implement viewDidLoad to do additional setup after loading the view, typic...

Need advise about detect cache Image on Iphone

now i implement download image function so how did i know that image is already load and get it from memory? ...

char * to NSData to display in UIImageView

I am getting image data in form of char * (stored on sql server). I want to convert those data to NSData to display image in UIImage view. char * data is a bytearray for source image. how can i convert char * to NSData to display to get an UIImage instance for displaying in UIImageView? Thanks.. ...

How do I save and read an image to my temp folder when quitting and loading my app

I want to save and read a UIImage to my temp folder when my app closes and then load and delete it when the app loads. How do I accomplish this. Please help. ...

Drawing a PNG Image Into a Graphics Context for Blending Mode Manipulation

I need to draw a series of PNGs into a CG context so I can blend them together: CGContextRef context = UIGraphicsGetCurrentContext(); CGContextSetBlendMode (context, kCGBlendModeOverlay); Currently I have my app working based on just drawing each image as a UIImageView and adding them as a subview to the view file via: [self addSubview...

Creating image from an array of colors in iphone

I have array with colors as its objects. I want to create an image out of it. Actually, what is happening is , i'm taking the pixel value of each pixel of an image, modify it and store in a mutable array its object. Now want to draw an image from this. How to do that?? ANy idea??? -(UIImage*)modifyPixels:(UIImage*)originalImage { NS...

a problem with load image from cache on iPhone

Here my code UIImage * result = [[UIImage alloc] imageWithContentsOfFile:filePath]; here my error log > 2009-12-22 17:00:44.137 > DrillDownApp[2061:207] touchesBegan > from root 2009-12-22 17:00:44.138 > DrillDownApp[2061:207] touchesBegan > from root at X = 52.000 and Y = 87.000 > at INDEX = 0 2009-12-22 17:00:44.139 > DrillDownApp[...

Blending Three Images into Graphics Context Using Alpha Blend Mode kBlendModeOverlay

Does kCGBlendModeOverlay not work exactly like Photoshop's Overlay blending mode? I'm trying to overlay three images into a graphic context via: [uiimageGreen drawAtPoint:CGPointMake(x, y) blendMode:kCGBlendModeOverlay alpha:1.0]; [uiimageRed drawAtPoint:CGPointMake(x, y) blendMode:kCGBlendModeOverlay alpha:1.0]; [uiimageBlue drawAtPoin...