Fix for bug: [#18619] Shadow face flag ignores object's scale

In time for the 2.49a ahoy :)
This commit is contained in:
Dalai Felinto 2009-06-17 21:18:32 +00:00
parent f1b9e76e43
commit b033f07306

@ -261,6 +261,12 @@ void KX_BlenderRenderTools::applyTransform(RAS_IRasterizer* rasty,double* oglmat
// couldn't find something to cast the shadow on...
glMultMatrixd(oglmatrix);
}
else
{ // we found the "ground", but the cast matrix doesn't take
// scaling in consideration, so we must apply the object scale
MT_Vector3 size = gameobj->GetSGNode()->GetLocalScale();
glScalef(size[0], size[1], size[2]);
}
} else
{
@ -384,5 +390,4 @@ void KX_BlenderRenderTools::Update2DFilter(vector<STR_String>& propNames, void*
void KX_BlenderRenderTools::Render2DFilters(RAS_ICanvas* canvas)
{
m_filtermanager.RenderFilters(canvas);
}
}