Skip to content

Implement DepthOfFieldEffect #569

Open

Description

@vanruesc

Description

Implement a DepthOfFieldEffect based on the implementation in v6.

References:

Tasks

  • Create CoC shader.
  • Create blur shader.
  • Create DepthOfFieldEffect.
  • Create depth-of-field demo.
  • Add unit test.

Implementation Details

  • Check the linked article for potential improvements.
  • Should be done after PoissonBlurMaterial has been implemented.
  • The CoC should be calculated based on fragment distance instead of depth.
  • Add support for logarithmic depth.
  • Consider adding options for fringe/chromatic aberration and luminance gain.

Activity

  1. added this to the v7 milestone on Feb 11, 2024
  2. clicktodev commented on Apr 30, 2025

    @clicktodev

    what's the difference this and the v6 implementation?

  3. vanruesc commented on May 1, 2025

    @vanruesc
    MemberAuthor

    Support for log depth and inversed depth, better configuration options and more natural circle of confusion based on distance instead of linear depth. There may also be some other aspects that can be improved based on the linked article.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions