Aligning Object3d with another Object3d while maintaining consistent rotation

Started by gagnej, April 12, 2017, 03:25:42 AM

Previous topic - Next topic

gagnej

I want to place a cube at the origin and align a cone at an edge of that cube such that the base of the cone is perpendicular to a face of the cube. I then want to be able to rotate the view so the cone stays aligned with the cube during rotation. Any stackoverflow references or videos as to how to do this would be great!

EgonOlsen

I'm not sure, what your actual question is. Just create a cube and a cone, align them in code as you wish and then rotate the view. Rotating the view has no impact on the relation between objects. If you don't want to rotate the view but the actual objects instead, make the cube the parent of the cone and then rotate only the cube.