Move growBoundingBox to utils.js
This commit is contained in:
parent
112de7ed1a
commit
596dd9501c
|
|
@ -163,6 +163,13 @@ function multiplyMatrices(a, b) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function growBoundingBox(bboxa, bboxb) {
|
||||||
|
bboxa.x.min = Math.min(bboxa.x.min, bboxb.x.min);
|
||||||
|
bboxa.y.min = Math.min(bboxa.y.min, bboxb.y.min);
|
||||||
|
bboxa.x.max = Math.max(bboxa.x.max, bboxb.x.max);
|
||||||
|
bboxa.y.max = Math.max(bboxa.y.max, bboxb.y.max);
|
||||||
|
}
|
||||||
|
|
||||||
function floodFillRegion(
|
function floodFillRegion(
|
||||||
startPoint,
|
startPoint,
|
||||||
epsilon,
|
epsilon,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue