potrace
potrace copied to clipboard
Feature request: potrace color option -C #rrggbb, --color #rrggbb
this potrace option would be useful in the cases when we have a black image on transparent background because the current javascript version transforms the alpha channel in black so dark pictures with transparent backgrounds don't show up.
ps: great work, thanks and congratulations.
Workaround that I'm currently using to let the alpha white (don't work in Firefox and MS Edge when the image comes from the clipboard because their clipboard dont support alpha):
function loadCanvas() { imgCanvas.width = imgElement.width; imgCanvas.height = imgElement.height; var ctx = imgCanvas.getContext('2d'); ctx.beginPath(); ctx.rect(0, 0, imgElement.width, imgElement.height); ctx.fillStyle = "white"; ctx.fill(); ctx.drawImage(imgElement, 0, 0); }