Skip to content

Revisit handling of blending around shadow blobs in SfS #458

@oleg-alexandrov

Description

@oleg-alexandrov

In SfS, a region that is in shadow is considered to have no useful data, so SfS does does not happen in it. Then there is a transition area around it to terrain where SfS happens, to avoid a discontinuity. This results in some erosion or loss of detail around the region.

When many such small areas are present, the transition areas can end up eroding a lot of the good terrain produced with SfS. It is then preferable to do SfS in such a small hole and live with a little artifact than skip and erode around it.

This is controlled by parameter --min-blend-size. Regions in shadow whose both width and height are less than this are considered acceptable to do SfS in. For bigger shadow regions, SfS is not done.

The question is, is defining a region to be small by its width and height the right thing? What if there is a long and narrow shadow? Maybe it is better to do SfS there too, and not erode around it.

This will be looked into when there is a solid testcase to illustrate the problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions