<commit_before><!DOCTYPE html>
<html lang="en">
<head>
    <title>xeoEngine Example</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">

    <style>
        body {
            margin: 0;
            -moz-user-select: -moz-none;
            -khtml-user-select: none;
            -webkit-user-select: none;
        }
    </style>

    <link href="css/styles.css" rel="stylesheet"/>

    <script src="lib/dat.gui.min.js"></script>
    <link type="text/css" rel="stylesheet" href="css/dat-gui-swec.css">

    <script src="../build/xeoengine.js"></script>

<body>

<div id="infoDark">
    <a href="http://xeoengine.org" target="_other">xeoEngine</a>
    <br><br><a href="../docs/classes/Heightmap.html"
               target="_other">Heightmap</a>
</div>
<div id="dat-gui-container">
</div>

<script>

    //------------------ Scene definition --------------------

    var heightmap = new XEO.Heightmap({
        primitive: "triangles",
        src: "textures/heightMap2.png",
        xSize: 10,
        ySize: 10,
        zSize: 5,
        xSegments: 70,
        ySegments: 70,
        lod: 1.0, // Default
        autoNormals: true // Default
    });

    var diffuseMap = new XEO.Texture({
        src: "textures/uvGrid2.jpg"
    });

    var object = new XEO.GameObject({
        geometry: heightmap,
        material: new XEO.PhongMaterial({
            diffuseMap: diffuseMap,
            pointSize: 3
        })
    });

    object.worldBoundary.visible = true;

    // Position camera

    var view = object.scene.camera.view;

    view.zoom(2);
    view.rotateEyeX(-60);
    view.rotateEyeY(-20);

    // Let user move camera

    new XEO.CameraControl();

    //------------------ GUI ---------------------------------

    var Menu = function () {

        this.message = "heightmap";

        this["primitive"] = heightmap.primitive;
        this["src"] = heightmap.src.substring("textures/".length);
        this["xSize"] = heightmap.xSize;
        this["ySize"] = heightmap.ySize;
        this["zSize"] = heightmap.zSize;
        this["xSegments"] = heightmap.xSegments;
        this["ySegments"] = heightmap.ySegments;
        this["autoNormals"] = heightmap.autoNormals;
        this["lod"] = heightmap.lod;
        this["texture"] = true;

        var self = this;

        // This is actually quite inefficient because it continually updates
        // the scene graph, forcing frames to continually re-render.
        // Your GPU's not going to like it, but it's just for a quick and dirty demo.

        var textured = true;

        var update = function () {

            heightmap.primitive = self["primitive"];
            heightmap.src = "textures/" + self["src"];
            heightmap.xSize = self["xSize"];
            heightmap.ySize = self["ySize"];
            heightmap.zSize = self["zSize"];
            heightmap.xSegments = self["xSegments"];
            heightmap.ySegments = self["ySegments"];
            heightmap.lod = self["lod"];
            heightmap.autoNormals = self["autoNormals"];

            requestAnimationFrame(update);
        };

        update();
    };

    var gui = new dat.GUI({autoPlace: false});

    document.getElementById('dat-gui-container').appendChild(gui.domElement);

    var menu = new Menu();

    var folder = gui.addFolder('heightmap');
    folder.add(menu, 'primitive', ["triangles", "lines", "points"]);
    folder.add(menu, 'src', [
        "heightMap1.jpg",
        "heightMap2.png",
        "heightMap2.jpg"
    ]);
    folder.add(menu, 'xSize', 0.1, 10.0);
    folder.add(menu, 'ySize', 0.1, 10.0);
    folder.add(menu, 'zSize', 0.1, 10.0);
    folder.add(menu, 'xSegments', 1, 70);
    folder.add(menu, 'ySegments', 1, 70);
    folder.add(menu, 'lod', 0.1, 1.0);
    folder.add(menu, 'autoNormals');
    folder.add(menu, 'texture');

    folder.open();

