iphone - How combine UIImageViews and and save as Single in Gallery as Single Image -


in new iphone project, want combine 5 uiimageviews , and save single in gallery single image.. 5 images in same view possible..?

this combining 2 images 1, you'll need tweak 5.

- (uiimage*)imagebycombiningimage:(uiimage*)firstimage withimage:(uiimage*)secondimage {         uiimage *image = nil;      cgsize newimagesize = cgsizemake(max(firstimage.size.width, secondimage.size.width), max(firstimage.size.height, secondimage.size.height));     if (uigraphicsbeginimagecontextwithoptions != null) {         uigraphicsbeginimagecontextwithoptions(newimagesize, no, [[uiscreen mainscreen] scale]);     } else {         uigraphicsbeginimagecontext(newimagesize);      }     [firstimage drawatpoint:cgpointmake(roundf((newimagesize.width-firstimage.size.width)/2),                                          roundf((newimagesize.height-firstimage.size.height)/2))];      [secondimage drawatpoint:cgpointmake(roundf((newimagesize.width-secondimage.size.width)/2),                                           roundf((newimagesize.height-secondimage.size.height)/2))];      image = uigraphicsgetimagefromcurrentimagecontext();     uigraphicsendimagecontext();      return image; } 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -