I have several rounded rect's that i filled and set a blend mode to make it blend to the background image by doing something like this:
UIGraphicsBeginImageContextWithOptions(self.view.frame.size, NO, 0.0);
UIImage *bgImage = [UIImage imageNamed:@"UEmenubackground.png"];
[bgImage drawInRect:self.view.frame];
UIBezierPath *textField1 = [UIBezierPath bezierPathWithRoundedRect:textField1Rect cornerRadius:21];
[[UIColor colorWithRed:174.0f/255.0f green:9.0/255.0f blue:34.0f/255.0f alpha:1.0] setFill];
[textField1Path fillWithBlendMode:kCGBlendModeOverlay alpha:1.0f];
UIBezierPath *textField2Path = [UIBezierPath bezierPathWithRoundedRect:textField2Rect cornerRadius:21];
[[UIColor colorWithRed:0 green:0 blue:0 alpha:.35] setFill];
[textField2Path fillWithBlendMode:kCGBlendModeNormal alpha:1.0f];
UIImage *drawnImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
UIImageView *finishedBGImage = [[UIImageView alloc] initWithImage:drawnImage];
[self.view addSubview:finishedBGImage];
[self.view sendSubviewToBack:finishedBGImage];
On top of these rounded rects I have text fields which the user can enter text. To make the screen less crammed I want to try to put the text fields on a scroll view with the background staying stationary however I am having trouble finding a way to redraw the rounded rects to blend with the background as it scrolls. I tried redrawing them each time the UIScrollView:DidScroll: delegate method was called but it was incredibly slow and clunky. From what I have read it looks like it is not possible but I figured I would ask around and see if anyone has a solution. Thanks!