libpov_2025/index.html

150 lines
5.3 KiB
HTML
Raw Normal View History

2023-10-20 02:54:39 +02:00
<!DOCTYPE html>
<html>
<head>
2023-10-20 14:37:07 +02:00
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="icon" href="./favicon.png">
2023-10-21 23:45:40 +02:00
<link rel="stylesheet" href="./dark_style.css">
2023-10-22 02:21:20 +02:00
<title>MiBPoV—Minetest Biome Point Visualizer</title>
2023-10-20 02:54:39 +02:00
</style>
2023-10-23 01:48:15 +02:00
<!-- Include Voronoi diagram API, required to calculate Voronoi diagrams -->
2023-10-20 02:54:39 +02:00
<script src="./rhill-voronoi-core.js"></script>
</head>
2023-10-21 23:45:40 +02:00
2023-10-20 02:54:39 +02:00
<body>
2023-10-22 02:21:20 +02:00
<h1>MiBPoV—Minetest Biome Point Visualizer</h1>
2023-10-23 01:46:24 +02:00
<div class="contentContainer" id="noscriptContainer">
2023-10-22 02:45:26 +02:00
<noscript>
<div class="borderedWarning">
2023-10-22 02:47:09 +02:00
ERROR: This tool requires JavaScript to work, but JavaScript is disabled in your browser.
2023-10-22 02:45:26 +02:00
</div>
</noscript>
2023-10-23 01:46:24 +02:00
</div>
<!-- The main content container starts hidden so it doesn't clutter
the page in noscript mode. It will be unhidden once the JavaScript loads -->
<div id="mainContentContainer" class="contentContainer" hidden>
2023-10-21 23:45:40 +02:00
<div id="canvasContainer">
2023-10-20 12:34:37 +02:00
<canvas id="voronoiCanvas" width="500" height="500">
2023-10-21 23:45:40 +02:00
A Voronoi diagram is supposed to be here but for some reason it cannot be displayed. This tool is useless without this functionality.
2023-10-20 02:54:39 +02:00
</canvas>
2023-10-20 10:43:04 +02:00
</div>
2023-10-21 23:45:40 +02:00
<div id="diagramInfoContainer" class="borderedSection">
2023-10-21 21:35:20 +02:00
<span id="errorMessage" hidden></span>
<span id="altitudeDisplay"></span>
<br>
<span id="rangeDisplay">&nbsp;</span>
<br>
<span id="coordinateDisplay">&nbsp;</span>
<br>
2023-10-21 01:48:45 +02:00
</div>
2023-10-22 02:11:36 +02:00
<div>
<h2 class="configHeader"><span class="collapser" id="biomeConfigHeaderLink"></span> Biome configuration</h2>
2023-10-21 23:45:40 +02:00
<div id="biomeConfigContainer" class="configFrame">
2023-10-20 10:43:04 +02:00
<form id="biomeForm">
2023-10-21 23:45:40 +02:00
<div id="biomeSelectorContainer">
2023-10-21 22:44:09 +02:00
<h3>Biome list</h3>
2023-10-20 11:24:38 +02:00
<label for="biomeSelector">Biomes:<br>
2023-10-20 12:34:37 +02:00
<select id="biomeSelector" name="biomeList" size="8"></select>
2023-10-20 10:43:04 +02:00
</label>
<br>
2023-10-21 23:45:40 +02:00
<div id="biomeButtonContainer">
2023-10-20 11:24:38 +02:00
<button id="addBiomeButton" type="button">Add</button>
<button id="removeBiomeButton" type="button">Remove</button>
2023-10-21 22:44:09 +02:00
</div>
</div>
2023-10-20 11:24:38 +02:00
<div id="biomeEditElements">
2023-10-21 22:44:09 +02:00
<h3>Selected biome</h3>
2023-10-20 11:24:38 +02:00
<label for="inputHeat">Heat:
2023-10-20 18:38:31 +02:00
<input id="inputHeat" type="number" value="50" step="1">
2023-10-20 10:43:04 +02:00
</label>
2023-10-20 11:24:38 +02:00
<label for="inputHumidity">Humidity:
2023-10-20 18:38:31 +02:00
<input id="inputHumidity" type="number" value="50" step="1">
2023-10-20 10:43:04 +02:00
</label>
<br>
<label for="inputMinY">Min. Y:
2023-10-22 01:41:00 +02:00
<input id="inputMinY" type="number" value="-31000" step="1">
2023-10-20 10:43:04 +02:00
</label>
<label for="inputMaxY">Max. Y:
2023-10-22 01:41:00 +02:00
<input id="inputMaxY" type="number" value="31000" step="1">
2023-10-20 10:43:04 +02:00
</label>
</div>
</form>
2023-10-20 13:31:23 +02:00
</div>
2023-10-22 02:11:36 +02:00
<div>
<h2 class="configHeader"><span class="collapser" id="viewConfigHeaderLink"></span> Diagram view settings</h2>
<div id="viewConfigContainer" class="configFrame">
2023-10-20 17:22:48 +02:00
<form id="viewForm">
2023-10-21 21:35:20 +02:00
<label for="inputViewY">Altitude:</label>
2023-10-21 13:59:19 +02:00
<input id="inputViewY" type="number" value="0" step="1">
2023-10-21 22:44:09 +02:00
<br>
2023-10-21 13:59:19 +02:00
<input id="inputCheckboxPoints" type="checkbox" checked>
<label for="inputCheckboxPoints">Show points</label>
<input id="inputCheckboxNames" type="checkbox" checked>
<label for="inputCheckboxNames">Show names</label>
2023-10-23 02:47:00 +02:00
<input id="inputCheckboxAxes" type="checkbox">
<label for="inputCheckboxAxes">Show axes</label>
2023-10-21 13:59:19 +02:00
<input id="inputCheckboxGrid" type="checkbox" checked>
<label for="inputCheckboxGrid">Show grid</label>
<input id="inputCheckboxCellColors" type="checkbox" checked>
<label for="inputCheckboxCellColors">Colorize cells</label>
2023-10-20 17:22:48 +02:00
</form>
</div>
2023-10-21 22:44:09 +02:00
</div>
2023-10-22 02:11:36 +02:00
<div>
<h2 class="configHeader"><span class="collapser" id="noiseConfigHeaderLink"></span> Noise parameters</h2>
2023-10-22 02:11:36 +02:00
<div class="configFrame" id="noiseConfigContainer">
2023-10-21 17:12:43 +02:00
<form id="noiseForm">
2023-10-22 01:41:00 +02:00
<h3>Heat (<code>mg_biome_np_heat</code>)</h3>
<label for="inputNoiseHeatOffset">Offset:</label>
<input id="inputNoiseHeatOffset" type="number" value="50">
2023-10-21 17:12:43 +02:00
<label for="inputNoiseHeatScale">Scale:</label>
<input id="inputNoiseHeatScale" type="number" value="50">
2023-10-21 17:12:43 +02:00
<label for="inputNoiseHeatOctaves">Octaves:</label>
<input id="inputNoiseHeatOctaves" type="number" value="3" step="1" min="1">
2023-10-21 17:12:43 +02:00
<label for="inputNoiseHeatPersistence">Persistence:</label>
<input id="inputNoiseHeatPersistence" type="number" value="0.5" step=0.1>
2023-10-21 17:12:43 +02:00
2023-10-22 01:41:00 +02:00
<h3>Humidity (<code>mg_biome_np_humidity</code>)</h3>
<label for="inputNoiseHumidityOffset">Offset:</label>
<input id="inputNoiseHumidityOffset" type="number" value="50">
<label for="inputNoiseHumidityScale">Scale:</label>
<input id="inputNoiseHumidityScale" type="number" value="50">
<label for="inputNoiseHumidityOctaves">Octaves:</label>
<input id="inputNoiseHumidityOctaves" type="number" value="3" step="1" min="1">
<label for="inputNoiseHumidityPersistence">Persistence:</label>
<input id="inputNoiseHumidityPersistence" type="number" value="0.5" step=0.1>
2023-10-21 22:44:09 +02:00
<h3>Reset</h3>
<button id="inputNoiseReset" type="button">Reset noise parameters</button>
2023-10-21 17:12:43 +02:00
</form>
</div>
</div>
2023-10-21 22:44:09 +02:00
</div>
</div>
2023-10-21 23:45:40 +02:00
<hr>
<div class="contentContainer">
<!-- footer -->
2023-10-22 01:41:00 +02:00
<p>Need help? Read the <a title="Manual for the Minetest Biome Point Visualizer" href="./manual.html">manual</a>.</p>
2023-10-21 23:45:40 +02:00
<p>This is free software released under the <a title="MIT License" href="./license.html">MIT License</a>. Code by <a title="Wuzzys Personal Website" href="https://wuzzy.codeberg.page/">Wuzzy</a>. Uses <a title="Javascript-Voronoi Git repository webpage" href="https://github.com/gorhill/Javascript-Voronoi/">Javascript-Voronoi</a> by <a title="Raymond Hills personal website" href="http://www.raymondhill.net/">Raymond Hill</a>.</p>
</div>
2023-10-23 01:48:15 +02:00
<!-- The main script handling all the UI stuff -->
<script src="./mibpov.js"></script>
2023-10-20 02:54:39 +02:00
</body>
</html>