I want to set my world origin to a reference point ARNode, this should be easy but has no effect.
// translate node
myNode.position = position;
// reset world origin to new node
[self.sceneView.session setWorldOrigin:(myNode.simdPivot)];
// Add the model to the scene
[self.sceneView.scene.rootNode addChildNode:myNode];
I switched on the debug functions but the world origin is not moving... but also no crash or warning??
self.sceneView.debugOptions = ARSCNDebugOptionShowWorldOrigin;
Can someone point me to the right direction!
I found that a matrix conversion is necessary to make it moving:
[self.sceneView.session setWorldOrigin:SCNMatrix4ToMat4(myNode.pivot)];
But still not exactly to the node point origin... anyone who has an idea?
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.