<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>
<body>
<canvas id="mycanvas" class="mycanvas" width="462" height="462"></canvas>
</body>
<script>
const x0 = 231 / 2 * 2 // 圆心坐标
const y0 = 231 / 2 * 2 // 圆心坐标
const r1 = (231 / 2 - 16) * 2 // 外圆半径
const r2 = (231 / 2 - 25) * 2 // 内圆半径
const startAng = 135 // 起始角度
const
canvas 画半圆的两种方式
最新推荐文章于 2022-05-06 17:37:28 发布