この記事では、参照用のCanvasタイマーの動的読み込みアニメーションを共有しています。特定のコンテンツは次のとおりです
<!doctype html> <html> <head lang = "en"> <meta charset = "utf-8"> <title> </title> </title> </style> </head> <body> <canvas id = "canvas" var ctx = c.getContext( '2d'); ctx.translate(c.width/2、c.height/2); //最初に描画8個の静的ラップサークル機能create(){for(var i = 1; i <9; i ++){if(i == 1){ctx.beginPath(); ctx.arc(0、-30、5、0、2 * math.pi); ctx.fillstyle = '#f0f'; ctx.fill(); } else {ctx.beginpath(); ctx.arc(0、-30、5、0、2 * math.pi); ctx.strokestyle = '#000'; ctx.stroke(); } ctx.rotate(math.pi * 45/180); }} // setinterval(function(){ctx.clearrect(-c .width/2、-c.height、c.width、c.height); create(); ctx.rotate(math.pi*45/180);}、300); // settimeout(function(){c.style.display = 'none';}、12200)を縮小します。 // </script> </body> </html>上記はこの記事のすべての内容です。みんなの学習に役立つことを願っています。誰もがwulin.comをもっとサポートすることを願っています。