-
Notifications
You must be signed in to change notification settings - Fork 949
Description
In the current book (also in dev-major branch), the value for the noise texture looks like this
return color(1,1,1) * 0.5 * (1 + sin(scale*p.z() + 10*noise.turb(p)));Here the z coordinate of the p is scaled, but the p itself when it is passed to noise.turb is not. Therefore the turbulence is not scaled with the texture as it should be (one can also see it in the final image, where instead of a nice marble texture one sees some white noise). I think the correct line would be
return color(1,1,1) * 0.5 * (1 + sin(scale*p.z() + 10*noise.turb(scale * p)));With this change, one gets a nice marble texture in the final render, like here: https://github.com/mu-lambda/mu-lambda-raytracer/blob/main/final_scene.jpg
There is a related issue #425 : the picture would look even better if the noise was aligned along different axis: when one aligns along z, the unnatural con-axed circles on the marble surface are apparent.