Giter Club home page Giter Club logo

Comments (8)

matheusmdx avatar matheusmdx commented on September 26, 2024 2

It might be worth turning off tighter shadow culling in project settings advanced , rendering lights and shadows, to check whether this is a regression due to tighter culling.

I can confirm disabling tighter shadow culling stops the flickering

from godot.

lawnjelly avatar lawnjelly commented on September 26, 2024 2

Getting clues now. It seems to be due to the spotlight being attached to the camera, at 0, 0 on the y and z axis.

The light position is therefore on the exact boundary for the top and bottom camera frustum planes, and sometimes the distance check is returning +0 and sometimes -0 due to float inaccuracy.

This may need an epsilon to prevent this edge condition.

UPDATE:
It looks like this can be solved just be increasing the colinearity epsilon a bit (I did have it set to a deliberately very low value, partly because once you increase it, you never know whether it can be lower).

Whether borderline frustum planes should be considered back facing is another matter, but this seems more like a question of slightly increasing efficiency, rather than affecting accuracy.

I'll make PR soon, I just want to check there aren't any other additions to make it more robust.

from godot.

lawnjelly avatar lawnjelly commented on September 26, 2024

It might be worth turning off tighter shadow culling in project settings advanced , rendering lights and shadows, to check whether this is a regression due to tighter culling.

If so I can investigate saturday. There is currently a known bug with directional lights in dev6, but spots and omnis no bugs currently reported.

from godot.

catboy-catfish avatar catboy-catfish commented on September 26, 2024

It might be worth turning off tighter shadow culling in project settings advanced , rendering lights and shadows, to check whether this is a regression due to tighter culling.

If so I can investigate saturday. There is currently a known bug with directional lights in dev6, but spots and omnis no bugs currently reported.

It might be worth turning off tighter shadow culling in project settings advanced , rendering lights and shadows, to check whether this is a regression due to tighter culling.

I can confirm disabling tighter shadow culling stops the flickering

Just tried this out, it does seem to solve the flickering issue, but apparently tighter shadow caster culling can increase performance, which is exactly what I want. Maybe tighter shadow caster culling could be set separately for each light? Maybe we could add the option's 'flickering' issue in the docs.

from godot.

matheusmdx avatar matheusmdx commented on September 26, 2024

@catboy-catfish Don't worry, this was just to know where the problem started, is not the final solution. As lawnjelly said this will be investigated to make work with tighter shadow culling

from godot.

catboy-catfish avatar catboy-catfish commented on September 26, 2024

@catboy-catfish Don't worry, this was just to know where the problem started, is not the final solution. As lawnjelly said this will be investigated to make work with tighter shadow culling

Cool cool, maybe I could make a proposal out of this

from godot.

lawnjelly avatar lawnjelly commented on September 26, 2024

Re-opening as this is not fixed yet. Disabling was to identify the bug, not to fix.

from godot.

lawnjelly avatar lawnjelly commented on September 26, 2024

First step was making a more usable MRP, then converting to 3.x:
spotlight_tight_cull_bug.zip

from godot.

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.