processing-js
Version:
For the project website, visit http://processingjs.org
35 lines (30 loc) • 1.42 kB
HTML
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Ref Test Builder</title>
<style>
canvas { width: 100px; height: 100px; border: 1px solid }
</style>
</head>
<body onload="document.getElementById('code').focus()">
<h1>Ref Test Builder</h1>
<p>To build a ref test, put your code below, and place any images in test/ref/ so they can be preloaded by filename (e.g., preload="foo.png") with a relative path. Click Run to test your sketch, Generate Ref Test to build the test. Save the test to test/ref/ as well. Note: You <b>MUST</b> have an exit() call somewhere within your ref test.</p>
<p>To run the ref tests, click <a href="index.html">here</a>.
<h2>Processing Code</h2>
<textarea rows="20" cols="80" id="code"></textarea>
<div>
<br> <input onclick="runSketch(function(){});" type="button" value="Run"></input>
<input onclick="generateRefTest();" type="button" value="Generate Ref Test"></input>
</div>
<h2>Canvas</h2>
<div id="sketch-container">
<canvas id="sketch"></canvas>
</div>
<h2>Output</h2>
<textarea rows="20" cols="80" id="output" readonly="readonly">None.</textarea>
<script src="../../processing.js"></script>
<script src="../../tools/jsbeautify.js"></script>
<script src="../../tools/processing-helper.js"></script>
</body>
</html>