Hello developers, I am confused for the specularOcclusion()…
void occludeSpecular() {
float specOcc = dAo;
dSpecularLight *= specOcc;
dReflection *= specOcc;
}
vec3 combineColor() {
return mix(dAlbedo * dDiffuseLight, dSpecularLight + dReflection.rgb * dReflection.a, dSpecularity);
}
As the code shows, dReflection.a will be multiplied by the ao, At last:
dReflection.rgb = dReflection.rgb * ao * dReflection.a * ao … Does playcanvas do this on purpose?
Why dont we just only multiply the dRefelction.rgb with ao and leave along the reflectivity…
thanks very much!!!