]> git.scottworley.com Git - nt3d/blobdiff - box_by_extrude.html
Flip the order of shape,path in extrude args
[nt3d] / box_by_extrude.html
index 6a883a60eb7e9fb6b04f1809f51d5a0c2e3df048..be95de64ade3309ee6f56697df71f964afbfb73b 100644 (file)
@@ -3,14 +3,13 @@
     <title>Box by extrude</title>
     <script type="text/javascript" src="nt3d.js"></script>
     <script type="text/javascript">
-      function box_by_extrude(size_as_string) {
-        var size = parseFloat(size_as_string);
+      function box_by_extrude(size) {
         var origin = [0,    0,    0];
         var x      = [size, 0,    0];
         var y      = [0,    size, 0];
         var xy     = [size, size, 0];
-       return nt3d.extrude([origin, x, xy, y],
-                           [[0, 0, 0], [0, 0, 1]],
+       return nt3d.extrude([[0, 0, 0], [0, 0, 1]],
+                           [origin, x, xy, y],
                            [[0, 0, 1], [0, 0, 1]],
                            [[1, 0, 0], [1, 0, 0]]);
       }