TA159

Notas, resueltos y trabajos practicos de la materia Sistemas Gráficos
Index Commits Files Refs Submodules README LICENSE
commit 93f0479fe4f48e60ab188dd1e5765f4c5fff49e0
parent 2fd561c23598560feae0b90d55619181852987d0
Author: Martin Kloeckner <mjkloeckner@gmail.com>
Date:   Thu, 27 Jun 2024 22:31:30 -0300

add function parameters to `generateBridge` call

Diffstat:
Mtp/src/scene.js | 19+++++++++++++++++--
1 file changed, 17 insertions(+), 2 deletions(-)
diff --git a/tp/src/scene.js b/tp/src/scene.js
@@ -106,8 +106,23 @@ function loadTextures(callback) {
 }
 
 function buildBridge() {
-    const bridge = generateBridge();
-    scene.add(bridge);
+    // const bridge1 = generateBridge();
+    // const bridge2 = generateBridge();
+
+    // (arcCount, arcRadius, columnWidth, columnHeight, padding, squaresCount, squareLen)
+    const bridge1 = generateBridge(1, 3, 0, 0, 10, 2, 2);
+    const bridge2 = generateBridge(2, 2, 1, 0, 15, 3, 2);
+
+    bridge1.scale.set(0.5, 0.5, 0.5);
+    bridge1.position.set(16, -0.75, 33);
+    // bridge1.rotateY(-Math.PI*0.118);
+
+    bridge2.scale.set(0.5, 0.5, 0.5);
+    bridge2.position.set(-14, 0, -40);
+    // bridge2.rotateY(-Math.PI*0.118);
+
+    scene.add(bridge1);
+    scene.add(bridge2);
 }
 
 // loco -> locomotora/locomotive