From 86864ab8b2d4c49e844f5b0d48a3f66ed223a557 Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Mon, 9 Apr 2018 23:30:14 +0200 Subject: [PATCH] [vue.auth.dialog] updated dialog 'frequency' canvas --- parcel/vue/auth/dialog.vue | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/parcel/vue/auth/dialog.vue b/parcel/vue/auth/dialog.vue index d7c07a2..7dd60c7 100644 --- a/parcel/vue/auth/dialog.vue +++ b/parcel/vue/auth/dialog.vue @@ -142,19 +142,21 @@ export default { /* (3) Erase previous drawing */ ctx.clearRect(0, 0, can.width, can.height); + ctx.lineWidth = 7; - /* (4) Begin tracing */ - ctx.beginPath(); - ctx.moveTo(0, can.height-128-buffer[0]/2); + /* (4) Trace through each value */ + for( let i = precision ; i < buffer.length ; i+=precision ){ - /* (5) Trace through each value */ - for( let i = precision ; i < buffer.length ; i+=precision ) + ctx.beginPath(); + ctx.strokeStyle = '#44484f'; + + ctx.moveTo(i, can.height-128); ctx.lineTo(i, can.height-128-buffer[i]/2); - /* (6) End tracing */ - ctx.lineWidth = 7; - ctx.strokeStyle = '#44484f'; - ctx.stroke(); + ctx.stroke(); + + } + }