andreasala98 / NM4PIG

Numerical Methods for Photorealistic Image Generation
MIT License
2 stars 1 forks source link

Implement Point-Light Tracing #10

Closed andreasala98 closed 3 years ago

andreasala98 commented 3 years ago

This pull request is to keep track of the implementation of Point Light Tracing, a quink rendering algorithm. As this is a secondary feature for our project, we will implement this when we have time.

PietroKlausner commented 3 years ago

I'm sure the quickRayIntersection method for Box shapes can be optimized. Maybe @TommasoArmadillo can offer some precious insights.

andreasala98 commented 3 years ago

I'm sure the quickRayIntersection method for Box shapes can be optimized. Maybe @TommasoArmadillo can offer some precious insights.

He is the CEO of Boxes, after all.

TommasoArmadillo commented 3 years ago

Hi! @PietroKlausner, yes the could be optimized. In fact we don't need to compute all the intersections and then return true only if there is one or more intersections, but we can avoid some calculations. I just pushed a commit with this optimization. All the tests still pass correctly as expected!

PietroKlausner commented 3 years ago

Hi! @PietroKlausner, yes the could be optimized. In fact we don't need to compute all the intersections and then return true only if there is one or more intersections, but we can avoid some calculations. I just pushed a commit with this optimization. All the tests still pass correctly as expected!

Thank you very much!