From 603603993a23435a2996989c8d1b955f944740db Mon Sep 17 00:00:00 2001
From: bill
Date: Wed, 24 Feb 2021 14:35:12 +0800
Subject: [PATCH] Release Candidate
---
README.md | 4 ++--
index.html | 27 ++++++++++-----------------
2 files changed, 12 insertions(+), 19 deletions(-)
diff --git a/README.md b/README.md
index d316435..0262c7f 100644
--- a/README.md
+++ b/README.md
@@ -1,2 +1,2 @@
-# graphics_hw1
-[link](https://billsun.dev/graphics/hw1)
+# graphics_hw2
+[link](https://billsun.dev/graphics/hw2)
diff --git a/index.html b/index.html
index 7480594..03424f2 100644
--- a/index.html
+++ b/index.html
@@ -58,25 +58,18 @@ Solar RTX
Here is how it works:
- - First, I added texture to the sphere. The code to load the texture is from
- here. Please wait a sec for the texture to download.
- - Then, I mapped the 3D sphere surface to the rectangular 2D texture picture.
- - I also make it look like it's rotating by adding uTime to the offset of the texture and reset the offset to 0 whenever it exceeds
- the width of the texture.
- - I used Perlin Noise to generate fake clouds.
- - I modified the lighting so that the light source won't move with the sphere and
- the lighting will change when the sphere moves. I also added specular lights to make it shinier.
- - I tried to add some 'soft shadow' to it. I used a mix of methods inspired by Ambient Occlusion and Ray Tracing.
+ - First, I started with what I've already done in homework 1. Which already included complete Phong shading with
+ Specular light and much more (spherical texture mapping, simple interactions, improved UI/shader editor).
+
+ - I then merged the code from hw2 and added texture to each sphere.
+ - I modified the ray tracing algorithm so that when hitting an object, instead of returning color calculated from
+ Phong model:
- - The Ambient lights and diffusion lights are reduced with respect to the distance between the background point and the sphere.
- - The specular light of the background wall is eliminated and the diffusion factor is reduced when the ray shooting from the background point
- towards the light source or from the background point towards the camera position intersect with the sphere.
+ - I recursively traced the light reflected and refract from the object.
+
- - I added basic interactions such as press ctrl + 't' key to hide/show texture, click on the above canvas to pause/unpause animations.
- Just a proof of concept.
- - Finally, I made some small changes like changing R over time and refined the UI a little bit. I used
- Ace for code highlighting and autocompletion on the edit panel.
- - Comments begin with '//*' are added by me.
+
+ - Finally, I used super sampling via doubling the render dimensions of the canvas to reduce aliasing.
- Repo on Github.