export const Kernel = { Corners: [ [ 1, 1, -1], [ 1, -1, -1], [-1, 1, -1], [-1, -1, -1], [ 1, 1, 1], [ 1, -1, 1], [-1, 1, 1], [-1, -1, 1] ], Cardinal: [ [ 1, 0, 0], [ 0, 1, 0], [-1, 0, 0], [ 0, -1, 0], [ 0, 0, 1], [ 0, 0, -1] ], Loop(inList, inVector, inHandler) { for(let i=0; i { let coords = Region.XYZ(inIndex); Kernel.Loop(Kernel.Corners, coords, (inX, inY, inZ)=> { let index = Region.I(inX, inY, inZ); if(inRegion.filled[index] === undefined) { console.log(inX, inY, inZ, "surface"); surface.push(inIndex); return true; } else { console.log(inX, inY, inZ, "filled"); } }); }); return surface; } };