Canvas第十章绘制曲线

    科技2022-07-10  226

    第十章 绘制曲线

    <canvas height="500" width="500" id="canvas"></canvas> <script> var elem=document.getElementById("canvas"); var canvas=elem.getContext("2d"); // canvas.beginPath(); // canvas.moveTo(85,73); // canvas.quadraticCurveTo (270,226,434,114); // //canvas.closePath(); // canvas.stroke(); canvas.beginPath(); canvas.moveTo(63,101); canvas.bezierCurveTo (153,212,246,68,383,191); //canvas.closePath(); canvas.stroke(); </script>
    Processed: 0.018, SQL: 8