Hey, not sure if this is in progress, or was just overlooked, but lightmass doesn’t take into account a light’s “Source Length” when baking the scene. It works correctly in realtime, and the preview, but the bake ignores the setting.
It would be even better if not only shape, but light influence would be fixed, too. AFAIK, at the moment light shape affects only on reflection & specularity of the light.
If only we could use not only some light length and radius values, but make certain areas (of any given form) emit the light - THAT would be perfect. *And I’m not talking about bounced-light-lit areas here, it’s a lot more complex, I suppose.
Well, me not being one for waiting, I thought I’d jump into the lightmass code and see what’s what. Looks like what I had thought, and it’s either overlooked or just not done yet, as the source length just isn’t passed in.
A bit more digging, and some mind bending vector math later, I think I’ve almost got it baking capsule lights properly.
Cool stuff! Yes, I haven’t gotten to better lightmass support for tube lights. As you note, the static version doesn’t work right now. In addition I’d like better support for precomputed shadows from area lights. Dynamic area light shadows are super hard but precomputed ones are easy so there’s no reason why not. Also I’d like to do a similar trick for per object shadows to area lights as I’ve done at a previous company. The trick is basically cast shadow from closest point on light shape. Not accurate but looks good.
Dude! Please, please post the code here. I needed this feature for a while now, and unfortunately it does not seem as a high priority in official roadmap. It would be greatly appreciated and I’m sure not only by me.
Great work! If you post the code, please consider posting it in the Engine Source and GitHub section. This will give users who like to add plugins and make modifications to the source the opportunity to see it more easily. Here in the rendering section it seems a little buried.