
Henrai
The Ray Tracer Challenge: Cannot get rid of acne When implement Shadows in Chapter 8.
Hi, I’m working on the Chapter 8 of the book.
After I add add the point_offset, I’m still able to see acne:
In the image above, I remove all balls to make things easier. I notice that for some of the hit point falls into the walls. Therefore it will have very small t (but greater than the epsilon) for the intersection.
I make all tests pass except “The Color with an intersection behind the ray”. Could some one explain that why this case can pass with the shadow? I think the light should be blocked by the outer ball.
May I get some suggestion to debug my code?
Here is my github repo: GitHub - Henrai/TheRayTracingChallenge
Most Liked

hoozifachi
It’s cool. I completely understand. I can see the thread now. Thank you very much. My image looks almost exactly like the one in the thread. So it should be very helpful.
Popular Prag Prog topics









Modern front-end development for Rails, second edition - Struggling to get the first chapter to work

Other popular topics










Latest in PragProg
Latest (all)
Categories:
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /js
- /rails
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /java
- /haskell
- /emacs
- /svelte
- /onivim
- /typescript
- /crystal
- /c-plus-plus
- /tailwind
- /kotlin
- /gleam
- /react
- /flutter
- /elm
- /ocaml
- /vscode
- /opensuse
- /ash
- /centos
- /php
- /deepseek
- /scala
- /zig
- /html
- /debian
- /nixos
- /lisp
- /agda
- /sublime-text
- /textmate
- /react-native
- /kubuntu
- /arch-linux
- /revery
- /ubuntu
- /manjaro
- /django
- /spring
- /diversity
- /lua
- /nodejs
- /julia
- /slackware
- /c
- /neovim