Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shadow feature and MAX TEXTURE IMAGE UNITS limitation #35

Closed
lesydat opened this issue Aug 11, 2021 · 10 comments
Closed

Shadow feature and MAX TEXTURE IMAGE UNITS limitation #35

lesydat opened this issue Aug 11, 2021 · 10 comments
Labels
bug Something isn't working

Comments

@lesydat
Copy link

lesydat commented Aug 11, 2021

Can you fix light through walls when turn on light?

@lesydat lesydat added the bug Something isn't working label Aug 11, 2021
@adizanni
Copy link
Owner

adizanni commented Aug 13, 2021

Hello, starting from recent release, the problem has been fixed by setting the shadow parameter to 'yes'.
Note that the shadow feature is very greedy in PC resources so you may want to see if this is applicable to your model based on the complexity. Also be aware that, at today, the activation of shadow may have some collateral effect on the lights. To workaround the issue I now give the possibility to set the vertical alignment of the light inside the bound object. This gives the possibility to make a light appear in the case it is shaded by the light object itself.
Please try it and let me know if it works for you.

@lesydat
Copy link
Author

lesydat commented Aug 13, 2021

Turn on shadow make my home model can't load. I use Firefox and my laptop only has Intel graphic

@adizanni
Copy link
Owner

I suspect your problem is similar to the following #36.
Can you please activate the logs and paste here the console content here ? This can be achieved by opening the Web Developer Tools in the Firefox menu

@adizanni
Copy link
Owner

adizanni commented Aug 16, 2021

Hello lesydat, please post here the snapshot of the screen you will find here https://browserleaks.com/webgl or here https://webglreport.com/?v=1
This shows the limits you have on your browser related to the number of supported THREE.js (WebGL) objects.

@lesydat
Copy link
Author

lesydat commented Aug 16, 2021

@adizanni
This is screenshot when turn on shadow
Floor_plan_-_Home_Assistant

Turn off shadow
Floor_plan_-_Home_Assistant

Console log when turn on shadow
Screen Shot 2021-08-17 at 00 02 11

WebGL browser check
browserleaks-webgl-2021_08_16_23_59_52

@adizanni
Copy link
Owner

So, before I see how to optimize the usage of lights and shadows, you will not be able to put more than 16 (Max Texture Image Unit in your WebGL report) lights into your model. I keep it open for further investigations

@adizanni adizanni changed the title Light through walls Shadow feature and MAX TEXTURE IMAGE UNITS limitation Aug 17, 2021
@adizanni
Copy link
Owner

Added a new task in project 2.0 to see how to handle lights to consume less GPU resources. Closing the issue as the behaviour of the card is according to THREE.js and WebGL limitation

@geolos
Copy link

geolos commented Aug 25, 2021

Sorry for my late reply (I come from issue #36). I also confirm that with the shadow set to 'no' the 3D model appears normal. I also attach my WebGL browser check just for reference.
browser_webGL.pdf

@adizanni
Copy link
Owner

Yes geolos, and do you confirm that you had more than 16 lights defined ?

@geolos
Copy link

geolos commented Aug 26, 2021

Yes I confirm that the lights were more than 16 (and with shadow set to yes there was a problem). When I reduced them the model appeared ok. In both cases the model remained the same; with the same number of textures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants