테스트 케이스 더 자세히 전달 드리겠습니다.
Case 1
MobileLightingCommon.ush, 617
#if !MOBILE_DEFERRED_LIGHTING
// Check lighting channels for mobile forward
//if ((UnpackLightingChannelMask(LocalLight) & LightingChannelMask) == 0)
//{
// continue;
//}
#endif
해당 부분 제거 (LightingChannelMask 사용하지 않음)
- LightingChannelMask 부분이 렌더링 오류를 유발
- 해당 빌드 정상적으로 출력
Case 2
LightData.ush, 219
uint UnpackLightingChannelMask(FLocalLightData In)
{
uint Mask = LIGHTING_CHANNEL_MASK << 8;
//uint Mask = 1792;
const uint LightTypeAndPackedShadowMapChannelMask = asuint(Mask);
return UnpackLightingChannelMask(LightTypeAndPackedShadowMapChannelMask);
}
In.LightDirectionAndShadowMask.w = 7u; 로 고정
- asuint() 의심
- 해당 빌드 렌더링 이슈 발생
Case 3
MobileLightingCommon.ush, 617
#if !MOBILE_DEFERRED_LIGHTING
// Check lighting channels for mobile forward
if ((UnpackLightingChannelMask(LocalLight) & 0x7) == 0)
{
continue;
}
#endif
LightingChannelMask 를 0x7로 변경
- LightingChannelMask 값 이상 의심
- 해당 빌드 렌더링 이슈 없음
- LightingChannelMask 문제로 확인됨
Case 4
MobileBasePassPixelShader.usf, 986
//uint LightingChannelMask = GetPrimitive_LightingChannelMask(MaterialParameters.PrimitiveId);
uint LightingChannelMask = GetPrimitive_LightingChannelMask(0);
AccumulateLightGridLocalLighting(CulledLightGridHeader, GBuffer, MaterialParameters.WorldPosition_CamRelative, CameraVector, EyeIndex, 0, LocalLightDynamicShadowFactors, LightingChannelMask, DirectLighting);
- MaterialParameters.PrimitiveId 를 0 으로 강제 설정
- 해당 빌드에서 정상적으로 출력
- MaterialParameters.PrimitiveId 가 문제인 것으로 보임
Case 5
LocalVertexFactory.ush, 1175
//SetPrimitiveId(Interpolants, Intermediates.Common.SceneData.PrimitiveId);
SetPrimitiveId(Interpolants, 0);
- VS 에서 전달되는 PrimitiveId 를 강제로 0 설정
- 해당 빌드 렌더링 이슈 발생
VertexInterpolants 로 넘어오는 PrimitiveId 값이 뭔가 잘못되는 것으로 보여집니다.