I found interesting bug in iOS, but trying to belive that i\'m wrong. You have to do 2 things:
1) Create single-view template for iOS
2) Write small function i
I found this from one of Apple's tutorials on a finger-painting program:
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
{
CGRect bounds = [self bounds];
UITouch* touch = [[event touchesForView:self] anyObject];
firstTouch = YES;
// Convert touch point from UIView referential to OpenGL one (upside-down flip)
location = [touch locationInView:self];
location.y = bounds.size.height - location.y;
}
Looks like you need to convert the touch to OpenGL coordinates to get the result you are expecting. Hope this helps.