double x = vec_endPoint_rotate.x(); double y = vec_endPoint_rotate.y(); double dx = vec_center_rotate.x(); double dy = vec_center_rotate.y(); //一个点(x,y)绕任意点(dx,dy)顺时针旋转a度后的坐标 double xx = (x - dx)*cos(angleParam* VC_PI / 180) - (y - dy)*sin(angleParam* VC_PI / 180) + dx; double yy = (x - dx)*sin(angleParam* VC_PI / 180) + (y - dy)*cos(angleParam* VC_PI / 180) + dy;
原文地址:https://www.cnblogs.com/herd/p/11620760.html
时间: 2024-10-08 03:37:53