Why Ray Tracing?

光栅化不太好去表示一些全局的效果。

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/482d7ccc-9bc4-49a0-877c-02bf7dd3008a/Untitled.png

地图大,整个地图渲染非常耗,质量较低。

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/6cf8017b-a2d1-4d7b-8210-848584b7e52e/Untitled.png

Ray tracing is accurate, but is very slow

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/7153bf5f-be6f-40b8-afac-7824a86a818b/Untitled.png

Basic Ray-Tracing Algorithm

Light Rays

Three ideas about light rays

  1. Light travels in straight lines (though this is wrong)
  2. Light rays do not “collide” with each other if they cross (though this is still wrong)
  3. Light rays travel from the light sources to the eye (but the physics is invariant under path reversal - reciprocity). 光线的可逆性,可以认为眼镜发出感知的光线,最后打到光源。

“And if you gaze long into an abyss, the abyss also gazes into you.” — Friedrich Wilhelm Nietzsche (translated)

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/7bedc05e-8aff-4e08-b9ec-e4c7ddd96a8a/Untitled.png

虽然是错的,但可以这么理解。从相机(我们的眼镜)出发,往世界中投放光线,光线在弹来弹去之后到达光源。(光追中“追踪”的意思)

Ray Casting