mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 01:41:22 +01:00
fix: elevation profile color scheme
This commit is contained in:
parent
14ac83e6f5
commit
09f835c210
4 changed files with 42 additions and 10 deletions
|
|
@ -327,9 +327,10 @@ function drawCellsValue(data) {
|
|||
|
||||
// helper function non-used for the main generation
|
||||
function drawPolygons(data) {
|
||||
const max = d3.max(data),
|
||||
min = d3.min(data),
|
||||
scheme = getColorScheme(terrs.select("#landHeights").attr("scheme"));
|
||||
const max = d3.max(data);
|
||||
const min = d3.min(data);
|
||||
const scheme = getColorScheme(terrs.select("#landHeights").attr("scheme"));
|
||||
|
||||
data = data.map(d => 1 - normalize(d, min, max));
|
||||
|
||||
debug.selectAll("polygon").remove();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue