iphone - UIImage from image picker blurry -


i know question has been asked quite few times can't figure out why uiimage still blurry.

what i've done:

despite this, uiimage appears on screen still bit blurry. ideas i'm doing wrong?

code:

uiimage *gotimage = [info objectforkey:uiimagepickercontrolleroriginalimage];  float scale = (self.view.frame.size.width)/(imagetoresize.size.width); imagetoresize = [imagetoresize resizedimage:cgsizemake(scale * imagetoresize.size.width, scale * imagetoresize.size.height) interpolationquality:kcginterpolationhigh];  uiimageview *background = [[uiimageview alloc] initwithimage:imagetoresize]; background.contentmode = uiviewcontentmodescaleaspectfit; background.frame = cgrectintegral(background.frame); [self.view addsubview:background]; 

you might attempt set rasterization on uiimageview layer.

reason being, you're picking original image, depending on device can 1000s of pixels. squishing down using aspect fit. there no rasterization smooth out image.

thats guess. without device info question kind of tough answer.


Comments

Popular posts from this blog

Using 'OR' and 'AND' in SQL Server -

python - Finding intersection between ellipse and a line -

c++ - NetBeans Remote Development with additional configuration -