It's tile based so it's possible to change the shape chosing the tiles to be revealed around the player, some shapes won't fit the design to work with a changleable view range as a radius tho.
I've done another one with round corners (see it here) but I could not manage to save it when the player saves the game, so everytime the map is loaded, the fog of war is rebooted.
Yes, the one I linked was made using canvas, the problem is that I didn't find a way to store the map canvas when saving the game.
It's drawn in a Bitmap object which has a cyclic reference with it's parent, so I can't parse it into a JSON object to store in the save file.
var lines = JSON.parse(localStorage.getItem(canvasName));
lines.forEach(function (line) {
ctx.beginPath();
ctx.strokeStyle = line.color;
ctx.moveTo(line.x1, line.y1);
ctx.lineTo(line.x2, line.y2);
ctx.stroke();
});