xxxxxxxxxx
45
<html lang="en">
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/1.1.9/p5.js"></script>
<link rel="stylesheet" href="https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
<link rel="stylesheet" href="/resources/demos/style.css">
<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/1.1.9/addons/p5.sound.min.js"></script>
<link rel="stylesheet" type="text/css" href="style.css">
<meta charset="utf-8" />
</head>
<body>
<script src="segmentTree.js"></script>
<script src="sketch.js"></script>
<script>
$( function() {
$( "#slider-range" ).slider({
range: true,
min: segTreeSize[0],
max: segTreeSize[1],
values: segTreeSize,
slide: function( event, ui ) {
searchSpace = ui.values;
}
});
$("#selected_node_value").change(function(){
if (selected_node != -1)
{
segTree.update(selected_node, parseInt($("#selected_node_value").val()));
}
});
} );
</script>
<div class="ui-elements">
<div id="slider-range"></div>
<br />
<center>
<span id="selected_node">Update Selected Node Value : </span><input id="selected_node_value" type="number"/>
</center>
</div>
</body>
</html>