Web Interface For Lite Argus Control modules
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

39 lines
1.2 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Random Path Testing</title>
  6. <link rel="stylesheet" href="../css/style.css">
  7. <!-- IE 9: display inline SVG -->
  8. <meta http-equiv="X-UA-Compatible" content="IE=9">
  9. <script type="text/javascript" src="../../dist/paper-full.js"></script>
  10. <script type="text/paperscript" canvas="canvas">
  11. var center = new Point(100, 100);
  12. var sides = 3;
  13. var radius = 50;
  14. var triangle = new Path.RegularPolygon(center, sides, radius);
  15. triangle.fillColor = 'black';
  16. copy = triangle.clone();
  17. copy.strokeColor = 'blue';
  18. copy.rotate(45);
  19. var center = new Point(100, 300);
  20. var sides = 10;
  21. var radius = 50;
  22. var decahedron = new Path.RegularPolygon(center, sides, radius);
  23. decahedron.fillColor = 'black';
  24. var center = new Point(100, 400);
  25. var points = 6;
  26. var radius1 = 20;
  27. var radius2 = 50;
  28. var path = new Path.Star(center, points, radius1, radius2);
  29. path.fillColor = 'black';
  30. document.body.appendChild(project.exportSVG());
  31. </script>
  32. </head>
  33. <body>
  34. <canvas id="canvas" width="500" height="500"></canvas>
  35. </body>
  36. </html>