Unofficial Hacker News client - receive Push Notifications on replies.

Cloth Simulation with XBPD (opens external site)

60 points by ricardobeat 3 days ago | ricar.do | 19 comments on HN | Vote on HN (opens Hacker News)

View full thread · View on Hacker News

Comment thread (4)

  1. The Handkerchiefs demo is pretty sweet. How could you do that light/flare through the windows?

    Nice demos, indeed.

    Replies (3)
    1. If it's shadowmap based lighting you can trace through it.

      Imagine a ray from the camera to the background pixel, sample the shadowmap along the way if the sample points along the camera ray lies within the shadowmap and add light if the shadowmap depth is further away (simplified, depending on number of lights,etc there's a number of possible optimizations but that should be googleable).

    2. light through the window looks like standard volumetric rendering, a custom lens flare effect, and some (not sure if physically accurate) blooming of image values beyond the dynamic range in this scene.
    3. Thank you :)

      The light uses a froxel volumetric fog [1] implementation. The flares are bloom + a rendering from the camera POV, the lens reflection reprojected a few times.

      [1] https://www.mattiasstrand.com/posts/volumetric-fog/