第一步 获取画布
var canvas = document.querySelector('canvas')
第二步 获取画笔,或者上下文
var ctx = canvas.getContext('2d');
第三步 开始绘制新路径(从新起笔)
ctx.beginPath()
第四步 绘制图形