// For HDRP we need to divide the analytic light color by PI (HDRP do explicit PI division for Lambert, but built in Unity and the GI don't)
// We apply it on both direct and indirect are they are separated, seems that direct is no used if we used mixed mode with indirect or shadowmask bake.
ld.color.red/=Mathf.PI;
ld.color.green/=Mathf.PI;
ld.color.blue/=Mathf.PI;
ld.indirectColor.red/=Mathf.PI;
ld.indirectColor.green/=Mathf.PI;
ld.indirectColor.blue/=Mathf.PI;
#if UNITY_EDITOR
#else
ld.mode=LightMode.Realtime;
#endif
// For HDRP we need to divide the analytic light color by PI (HDRP do explicit PI division for Lambert, but built in Unity and the GI don't for punctual lights)
// We apply it on both direct and indirect are they are separated, seems that direct is no used if we used mixed mode with indirect or shadowmask bake.
ld.color.intensity/=Mathf.PI;
ld.indirectColor.intensity/=Mathf.PI;
switch(l.type)
{
caseLightType.Directional:
ld.shape1=0.0f;
#endif
// TEMP: for now, if we bake a rectangle type this will disable the light for runtime, need to speak with GI team about it!