normalize prec, flux and river width

This commit is contained in:
Azgaar 2021-12-30 18:49:36 +03:00
parent f08b77bd6a
commit 604dcfacf6
6 changed files with 76 additions and 16 deletions

View file

@ -89,7 +89,8 @@ function createRiver() {
const source = riverCells[0];
const mouth = parent === riverId ? last(riverCells) : riverCells[riverCells.length - 2];
const sourceWidth = 0.05;
const widthFactor = 1.2;
const defaultWidthFactor = rn(1 / (pointsInput.dataset.cells / 10000) ** 0.25, 2);
const widthFactor = 1.2 * defaultWidthFactor;
const meanderedPoints = addMeandering(riverCells);