I have an iPad app with a standard UIViewController/UIView setup - all rotations are allowed. The UIView draws some tiled image as background (the tile is 256*256 pixels):
- (void)drawRect:(CGRect)rect
{
[[UIImage imageNamed: @"Background.png"] drawAsPatternInRect: rect];
}
When I turn my iPad I can see that during the rotation the image pattern of the original orientation is scaled to fit the new orientation. Then - immediately after the animation is finished - the view redraws its background pattern with the final configuration which is unscaled. The switching from a scaled to an unscaled pattern looks a bit ugly.
Is there a way to circumvent (or hide) this strecthing of the background pattern?