假设你在二维空间中有两个点,你需要将其中一个点旋转X度,另一个点作为中心。
float distX = Math.abs( centerX -point2X );
float distY = Math.abs( centerY -point2Y );
float dist = FloatMath.sqrt( distX*distX + distY*distY );
到目前为止,我只是找到了两点之间的距离...有没有什么想法,我应该怎么做呢?
https://stackoverflow.com/questions/12161277
复制相似问题