Hi,
I'm using AttachInView to attach a cocos scene to a UIKit view. However, although moving the frame of that view around correctly moves the cocosScene, it does not seem to obey the size setting of the view. I have 'scale subview automatically' true on the view. Is there some way to cause the cocos scene to correctly scale with the view it's attached to?
For code reference, given V is the view the cocos scene is attached to, and dx is the pixel space of the pinch (to zoom):
v.frame = CGRectMake(v.frame.origin.x-dx/2.0,
v.frame.origin.y-dx/2.0, v.frame.size.width+dx,
v.frame.size.height+dx);
I could, of course, set the scale on the scene manually, but this will break touch coordinates from being in the correct place.