private void BakedGUI(SerializedObject so, bool enableRealtimeGI, SerializedProperty enableBakedGI)
{
this.m_ShowBakeSettings = EditorGUILayout.ToggleTitlebar(this.m_ShowBakeSettings, styles.BakedGILabel, enableBakedGI);
if (this.m_ShowBakeSettings)
{
SerializedProperty resolution = so.FindProperty("m_LightmapEditorSettings.m_Resolution");
SerializedProperty property2 = so.FindProperty("m_LightmapEditorSettings.m_BakeResolution");
SerializedProperty property = so.FindProperty("m_LightmapEditorSettings.m_Padding");
SerializedProperty property4 = so.FindProperty("m_LightmapEditorSettings.m_AO");
SerializedProperty property5 = so.FindProperty("m_LightmapEditorSettings.m_AOMaxDistance");
SerializedProperty property6 = so.FindProperty("m_LightmapEditorSettings.m_CompAOExponent");
SerializedProperty property7 = so.FindProperty("m_LightmapEditorSettings.m_CompAOExponentDirect");
SerializedProperty property8 = so.FindProperty("m_LightmapEditorSettings.m_TextureCompression");
SerializedProperty property9 = so.FindProperty("m_LightmapEditorSettings.m_DirectLightInLightProbes");
SerializedProperty property10 = so.FindProperty("m_LightmapEditorSettings.m_FinalGather");
SerializedProperty property11 = so.FindProperty("m_LightmapEditorSettings.m_FinalGatherRayCount");
SerializedProperty property12 = so.FindProperty("m_LightmapEditorSettings.m_FinalGatherFiltering");
SerializedProperty property13 = so.FindProperty("m_LightmapEditorSettings.m_TextureWidth");
EditorGUI.indentLevel++;
using (new EditorGUI.DisabledScope(!enableBakedGI.boolValue))
{
DrawLightmapResolutionField(property2, styles.BakeResolution);
GUILayout.BeginHorizontal(new GUILayoutOption[0]);
EditorGUILayout.PropertyField(property, styles.Padding, new GUILayoutOption[0]);
GUILayout.Label(" texels", styles.labelStyle, new GUILayoutOption[0]);
GUILayout.EndHorizontal();
EditorGUILayout.PropertyField(property8, s_Styles.TextureCompression, new GUILayoutOption[0]);
this.m_ShowIndirectResolution.target = !enableRealtimeGI;
if (EditorGUILayout.BeginFadeGroup(this.m_ShowIndirectResolution.faded))
{
EditorGUILayout.Space();
DrawLightmapResolutionField(resolution, styles.IndirectResolution);
EditorGUILayout.Space();
}
EditorGUILayout.EndFadeGroup();
EditorGUILayout.PropertyField(property4, s_Styles.AO, new GUILayoutOption[0]);
if (property4.boolValue)
{
EditorGUI.indentLevel++;
EditorGUILayout.PropertyField(property5, styles.AOMaxDistance, new GUILayoutOption[0]);
if (property5.floatValue < 0f)
{
property5.floatValue = 0f;
}
EditorGUILayout.Slider(property6, 0f, 10f, styles.AmbientOcclusion, new GUILayoutOption[0]);
EditorGUILayout.Slider(property7, 0f, 10f, styles.AmbientOcclusionDirect, new GUILayoutOption[0]);
EditorGUI.indentLevel--;
}
EditorGUILayout.PropertyField(property10, s_Styles.FinalGather, new GUILayoutOption[0]);
if (property10.boolValue)
{
EditorGUI.indentLevel++;
EditorGUILayout.PropertyField(property11, styles.FinalGatherRayCount, new GUILayoutOption[0]);
EditorGUILayout.PropertyField(property12, styles.FinalGatherFiltering, new GUILayoutOption[0]);
EditorGUI.indentLevel--;
}
EditorGUILayout.IntPopup(property13, this.kMaxAtlasSizeStrings, this.kMaxAtlasSizeValues, styles.MaxAtlasSize, new GUILayoutOption[0]);
EditorGUILayout.Space();
EditorGUILayout.LabelField(styles.LightProbesTitle, new GUILayoutOption[0]);
EditorGUI.indentLevel++;
EditorGUILayout.PropertyField(property9, s_Styles.DirectLightInLightProbes, new GUILayoutOption[0]);
EditorGUI.indentLevel--;
EditorGUILayout.Space();
}
EditorGUI.indentLevel--;
}
}