Jump to content

[SOLVED] world portal vs sun


photo

Recommended Posts

Under some conditions (distance from portal, angle of view) world portal lets sun inside the closed room even in case, that sun light is parallel with portal opening. I ve prepared three screenshots (portal on/off, distance from portal, camera rotation). Direction of sun is marked by yellow arrow:

 

http://www.endor.cz/demo/portal.png- turning portal off fixes the light (sun on)

 

http://www.endor.cz/demo/portal2.png- opposite direction - few steps more inside and from this angle lightning is OK (sun on)

 

http://www.endor.cz/demo/portal3.png - rotation of camera several degrees (sun on)

 

Turning sun off also "fixes" the light, but this is not solution.

Link to comment

I ve managed to export impacted part of world into single node via node export tool, imported into empty world with same render settings and uploaded it to your ftp (test.rar).

 

Btw, there is issue with node import, when I imported created node into world as reference node or node, only sun appeared in the node structure. When I imported as layer node, everything was OK, so you have it in the world as layer node. But import deserves check too, it seems there is also problem.

Link to comment

Hi,

 

Could you please try to adjust portal's height via WorldPortal manipulator (just move Z axis down until sun light will disappear)? Also, have you tried to adjust height it in template.world?

 

portal_.png

 

I'm using DX11 API. Sun is blocked by portal correctly when I changed portal's height.

 

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

Hi,

 

Could you please try to adjust portal's height via WorldPortal manipulator (just move Z axis down until sun light will disappear)? Also, have you tried to adjust height it in template.world?

 

attachicon.gifportal_.png

 

I'm using DX11 API. Sun is blocked by portal correctly when I changed portal's height.

 

Thanks!

 

In template.world it works, but it is limited testcase (without outside world). In whole scene situation is different. If I make portal high enough (portal will go outside of its sector box), it really solves problem with light, but it will no longer display scenery outside of portal (technically portal stops working). Sun is blocked by building itself, problem is, that portal is letting in light and also shadows, which should never go inside no matter of sun position.

Link to comment

Hi,

 

I'm afraid in this case the most efficient solution would be to configure the surfaces to ignore the world light via light mask and setup the inner lights with different light masks.

 

Thanks for tip. There is small problem, we are using these nodes both inside and outside, which means to prepare special set for these cases, and rebuild the scene, but as workaround it can be.

 

Fixing portal is not an option?

Link to comment

The portal itself works as expected. When camera is faced to the portal it will render all the objects that are located behind it (including the WorldLight that produces such issue). In the City demo we faced the same behavior with WorldLight.

 

You also can try to create invisible geometry near the exit to block the WorldLight first. If this doesnt help the light masks should do the trick.

 

Sorry for the inconvenience.

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

The portal itself works as expected. When camera is faced to the portal it will render all the objects that are located behind it (including the WorldLight that produces such issue). In the City demo we faced the same behavior with WorldLight.

 

You also can try to create invisible geometry near the exit to block the WorldLight first. If this doesnt help the light masks should do the trick.

 

Sorry for the inconvenience.

 

We probably dont understand each other. In this case world light is not comming through portal (this would be OK), because world light rays are almost parallel with portal opening. World light and shadows of objects outside oclusion zone are comming literally through walls and ceeling and it happens only in case when portal is active. So no invisible geometry near exit would help, there is nothing to block. Portal somehow causes, that walls/ceelings/floors are not blocking world light/shadows anymore.

Link to comment

Hi,

 

I made two screenshots that I believe can explain more. On the first screenshot (portal_inside.jpg) you can see the sun light through the portal, on the second screenshot (portal_outside.jpg) you can see how sun "see" the dungeon through the portal. So, this is really not a bug.

 

I can mislead you by suggesting to create invisible geometry near the exit (it is doesn't help in this case). An invisible ("shadow") geometry that covers whole dungeon and can be visible from inside and from outside will help in this case. Also changing the light mask parameter for the surfaces can do the job here.

 

Sorry for the inconvenience caused.

 

portal_inside.jpg portal_outside.jpg

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

Hi,

 

I made two screenshots that I believe can explain more. On the first screenshot (portal_inside.jpg) you can see the sun light through the portal, on the second screenshot (portal_outside.jpg) you can see how sun "see" the dungeon through the portal. So, this is really not a bug.

attachicon.gifportal_inside.jpg attachicon.gifportal_outside.jpg

 

I understand this and such behaviour is perfectly correct. Light through portal is indeed OK.

 

I just dont understand, why shadows of trees and objects (+world light) outside dungeon are visible inside of dungeon:

 

http://www.dropmocks.com/mICyiP   shadow of leaves of vegetation above.

 

 

It is like there are no walls and it depends on position of camera towards portal. If there is no portal, everything is perfectly OK, light is as it should be.

 

So does it mean, that sun simply does not "see" walls, because walls are inside of oclussion area? But why does this behaviour change with position of camera towards portal? This happens only in case portal is "active" (in camera frustum). So active portal enables sun to go inside of oclussion area, but sun does not see any objects inside, so it casts shadows on objects, which I see?

 

If I understand your workaround, such "light protection shell" should be outside oclussion sector (some double sided mesh)?

Link to comment

Btw, did you try this?

 

"there is issue with node import, when I imported created node into world as reference node or node, only sun appeared in the node structure. When I imported as layer node, everything was OK, so you have it in the world as layer node. But import deserves check too, it seems there is also problem."

 

It is easily reproducable in my test word. Just use menu create/import node, use node with dungeon (node which is linked now as layer node) and only sun will be imported instead of whole structure. Same for reference node. Only layer node works properly.

Link to comment

Hi,

 

there is issue with node import, when I imported created node into world as reference node or node, only sun appeared in the node structure. When I imported as layer node, everything was OK, so you have it in the world as layer node. But import deserves check too, it seems there is also problem.

The only way to Import such node for now is to use Node Layer - this a correct behavior. We will add support for imporing such nodes via usual Node Import (but not as NodeReference).

 

So active portal enables sun to go inside of oclussion area, but sun does not see any objects inside, so it casts shadows on objects, which I see?

Yes. Also it casts shadows from the objects like trees (that not occluded by WorldSectors).

 

If I understand your workaround, such "light protection shell" should be outside oclussion sector (some double sided mesh)?

Just reguar mesh will be enough. By configuring its viewport mask you can hide it from camera, but it would be still visible by the sun.

 

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment
×
×
  • Create New...