I'm bothered by existing space between one fill and another fill on HTML. Each fill is fitting on their aslant side. I'm expecting to fill exactly the line, but there is space.
this is sample code:
var canvas = document.createElement("canvas");
canvas.width = 120; canvas.height = 300;
document.body.appendChild(canvas);
var ctx = canvas.getContext("2d");
ctx.fillStyle = "#fff"; ctx.fillRect(0, 0, 120, 300);
ctx.fillStyle = "#000"; ctx.beginPath();
ctx.moveTo(0, 0); ctx.lineTo(0, 300); ctx.lineTo(120, 300); ctx.fill();
ctx.fillStyle = "#000"; ctx.beginPath();
ctx.moveTo(120, 300); ctx.lineTo(0, 0); ctx.lineTo(120, 0); ctx.fill();
You can see the white line (white space) between black triangles. Actually, the triangle's points are made by an auto-generating program for Flash, and Flash can show the triangles without space but HTML5 can not. Does anyone have an idea that erase that line?