</script>
</body>
</html><commit_msg>Example tweak<commit_after><!DOCTYPE html>
<html lang="en">
<head>
    <title>xeoEngine Example</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">

    <style>
        body {
            margin: 0;
            -moz-user-select: -moz-none;
            -khtml-user-select: none;
            -webkit-user-select: none;
        }
    </style>

    <link href="css/styles.css" rel="stylesheet"/>

    <script src="lib/dat.gui.min.js"></script>
    <link type="text/css" rel="stylesheet" href="css/dat-gui-swec.css">

    <script src="../build/xeoengine.js"></script>

<body>

<div id="infoDark">
    <a href="http://xeoengine.org" target="_other">xeoEngine</a>
    <br><br><a href="../docs/classes/Heightmap.html"
               target="_other">Heightmap</a>
</div>
<div id="dat-gui-container">
</div>

<script>

    //------------------ Scene definition --------------------

    var heightmap = new XEO.Heightmap({
        primitive: "triangles",
        src: "textures/heightMap2.png",
        xSize: 10,
        ySize: 10,
        zSize: 5,
        xSegments: 70,
        ySegments: 70,
        lod: 1.0, // Default
        autoNormals: true // Default
    });

    var diffuseMap = new XEO.Texture({
        src: "textures/uvGrid2.jpg"
    });

    var object = new XEO.GameObject({
        geometry: heightmap,
        material: new XEO.PhongMaterial({
            diffuseMap: diffuseMap,
            pointSize: 3
        })
    });

    object.worldBoundary.visible = true;

    // Position camera

    var view = object.scene.camera.view;

    view.zoom(2);
    view.rotateEyeX(-60);
    view.rotateEyeY(-20);

    // Let user move camera

    new XEO.CameraControl();

    //------------------ GUI ---------------------------------

    var Menu = function () {

        this.message = "heightmap";

        this["primitive"] = heightmap.primitive;
        this["src"] = heightmap.src.substring("textures/".length);
        this["xSize"] = heightmap.xSize;
        this["ySize"] = heightmap.ySize;
        this["zSize"] = heightmap.zSize;
        this["xSegments"] = heightmap.xSegments;
        this["ySegments"] = heightmap.ySegments;
        this["autoNormals"] = heightmap.autoNormals;
        this["lod"] = heightmap.lod;

        var self = this;

        // This is actually quite inefficient because it continually updates
        // the scene graph, forcing frames to continually re-render.
        // Your GPU's not going to like it, but it's just for a quick and dirty demo.

        var textured = true;

        var update = function () {

            heightmap.primitive = self["primitive"];
            heightmap.src = "textures/" + self["src"];
            heightmap.xSize = self["xSize"];
            heightmap.ySize = self["ySize"];
            heightmap.zSize = self["zSize"];
            heightmap.xSegments = self["xSegments"];
            heightmap.ySegments = self["ySegments"];
            heightmap.lod = self["lod"];
            heightmap.autoNormals = self["autoNormals"];

            requestAnimationFrame(update);
        };

        update();
    };

    var gui = new dat.GUI({autoPlace: false});

    document.getElementById('dat-gui-container').appendChild(gui.domElement);

    var menu = new Menu();

    var folder = gui.addFolder('heightmap');
    folder.add(menu, 'primitive', ["triangles", "lines", "points"]);
    folder.add(menu, 'src', [
        "heightMap1.jpg",
        "heightMap2.png",
        "heightMap2.jpg"
    ]);
    folder.add(menu, 'xSize', 0.1, 10.0);
    folder.add(menu, 'ySize', 0.1, 10.0);
    folder.add(menu, 'zSize', 0.1, 10.0);
    folder.add(menu, 'xSegments', 1, 70);
    folder.add(menu, 'ySegments', 1, 70);
    folder.add(menu, 'lod', 0.1, 1.0);
    folder.add(menu, 'autoNormals');

    folder.open();

</script>
</body>
</html>
{'fraction_non_alphanumeric': 0.17949370309120977, 'fraction_numerical': 0.013484289530594072, 'mean_word_length': 2.1173671689135607, 'pattern_counts': {'":': 0, '<': 63, '<?xml version=': 0, '>': 63, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5302587', 'n_tokens_mistral': 2604, 'n_tokens_neox': 2456, 'n_words': 508}