这几天在解决渲染场景时的阴影问题,首先在Eddie那儿找到一篇文章
TORQUE引擎里利用Sceneobject来产生动态阴影的方法(Shadows class derived from Sceneobject)
才知道DIF物体和山等SHAP可以自动计算出静态阴影,而DTS物体是出不来阴影的!比如树木等SHAP
但是例子里的torque_logo.dts是可以有阴影的,这又如何解释呢?《3D游戏开发大全》里这样说的
Also, DTS objects don't inherently understand the concept of lighting and shadows, so if you make a building as a DTS object, you will also have to light it yourself using another object—which is possible, but you'll have to do that for every building.
所以,如果我们要生成阴影最好还是用DIF吧!
另外,Eddie提到的那个补丁,在1.5中不再适用,因为已经有了TLK了。