Just you have to find the Screen size bound and scale.
CGRect rect=[[UIScreen mainScreen] bounds];
CGFloat scale=[[UIScreen mainScreen] scale];
NSLog(@"Actual Pixel Resolution: width :% f,height :%f",rect.size.width * scale,rect.size.height * scale);
NSLog(@" Actual Size width :% f,height :%f",rect.size.width ,rect.size.height );
O/P
For retina 4-inch display
Actual Pixel Resolution: width : 640.000000,height :1136.000000
Actual Size width : 320.000000,height :568.000000
No comments:
Post a Comment