From 8522d61351796b1c88c41bfc2b8b4fa130c73371 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Mon, 28 Aug 2023 13:09:29 +0300 Subject: [WGL/P] Improved wording --- Year 2/Computer Graphics with WebGL/Project/level.js | 4 ++-- Year 2/Computer Graphics with WebGL/Project/shaders.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Year 2/Computer Graphics with WebGL/Project/level.js b/Year 2/Computer Graphics with WebGL/Project/level.js index 2a525d2..83311c0 100644 --- a/Year 2/Computer Graphics with WebGL/Project/level.js +++ b/Year 2/Computer Graphics with WebGL/Project/level.js @@ -102,14 +102,14 @@ Level.prototype.load = function() { function createLevels() { var l1 = new Level( "Star passing behind black hole", - "You can see how the black hole (correctly) warps the light of the star behind it when it passes", + "You can see how the black hole (correctly) warps the light of the star, when it passes from behind.", [1000,0,650]); l1.addStar([1100,0,1000], 10, (t, star) => vecSum(star.center, [-100 * (1 + Math.sin(t/30 + 1.5 * Math.PI)),0,0])); l1.addBlackHole([1000,0,900], 30, undefined); var l2 = new Level( "Star gets closer to event horizon", - "As the star passes by behind the black hole, we can see it approaching the event horizon, however, it will never pass it and continue becoming thinner and taller (at least until we can calculate and show it).", + "Now the camera is very close to the event horizon, looking at the same direction as the previous level. As the star passes behind the black hole, we can see it approaching the event horizon, however, it will never pass it and will continue becoming thinner and taller (at least until we can calculate and show it).", [1014,0,892]); l2.addStar([1070,0,1000], 10, (t, star) => vecSum(star.center, [-t,0,0])); l2.addBlackHole([1000,0,900], 30, undefined); diff --git a/Year 2/Computer Graphics with WebGL/Project/shaders.js b/Year 2/Computer Graphics with WebGL/Project/shaders.js index bd98880..86c6faf 100644 --- a/Year 2/Computer Graphics with WebGL/Project/shaders.js +++ b/Year 2/Computer Graphics with WebGL/Project/shaders.js @@ -53,8 +53,8 @@ var fShader = ` // Settings uniform bool uDisableRayMarching; - uniform vec4 uBlack; - uniform vec4 uBHBlack; + uniform vec4 uBlack; // color when ray doesn't hit anything (or hits the skybox) + uniform vec4 uBHBlack; // color when ray doesn't escape the black hole // For ray marching uniform vec4 uStars[`+STAR_MAX_COUNT+`]; -- cgit v1.3.1-23-gd82d