Right now, when I double tap the UIScrollView I run this code (taken from Apple's own example code):
#define ZOOM_STEP 1.5
float newScale = [imageScrollView zoomScale] * ZOOM_STEP;
CGRect zoomRect = [self zoomRectForScale:newScale withCenter:tapPoint];
[imageScrollView zoomToRect:zoomRect animated:YES];
However, I have set the maximum zoom to 3, but I'd like to figure out how to make a double tap zoom to 1px = 1px, by that I mean, the UIScrollView zooms in to the actual size of the UIImage inside it. But I am not sure how to calculate how big the image in order to use it for zoom scaling?