Environment map pixel subtended solid angle issue?

Discussion related to the implementation of new features & algorithms to the Core Engine.

Moderators: Dade, jromang, tomb, zcott, coordinators

Environment map pixel subtended solid angle issue?

Postby yhg » Fri Feb 19, 2016 5:09 pm


I'm not quite sure this is the right board to post this, don't hesitate point me to the right direction (or move the topic) if I was wrong.

While playing with environment map lighting, I came to the conclusion that LuxRender may not take into account the solid angles subtended by each pixel of the environment map. I may be wrong, though, I would like the confirmation of a developer to make sure.

I tried performing a simple render of an (subdivided) icosahedron with lambertian (matte) reflectance (no roughness, albedo = [1,1,1]), and I don't obtain the same pixel intensity results on my computations using Matlab (using the normal and the sum of the light in the environment map) or even with Mitsuba.

Here's an example of what I mean. If I render an image with an environment map such as this one:
The bottom and top of the sphere will be too bright, as if the pixels pointing toward the zenith (up) and nadir (down) in the environment map were accounted multiple times.

To fix the issue, I've multiplied each pixel of the environment map by the solid angle it subtends, making it look like too dark on the zenith an nadir, as such:
While the environment map looks wrong on the render, the pixel intensities overt the sphere seems to fit the lambertian model correctly.

Both images are effectively quite noisy, it's just a quick render showing the zenith as an example. The analysis was made with the lowdiscrepancy sampler with 50k spp.

This deviation from the lambertian reflectance model is sometimes hard to perceive by the human eye (depending on the tonemapping, I've made it easier to see in the example), but when comparing the .exr output with the theoretical lambertian reflectance equation, there is a small systematic error that can foil some computer vision experiments. This effect is most appreciable when the only light source is the environment map. So either there's an error in Mitsuba and my code (which gives the same output), or there's a glitch in LuxRender's latitude-longitude environment map handling.

Can I be wrong in my analysis?

Also, as a side question, there seems to be a maximal value of environment map taken into account in LuxRender. Past this value, increasing the value of every pixel in the environment map seems to give the same output. Past that point, multiplying the environment map by 2 or 1000 gives the same render (if you make abstraction of the noise). Anybody else witnessed this?

Thanks for your consideration,
Posts: 5
Joined: Tue Oct 28, 2014 12:12 am

Return to Architecture & Design

Who is online

Users browsing this forum: No registered users and 2 guests