abouttreesummaryrefslogcommitdiff
diff options
context:
space:
mode:
authorpatrick-scho2025-04-17 22:22:14 +0200
committerpatrick-scho2025-04-17 22:22:14 +0200
commit959c350fb8cddf7d1b31907fcc1f7f99dad52f3e (patch)
treece2f5e05082aa0536bad3d87dce424a3d3b2db93
parentf97f4ee25759ffaa6a4d4709f45fc8b7b5b24973 (diff)
downloadcloth_sim-959c350fb8cddf7d1b31907fcc1f7f99dad52f3e.tar.gz
cloth_sim-959c350fb8cddf7d1b31907fcc1f7f99dad52f3e.zip
restructureHEADmain
-rw-r--r--3D-Models/3D-Models.txt0
-rw-r--r--Paper and Presentation/Cloth_simulation_Paper.pdfbin615566 -> 0 bytes
-rw-r--r--img/hsrm.jpg (renamed from Textures/hsrm.jpg)bin22589 -> 22589 bytes
-rw-r--r--img/hsrm.png (renamed from Textures/hsrm.png)bin10172 -> 10172 bytes
-rw-r--r--img/hsrm2.png (renamed from Textures/hsrm2.png)bin36221 -> 36221 bytes
-rw-r--r--img/tears_of_steel_bridge_2k.jpg (renamed from Textures/tears_of_steel_bridge_2k.jpg)bin371116 -> 371116 bytes
-rw-r--r--index.html8
-rw-r--r--js/OrbitControls.js (renamed from Scripts/OrbitControls.js)0
-rw-r--r--js/Script.txt (renamed from Scripts/Script.txt)0
-rw-r--r--js/_cloth.js (renamed from Scripts/_cloth.js)0
-rw-r--r--js/_main.js (renamed from Scripts/_main.js)0
-rw-r--r--js/cloth.js (renamed from Scripts/cloth.js)2
-rw-r--r--js/main.js (renamed from Scripts/main.js)4
-rw-r--r--js/three.js (renamed from Scripts/three.js)0
-rw-r--r--js/three.module.js (renamed from Scripts/three.module.js)0
-rw-r--r--pdf/Cloth_simulation_Presentation.pdf (renamed from Paper and Presentation/Cloth_simulation_Presentation.pdf)bin1096616 -> 1096616 bytes
16 files changed, 7 insertions, 7 deletions
diff --git a/3D-Models/3D-Models.txt b/3D-Models/3D-Models.txt
deleted file mode 100644
index e69de29..0000000
--- a/3D-Models/3D-Models.txt
+++ /dev/null
diff --git a/Paper and Presentation/Cloth_simulation_Paper.pdf b/Paper and Presentation/Cloth_simulation_Paper.pdf
deleted file mode 100644
index 84dc1b9..0000000
--- a/Paper and Presentation/Cloth_simulation_Paper.pdf
+++ /dev/null
Binary files differ
diff --git a/Textures/hsrm.jpg b/img/hsrm.jpg
index fddffd8..fddffd8 100644
--- a/Textures/hsrm.jpg
+++ b/img/hsrm.jpg
Binary files differ
diff --git a/Textures/hsrm.png b/img/hsrm.png
index 8945965..8945965 100644
--- a/Textures/hsrm.png
+++ b/img/hsrm.png
Binary files differ
diff --git a/Textures/hsrm2.png b/img/hsrm2.png
index 6b83d6b..6b83d6b 100644
--- a/Textures/hsrm2.png
+++ b/img/hsrm2.png
Binary files differ
diff --git a/Textures/tears_of_steel_bridge_2k.jpg b/img/tears_of_steel_bridge_2k.jpg
index bf311a3..bf311a3 100644
--- a/Textures/tears_of_steel_bridge_2k.jpg
+++ b/img/tears_of_steel_bridge_2k.jpg
Binary files differ
diff --git a/index.html b/index.html
index de3e51b..a1d5962 100644
--- a/index.html
+++ b/index.html
@@ -9,14 +9,14 @@
margin: 0;
}
</style>
- <script src="./Scripts/three.js"></script>
- <script src="./Scripts/OrbitControls.js"></script>
+ <script src="/projects/cloth/js/three.js"></script>
+ <script src="/projects/cloth/js/OrbitControls.js"></script>
</script>
</head>
<body>
- <script src="./Scripts/cloth.js"></script>
- <script src="./Scripts/main.js"></script>
+ <script src="/projects/cloth/js/cloth.js"></script>
+ <script src="/projects/cloth/js/main.js"></script>
<div id="threejscontainer"></div>
<div id="Output"></div>
diff --git a/Scripts/OrbitControls.js b/js/OrbitControls.js
index 54a09ef..54a09ef 100644
--- a/Scripts/OrbitControls.js
+++ b/js/OrbitControls.js
diff --git a/Scripts/Script.txt b/js/Script.txt
index e69de29..e69de29 100644
--- a/Scripts/Script.txt
+++ b/js/Script.txt
diff --git a/Scripts/_cloth.js b/js/_cloth.js
index 546f7d3..546f7d3 100644
--- a/Scripts/_cloth.js
+++ b/js/_cloth.js
diff --git a/Scripts/_main.js b/js/_main.js
index fc797c8..fc797c8 100644
--- a/Scripts/_main.js
+++ b/js/_main.js
diff --git a/Scripts/cloth.js b/js/cloth.js
index 712ed63..bd13951 100644
--- a/Scripts/cloth.js
+++ b/js/cloth.js
@@ -289,7 +289,7 @@ class Cloth {
blow(camPos, intersects) {
let face = intersects[0].face;
/** vector from cam to intersection (wind) */
- let dir = intersects[0].point.clone().sub(camPos).multiplyScalar(100);
+ let dir = intersects[0].point.clone().sub(camPos).multiplyScalar(50);
/** apply to all vertices of affected face */
this.masses[face.a].addForce(dir);
this.masses[face.b].addForce(dir);
diff --git a/Scripts/main.js b/js/main.js
index 1a30f7a..64900d3 100644
--- a/Scripts/main.js
+++ b/js/main.js
@@ -37,7 +37,7 @@ function setup_scene(canvasSpace) {
/** add scene background */
const loader = new THREE.TextureLoader();
const texture = loader.load(
- 'Textures/tears_of_steel_bridge_2k.jpg',
+ '/projects/cloth/img/tears_of_steel_bridge_2k.jpg',
() => {
const rt = new THREE.WebGLCubeRenderTarget(texture.image.height);
rt.fromEquirectangularTexture(renderer, texture);
@@ -85,7 +85,7 @@ function init() {
/** Create cloth and generate mesh */
const cloth = new Cloth(1, 0.5, 20, 20);
const clothGeometry = cloth.generateGeometry();
- const clothMaterial = new THREE.MeshStandardMaterial({ map: loader.load('Textures/hsrm2.png'), color: 0xffffff, side: THREE.DoubleSide, flatShading: false });
+ const clothMaterial = new THREE.MeshStandardMaterial({ map: loader.load('/projects/cloth/img/hsrm2.png'), color: 0xffffff, side: THREE.DoubleSide, flatShading: false });
//const clothMaterial = new THREE.MeshStandardMaterial({ color: 0xC70039, side: THREE.DoubleSide, flatShading: false });
const clothMesh = new THREE.Mesh(clothGeometry, clothMaterial);
scene.add(clothMesh);
diff --git a/Scripts/three.js b/js/three.js
index 7b0e892..7b0e892 100644
--- a/Scripts/three.js
+++ b/js/three.js
diff --git a/Scripts/three.module.js b/js/three.module.js
index a499d33..a499d33 100644
--- a/Scripts/three.module.js
+++ b/js/three.module.js
diff --git a/Paper and Presentation/Cloth_simulation_Presentation.pdf b/pdf/Cloth_simulation_Presentation.pdf
index 06cc45e..06cc45e 100644
--- a/Paper and Presentation/Cloth_simulation_Presentation.pdf
+++ b/pdf/Cloth_simulation_Presentation.pdf
Binary files differ