[Soc-2009-dev] Weekly (late) report and IBL integration

Jingyuan Huang jingyuan.huang at gmail.com
Tue May 19 21:09:47 CEST 2009

Hi all,
Here is my weekly progress:
1. There is no update on user specs. It seems that people want a build
to play with rather than looking at docs. :-)
2. I updated several sections in design doc. The interface part is
still empty but they will be filled as I go.
3. I added (and committed) some code for light paint mode. It now has
a light paint mode and if the coefficients are never computed for the
scene it would create a job to do the initial computation. I'm only
computing diffuse coefficients now. The code is messy and needs
I apologize for my last commit. It was not done as it should have
been. I accidentally merged changes from 2.5 and commit everything
together. It should have been 2 commits.

There's been some discussions going on in Blender Artists. Several
people mentioned IBL and I think maybe it's a good idea to lay out a
plan for it. Here are some of my thoughts:
1. I'd like to have a light environment type (maybe
DNA_lightenv_types.h). A light environment can take a texture, or can
just be something computed by the system. scene->world should have a
reference to the lighting environment.
2. Light node would have similar structure as the other node types.
Very simple docs here:
3. Some of the function in broken's patch would be moved to either
LightEnv or sh/compute.c. re->ibl_sh_coeffs may be accessed through
scene instead of render so that the values can be used in view3d too.
4. I'm not sure how this would affect RenderLayer.
5. I will leave out the rest of broken's patch and go back to Render later.

I also have some thoughts about how objects should be drawn in light paint mode.
1. light paint mode should not have its own drawtype. In fact I think
it should be drawn as it is in solid mode.
2. in shaded mode, there are already a bunch of if-else statements for
vertex/texture/weight. Light paint drawing code would go there.
3. I intend to use dm->drawFacesColored (single side) for light paint.
Colours are computed as an accumulation of light sh coefficients and
object sh coefficients.

For the following week:
1. Discuss LightEnv on the ML and add more descriptions to the design doc.
2. Add a primitive synthetic LightEnv so that the problem would be
able to show a diffuse cube in light paint mode.
3. Clean up code.

I will be in Kelowna for CRV/GI 2009. Martin will be there too. :-)
I have an HPC summer school from June 1 to June 5 during the day, but
I can still do coding in the evenings.

Best Wishes
Jingyuan Huang
Computer Graphics Lab
University of Waterloo

More information about the Soc-2009-dev mailing list