[Bf-cycles] Lightprobe importance sampling

storm kartochka22 at yandex.ru
Wed Dec 28 13:22:10 CET 2011


Great! I google and found description
http://www.pbrt.org/plugins/infinitesample.pdf, really cool. I always
think about arbitrary phase function curve, maybe hand writen/converted
from any curve in viewport, and how to make importance sampling it, but
never imagine it can be done to whole environment image.

You absolutely right about current Cycles algorithm, you need to extend
light source list, most stuff in kernel_light.c and kernel_emission.c
(need careful, it executed in GPU and you need to use subset of c
language, prefered CUDA/OpenCL common parts ) and preparation data to
transfer to GPU space in device update event in
blender/intern/cycles/render/light.cpp, it run only in CPU you can use
safely any C statement here.

Beware CUDA/OpenCL memory allocation rules, all data can be accessed
from GPU are in constant memory "KernelData" in
blender/intern/cycles/kernel/kernel_types.hblender/intern/cycles/kernel/kernel_types.h or "textures", handled by device object, you restricted by onboard adapter memory, as I understend you need extra texture for algorithm to hold new accelerator data, then you need to add another to blender/intern/cycles/kernel/kernel_textures.h



More information about the Bf-cycles mailing list