How can we draw a blurred circle in canvas using QML or Javascript?
I have tried:
var ctx = getContext("2d");
ctx.save();
ctx.clearRect(0, 0, canvas.width, canvas.height);
ctx.beginPath();
ctx.shadowBlur = 20;
ctx.shadowColor = "#22ff0000";
ctx.shadowOffsetX = 10;
ctx.lineWidth = 1;
ctx.strokeStyle = "red";
ctx.arc(canvas.centerWidth,
canvas.centerHeight,
canvas.radius, canvas.angleOffset,
canvas.angleOffset + canvas.angle);
ctx.stroke();
ctx.restore();
But my problem is the strong line is visible. I need to draw it smoothly without edges. How to do this?