From 34329bf8ef92bb53ac32c543c5e40e0e73ade3fd Mon Sep 17 00:00:00 2001 From: Cameron Reikes Date: Thu, 13 Jul 2023 16:25:07 -0700 Subject: [PATCH] No waviness, export directly to assets to decrease codegen time --- art/Exporter.py | 2 +- run_codegen.bat | 9 +-------- threedee.glsl | 4 ++-- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/art/Exporter.py b/art/Exporter.py index bca6f3a..43feed8 100644 --- a/art/Exporter.py +++ b/art/Exporter.py @@ -10,7 +10,7 @@ C = bpy.context D = bpy.data LEVEL_EXPORT_NAME = "level" -EXPORT_DIRECTORY = "exported" +EXPORT_DIRECTORY = "../assets/exported_3d/exported" print("\n\nLet's get it started") diff --git a/run_codegen.bat b/run_codegen.bat index 8e684f1..d1a7afe 100644 --- a/run_codegen.bat +++ b/run_codegen.bat @@ -1,14 +1,7 @@ -@echo off +@echo on echo Running codegen... -rmdir /S /q assets\copyrighted - -rmdir /S /q "assets\exported_3d" -mkdir "assets\exported_3d" || goto :error -copy "art\exported\*" "assets\exported_3d\" || goto :error -copy "art\gigatexture.png" "assets\exported_3d\gigatexture.png" || goto :error - rmdir /S /q gen mkdir gen diff --git a/threedee.glsl b/threedee.glsl index ce2ec3b..79b5656 100644 --- a/threedee.glsl +++ b/threedee.glsl @@ -105,13 +105,13 @@ uniform vs_params { }; void main() { - vec3 transformed_pos = vec3(pos_in.x, pos_in.y + sin(pos_in.x * 5.0 + pos_in.y * 9.0 + time*1.9)*0.045, pos_in.z); + //vec3 transformed_pos = vec3(pos_in.x, pos_in.y + sin(pos_in.x * 5.0 + pos_in.y * 9.0 + time*1.9)*0.045, pos_in.z); vec3 untransformed_world_pos = (model * vec4(pos_in, 1.0)).xyz; vec3 away = normalize(untransformed_world_pos - wobble_world_source); float t = time + seed; - //vec3 transformed_pos = pos_in + away * sin(t*20.0 + pos_in.y*3.0) * pos_in.y*0.25 * wobble_factor * 0.0; + vec3 transformed_pos = pos_in + away * sin(t*20.0 + pos_in.y*3.0) * pos_in.y*0.25 * wobble_factor * 0.0; pos = transformed_pos; uv = uv_in;