[LayaAirIDE 2.0]2.8.0上默认模型不能产生和接受阴影

同样的代码在 2.3.0 上使用阴影功能,是有阴影效果的。
在2.8.0上使用阴影功能,就没有出现阴影效果。
2.8.0设置阴影的代码:
var directionLight: Laya.DirectionLight = scene.addChild(new Laya.DirectionLight()) as Laya.DirectionLight;
directionLight.color = new Laya.Vector3(0.6, 0.6, 0.6);
directionLight.transform.worldMatrix.setForward(new Laya.Vector3(1, -1, 0));


directionLight.shadowMode = Laya.ShadowMode.SoftLow;
directionLight.shadowDistance = 100;
directionLight.shadowNearPlane = 1;
directionLight.shadowResolution = 2048;
directionLight.shadowCascadesMode = Laya.ShadowCascadesMode.NoCascades;
directionLight.shadowNormalBias = 4;

directionLight.shadowStrength = 10;
已邀请:

Laya_z

赞同来自:

不能产生阴影是什么环境下,浏览器、小游戏(哪个平台)?

要回复问题请先

商务合作
商务合作