Minor change
This commit is contained in:
@@ -42,11 +42,6 @@ And to run the build:
|
||||
|
||||
You'll need an image viewer to view the PPM file. I used [feh](https://feh.finalrewind.org/).
|
||||
|
||||
# :scroll: To Do
|
||||
A list of things I wish to implement:
|
||||
- [ ] Triangle
|
||||
|
||||
|
||||
# :book: Resources Used
|
||||
[_Ray Tracing in One Weekend_](https://raytracing.github.io/books/RayTracingInOneWeekend.html)
|
||||
|
||||
|
4
camera.h
4
camera.h
@@ -94,9 +94,7 @@ class camera {
|
||||
// Construct a camera ray originating from the origin and directed at randomly sampled point around the pixel location i, j.
|
||||
|
||||
auto offset = sampleSquare();
|
||||
auto pixelSample = pixel00Location
|
||||
+ ((i + offset.x()) * pixelDeltaU)
|
||||
+ ((j + offset.y()) * pixelDeltaV);
|
||||
auto pixelSample = pixel00Location + ((i + offset.x()) * pixelDeltaU) + ((j + offset.y()) * pixelDeltaV);
|
||||
|
||||
auto rayOrigin = (defocusAngle <= 0) ? centre : defocusDiskSample();
|
||||
auto rayDirection = pixelSample - rayOrigin;
|
||||
|
Reference in New Issue
Block a user