I’m new to SceneKit,and what I’m trying do is to load a dae file to a SCNScene, set this SCNScene to a SCNView, enable the user interaction, and then I can rotate the 3D model through gestures. So far it goes well, when I swipe or zoom in/zoom out, the 3D model works as the way it should be. However, what I really need is that when a gesture(swipe right or left)takes place, the 3D model rotates only horizontally, and no zoom in/zoom out, what can I do to make it happen? Here is my code:
// retrieve the SCNView
SCNView *myView = (SCNView *)self.view;
// load dae file and set the scene to the view
myView.scene = [SCNScene sceneNamed:@"model.dae"];
myView.userInteractionEnabled = YES;
myView.allowsCameraControl = YES;
myView.autoenablesDefaultLighting = YES;
myView.backgroundColor = [UIColor lightGrayColor];
Thanks for any help!