This commit is contained in:
Anthony Lieuallen 2022-11-20 17:34:51 -05:00
parent 5ae3142d19
commit 69d5b416ed
1 changed files with 11 additions and 24 deletions

View File

@ -210,18 +210,6 @@ Object.entries(colors).forEach(([name, color], _) => {
let x = Math.cos(colorAngle) * colorRadius + 512;
let y = Math.sin(colorAngle) * colorRadius + 512;
/*
let dotSize = 16;
let dot = document.createElementNS('http://www.w3.org/2000/svg', 'circle');
dot.setAttribute('cx', x - (dotSize/2));
dot.setAttribute('cy', y - (dotSize/2));
dot.setAttribute('r', dotSize);
dot.setAttribute('style', `fill: rgb(${r}, ${g}, ${b})`);
dot.setAttribute('title', name);
svg.appendChild(dot);
*/
sites.push({x: x, y: y});
colorsBySite[[x, y]] = name;
});
@ -229,7 +217,6 @@ Object.entries(colors).forEach(([name, color], _) => {
let voronoi = new Voronoi().compute(sites, {xl: 0, xr: 1024, yt: 0, yb: 1024});
voronoi.cells.forEach(cell => {
//console.log('cell', cell, );
if (cell.closeMe) {
console.warn('cell', cell, 'needs closing');
return;