zombie@computer wrote:Perhaps i misssed something or im using the wrong codebase but i had to add
void UpdateShadowDirectionFromLocalLightSource( ClientShadowHandle_t shadowHandle );
const Vector &CClientShadowMgr::GetShadowDirection( ClientShadowHandle_t shadowHandle ) const;
void UpdateDirtyShadow( ClientShadowHandle_t handle );
to the class definition before it worked.
Thanks zombie, added the steps to the article now.
zombie@computer wrote:OK, it's working great, but the shadow switching between two lights is... odd. Is it possible to have multiple shadows (one fading in, one fading out, for each light in the neighborhood) this way, or would that not be possible?
Assuming you already investigated that, i guess it's an obvious next step.
I was thinking about multiple shadows myself, and will give it a shot when I get per-entity shadow colours functional. I will add a ConVar such as
r_worldlight_shadowsperentity which will define the maximum number of shadows an entity may have. The brightest lights around an entity will then cast independent shadows, instead of
the most intense light casting a single shadow.
In the meantime, try increasing
r_worldlight_mincastintensity, or decreasing
r_worldlight_lerptime.