Question about 3D point intersection
显示 更早的评论
Hello, thank you for reading this,
I'm having trouble performing a centroid rotation of a 3D geometry. My data consists of 3D points, and what I want to do is rotate it along its center.
I have the data contained in a Nx3 matrix, where N is my number of points with three column entries for the x, y and z ccordiante respectively. I can rotate it around the origin by multiplying these points by the x, y and z rotation matrices, but the problem is with the rotation comes an extreme translation as well. I want to rotate it along its averaged x, y and z midpoint, so any translation I do doesn't come with a heavy translation of the coordinates.
I looked at some material, but everything I found was for 2D images. I tried applying it to my 3D collection of points, but was unsuccessful. I tried following this as well:
as it was the closest I can find, but I'm using a 3D geometry, and rotate3d doesn't work the same way as far as I could tell.
Any advice would be appreciated!
采纳的回答
更多回答(1 个)
Matt J
2014-5-19
0 个投票
See also this rotation tool
No idea, though, what you mean by rotation about a point. That is ill-defined, since there are infinite rotation axes passing through any given point.
2 个评论
The rotation tool at my link allows you to specify a translated axis around which to rotate. No need to translate manually.
Of course, you need to know what axis you want to rotate about and it's still not clear that you do, since you are still speaking of "rotation around a point", which has no clear definition... Rotation in 3D always has to be about an axis, not a point.
类别
在 帮助中心 和 File Exchange 中查找有关 Interactions, Camera Views, and Lighting 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
