World Background IBL texture incorrect

Project:YafaRay
Component:YafaRay Core
Category:bug report
Priority:critical
Assigned:David Bluecame
Status:closed
Description

Hello,

During my tests while preparing the Material Preview with camera rotation I've found a bad problem in the world background.

There are two different issues happening, when using a background image texture:

* Artifacts in the image: I used a black texture with a yellow circle on it and when rendering the yellow circle has strange black artifacts.

* Incorrect IBL light position. This is bad: when using a background image texture in Angular mode and enablign IBL, the light from the IBL is in a DIFFERENT position respect to the texture!  This would cause the illumination in the scene NOT MATCHING the background texture!

I've checked with older YafaRay versions and both problems also happen. So, this seems to be a very old problem that for some reason went unnoticed?

I've attached an example (and very simple) blend file showing this problem. Please unpack the jpg texture before rendering.

AttachmentSize
world_bg_issues.blend535.74 KB
world_bg_issues.jpg106.02 KB

Comments

#1

As you can see in the image, the test scene is very simple, it just has:

* Sphere

* Texture background angular + IBL

Issues:

- The texture has black artifacts

- The sphere is illuminated by the IBL in the OPPOSITE! side of the Sphere respect to where the yellow spot is placed!

 

#2

Status:active» ready to commit

Hello,

It looks like this has been wrong, causing bad IBL illumination when using Angular textures for YEARS!  :-(

I've made some changes, one commit for each problem:

* Black artifacts: https://github.com/DavidBluecame/Core/commit/39c96a066bf9e5093e5b6fcf15c...

* Incorrect IBL lighting when using Angular: https://github.com/DavidBluecame/Core/commit/46329c8c77618cc445b13dd68d9...

I hope these changes solve these problems without causing new issues. The changes will be included in the upcoming YafaRay-E version 2.1.1

I've attached an image rendered with the changes. It looks ok without artifacts and without the weird IBL problem, and when I rotate the scene to check the IBL, it's apparently correct now.

 

world_bg_issues_ok.pngworld_bg_issues_ok.png

#3

VERY IMPORTANT: This IBL problem has affected the illumination (and therefore the realism) for all scenes rendered with World Background Texture in Angular mode for years.

One of the biggest problems is this: until this fix, when setting a World Background Texture in Angular mode:

- The glossy/specular components of the materials were showing the reflections CORRECTLY

- The diffuse components of the materials were illuminated IN THE WRONG PLACE by the IBL

This means that the objects had, until now, an incorrect material lighting grossly reducing the realism in the scenes.

I hope this change improves the realism and lightning of the objects and materials from now on. Please let me know how this works for you.

#4

I've uploaded another .blend scene (please download the HDRI texture "probe_foyer_FINAL.hdr" I used from its original website http://www.unparent.com/gallery_probeFoyer.htm  before rendering)

As you can see, currently YafaRay is doing an incorrect lighting of the object. The reflections (including mirror and glossy) are correct, but the IBL lighting for the diffuse component is in the opposite side. That reduces a lot the realism of the scene and causes wrong illumination issues. This is the example of the wrong result:

wrong IBL lightingwrong IBL lighting

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

With my latest changes, that will be available in YafaRay-E v2.1.1, the IBL in diffuse is in the same place as the reflections, giving a much better (and correct!) result:

 

correct IBL lightingcorrect IBL lighting

#5

For some reason the .blend file did not appear in the previous post. You can download it from here.

AttachmentSize
world_bg_issues_1b.blend 484.33 KB

#6

Indeed there seems to be some issue going on. I can confirm wrong results here too. Spherical maps seem to provide correct results though. This bug went unnoticed probably because spherical maps are much more common nowadays than angular ones.

My work · Grey18 workflow · Sampling strategy · [url=http://www.yafaray.org/node/816]SPPM

#7

Status:ready to commit» fixed

Fixed in YafaRay-E v2.1.1. See: http://www.yafaray.org/community/forum/viewtopic.php?f=12&t=5137

#8

Status:fixed» closed

Fixed for 2 weeks without further comments, closing...