Coder Social home page Coder Social logo

Comments (1)

erichlof avatar erichlof commented on July 30, 2024 1

@gijsbel
Hi, thank you for bringing this error to my attention! A couple of years back I learned how to do depth of field and different apertures from this old project .

They indeed have the randomRadius square rooted. Now that I have most of the components for a path tracer working, I'm going back and studying books and papers like Peter Shirley's classic "Realistic Ray tracing, 2nd edition", and the online "GI Compendium" in pdf format. I'm trying to learn all the intricacies of Monte Carlo integration, sampling and reconstruction, and why they all work inside path tracers. One of the things I recently learned is that sampling a disk with uniform random variables (0.0 - 1.0) does not give a uniform sampling of the disk or sphere (as you pointed out), but square rooting the radius' random number helps push the samples out from the middle where they would get too clumped if not square rooted.

I have updated the pathtracingCommon.js file and all the animated demos that use their own main function that contains the aperture code. I'll go ahead and close this issue out now that it has been fixed repo-wide. Thanks again!
-Erich

from three.js-pathtracing-renderer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.