使用圆半径查找坐标以创建形状
Find coordinates using circle radius to create shapes
我使用脚本来创建形状,通常可以使用图像映射来绘制坐标,但此脚本使用的是圆半径的坐标。
有没有一种工具可以根据圆半径绘制坐标,或者有更好的方法来绘制坐标,例如:
这适用于多边形/星形,很难使形状对称。我将制作其他更复杂的形状
circles.push(new Circle(width / 2 - 70, height / 2 - 120, circleRadius));
circles.push(new Circle(width / 2 - 0, height / 2 - 250, circleRadius));
circles.push(new Circle(width / 2 + 70, height / 2 - 120, circleRadius));
circles.push(new Circle(width / 2 + 220, height / 2 - 120, circleRadius));
circles.push(new Circle(width / 2 + 120, height / 2 - 0, circleRadius));
circles.push(new Circle(width / 2 + 180, height / 2 + 180, circleRadius));
circles.push(new Circle(width / 2 - 0, height / 2 + 120, circleRadius));
circles.push(new Circle(width / 2 - 180, height / 2 + 180, circleRadius));
circles.push(new Circle(width / 2 - 120, height / 2 - 0, circleRadius));
circles.push(new Circle(width / 2 - 220, height / 2 - 120, circleRadius));
为什么不尝试使用与您需要的形状相同的背景图像,这将帮助您获得所需的形状。
对于你所说的多边形,试着使用这些坐标,这会给你一个更好的形状。
circles.push(new Circle(width / 2 - 60, height / 2 - 60, circleRadius));
circles.push(new Circle(width / 2 - 0, height / 2 - 250, circleRadius));
circles.push(new Circle(width / 2 + 60, height / 2 - 60, circleRadius));
circles.push(new Circle(width / 2 + 260, height / 2 - 60, circleRadius));
circles.push(new Circle(width / 2 + 100, height / 2 + 60, circleRadius));
circles.push(new Circle(width / 2 + 160, height / 2 + 250, circleRadius));
circles.push(new Circle(width / 2 - 0, height / 2 + 130, circleRadius));
circles.push(new Circle(width / 2 - 160, height / 2 + 250, circleRadius));
circles.push(new Circle(width / 2 - 100, height / 2 + 60, circleRadius));
circles.push(new Circle(width / 2 - 260, height / 2 - 60, circleRadius));
相关文章:
- 如何创建一个谷歌地图地理坐标数组
- 根据折线坐标数组创建高程剖面图
- 可以从谷歌地图 api v3 从生物摊位获取坐标 “onclick” 创建的标记
- 如何从点(X 和 Y 坐标)创建范围对象
- 创建坐标的栅格阵列
- 动态创建有限的n维坐标系,该坐标系具有来自轴向坐标的整数坐标
- 从xml创建多边形坐标数组
- 创建一个Javascript对象来容纳用户'的地理位置坐标
- 如何使用HTML、CSS、Javascript和If Useful JQuery创建可点击分区的坐标网格
- 使用圆半径查找坐标以创建形状
- 如何创建具有绝对坐标的响应画布
- Algorithm/Formula创建一条线/条,该线/条遵循坐标列表中的一组规范
- 在具有用户坐标的元素内创建SVGPoint
- 我如何创建一个svg精灵,然后获得每个svg的坐标
- 使用必应定位API抓取坐标并使用它创建交互式地图
- 根据数组中坐标的频率创建多个数组
- 在一个单一的经纬度坐标周围创建一个半径来创建“到达区”.因此脚本知道车辆何时到达位置
- 使用jQuery迭代JSON数组[高级自定义字段和JSON API创建的WP坐标]
- 如何在SVG中为d3 js地图创建坐标
- 在JavaScript中创建坐标数组