internal static TierSettings GetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier) { TierSettings settings; INTERNAL_CALL_GetTierSettingsImpl(target, tier, out settings); return(settings); }
internal void OnGuiVertical(BuildTargetGroup platform) { EditorGUILayout.BeginHorizontal(new GUILayoutOption[0]); EditorGUILayout.BeginVertical(new GUILayoutOption[0]); EditorGUIUtility.labelWidth = 140f; EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.empty, EditorStyles.boldLabel, new GUILayoutOption[0]); this.OnFieldLabelsGUI(); EditorGUILayout.EndVertical(); EditorGUIUtility.labelWidth = 50f; IEnumerator enumerator = Enum.GetValues(typeof(GraphicsTier)).GetEnumerator(); try { while (enumerator.MoveNext()) { GraphicsTier graphicsTier = (GraphicsTier)enumerator.Current; EditorGUILayout.BeginVertical(new GUILayoutOption[0]); EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.tierName[(int)graphicsTier], EditorStyles.boldLabel, new GUILayoutOption[0]); this.OnTierGUI(platform, graphicsTier); EditorGUILayout.EndVertical(); } } finally { IDisposable disposable; if ((disposable = (enumerator as IDisposable)) != null) { disposable.Dispose(); } } EditorGUIUtility.labelWidth = 0f; EditorGUILayout.EndHorizontal(); }
public TierSettings(PlatformShaderSettings settings, Platform platfrom, GraphicsTier tier, Version version, TransferInstructionFlags flags) { BuildTarget = platfrom.PlatformToBuildGroup(); Tier = tier; Settings = new TierGraphicsSettingsEditor(settings, version, flags); Automatic = false; }
internal void OnTierGUI(BuildTargetGroup platform, GraphicsTier tier, bool vertical) { TierSettings tierSettings = EditorGraphicsSettings.GetTierSettings(platform, tier); EditorGUI.BeginChangeCheck(); if (!vertical) { EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.empty, EditorStyles.boldLabel, new GUILayoutOption[0]); } tierSettings.standardShaderQuality = this.ShaderQualityPopup(tierSettings.standardShaderQuality); tierSettings.reflectionProbeBoxProjection = EditorGUILayout.Toggle(tierSettings.reflectionProbeBoxProjection, new GUILayoutOption[0]); tierSettings.reflectionProbeBlending = EditorGUILayout.Toggle(tierSettings.reflectionProbeBlending, new GUILayoutOption[0]); tierSettings.detailNormalMap = EditorGUILayout.Toggle(tierSettings.detailNormalMap, new GUILayoutOption[0]); tierSettings.semitransparentShadows = EditorGUILayout.Toggle(tierSettings.semitransparentShadows, new GUILayoutOption[0]); tierSettings.enableLPPV = EditorGUILayout.Toggle(tierSettings.enableLPPV, new GUILayoutOption[0]); if (!vertical) { EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.empty, EditorStyles.boldLabel, new GUILayoutOption[0]); EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.empty, EditorStyles.boldLabel, new GUILayoutOption[0]); } tierSettings.cascadedShadowMaps = EditorGUILayout.Toggle(tierSettings.cascadedShadowMaps, new GUILayoutOption[0]); tierSettings.prefer32BitShadowMaps = EditorGUILayout.Toggle(tierSettings.prefer32BitShadowMaps, new GUILayoutOption[0]); tierSettings.hdr = EditorGUILayout.Toggle(tierSettings.hdr, new GUILayoutOption[0]); tierSettings.hdrMode = this.HDRModePopup(tierSettings.hdrMode); tierSettings.renderingPath = this.RenderingPathPopup(tierSettings.renderingPath); tierSettings.realtimeGICPUUsage = this.RealtimeGICPUUsagePopup(tierSettings.realtimeGICPUUsage); if (EditorGUI.EndChangeCheck()) { EditorGraphicsSettings.RegisterUndoForGraphicsSettings(); EditorGraphicsSettings.SetTierSettings(platform, tier, tierSettings); } }
internal static TierSettings GetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier) { TierSettings result; EditorGraphicsSettings.INTERNAL_CALL_GetTierSettingsImpl(target, tier, out result); return(result); }
public TierSettings(TierGraphicsSettings settings, Platform platfrom, GraphicsTier tier) { BuildTarget = platfrom.PlatformToBuildGroup(); Tier = tier; Settings = new TierGraphicsSettingsEditor(settings); Automatic = false; }
public static void SetTierSettings(BuildTargetGroup target, GraphicsTier tier, TierSettings settings) { if (settings.renderingPath == RenderingPath.UsePlayerSettings) { throw new ArgumentException("TierSettings.renderingPath must be actual rendering path (not UsePlayerSettings)", "settings"); } SetTierSettingsImpl(target, tier, settings); OnUpdateTierSettingsImpl(target, true); }
internal void OnGuiVertical(BuildTargetGroup platform) { IEnumerator enumerator = Enum.GetValues(typeof(GraphicsTier)).GetEnumerator(); try { while (enumerator.MoveNext()) { GraphicsTier graphicsTier = (GraphicsTier)enumerator.Current; bool flag = EditorGraphicsSettings.AreTierSettingsAutomatic(platform, graphicsTier); EditorGUI.BeginChangeCheck(); GUILayout.BeginHorizontal(new GUILayoutOption[0]); EditorGUIUtility.labelWidth = 80f; EditorGUILayout.LabelField(GraphicsSettingsWindow.TierSettingsEditor.Styles.tierName[(int)graphicsTier], EditorStyles.boldLabel, new GUILayoutOption[0]); GUILayout.FlexibleSpace(); EditorGUIUtility.labelWidth = 75f; flag = EditorGUILayout.Toggle(GraphicsSettingsWindow.TierSettingsEditor.Styles.autoSettings, flag, new GUILayoutOption[0]); GUILayout.EndHorizontal(); if (EditorGUI.EndChangeCheck()) { EditorGraphicsSettings.RegisterUndoForGraphicsSettings(); EditorGraphicsSettings.MakeTierSettingsAutomatic(platform, graphicsTier, flag); EditorGraphicsSettings.OnUpdateTierSettingsImpl(platform, true); } using (new EditorGUI.DisabledScope(flag)) { EditorGUI.indentLevel++; EditorGUILayout.BeginHorizontal(new GUILayoutOption[0]); EditorGUILayout.BeginVertical(new GUILayoutOption[0]); EditorGUIUtility.labelWidth = 140f; this.OnFieldLabelsGUI(true); EditorGUILayout.EndVertical(); EditorGUILayout.BeginVertical(new GUILayoutOption[0]); EditorGUIUtility.labelWidth = 50f; this.OnTierGUI(platform, graphicsTier, true); EditorGUILayout.EndVertical(); GUILayout.EndHorizontal(); EditorGUI.indentLevel--; } } } finally { IDisposable disposable; if ((disposable = (enumerator as IDisposable)) != null) { disposable.Dispose(); } } EditorGUIUtility.labelWidth = 0f; }
internal void OnTierGUI(BuildTargetGroup platform, GraphicsTier tier) { TierSettings tierSettings = EditorGraphicsSettings.GetTierSettings(platform, tier); EditorGUI.BeginChangeCheck(); tierSettings.cascadedShadowMaps = EditorGUILayout.Toggle(tierSettings.cascadedShadowMaps, new GUILayoutOption[0]); tierSettings.standardShaderQuality = this.ShaderQualityPopup(tierSettings.standardShaderQuality); tierSettings.reflectionProbeBoxProjection = EditorGUILayout.Toggle(tierSettings.reflectionProbeBoxProjection, new GUILayoutOption[0]); tierSettings.reflectionProbeBlending = EditorGUILayout.Toggle(tierSettings.reflectionProbeBlending, new GUILayoutOption[0]); tierSettings.renderingPath = this.RenderingPathPopup(tierSettings.renderingPath); if (EditorGUI.EndChangeCheck()) { EditorGraphicsSettings.RegisterUndoForGraphicsSettings(); EditorGraphicsSettings.SetTierSettings(platform, tier, tierSettings); } }
public bool ShouldStrip(GraphicsTier tier) { switch (tier) { case GraphicsTier.Tier1: return(stripTier1); case GraphicsTier.Tier2: return(stripTier2); case GraphicsTier.Tier3: return(stripTier3); } return(false); }
internal static void SetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, TierSettings settings) { INTERNAL_CALL_SetTierSettingsImpl(target, tier, ref settings); }
internal static extern bool AreTierSettingsAutomatic(BuildTargetGroup target, GraphicsTier tier);
internal static void SetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, TierSettings settings) { EditorGraphicsSettings.INTERNAL_CALL_SetTierSettingsImpl(target, tier, ref settings); }
public VariantCompileInfo CompileVariant(ShaderType shaderType, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, BuiltinShaderDefine[] platformKeywords, GraphicsTier tier, bool forExternalTool) { return(ShaderUtil.CompileShaderVariant(SourceShader, SubshaderIndex, m_PassIndex, shaderType, platformKeywords, keywords, shaderCompilerPlatform, buildTarget, tier, forExternalTool)); }
public static TierSettings GetTierSettings(NamedBuildTarget target, GraphicsTier tier) => GetTierSettings(target.ToBuildTargetGroup(), tier);
internal static TierSettings GetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier) { TierSettings settings; INTERNAL_CALL_GetTierSettingsImpl(target, tier, out settings); return settings; }
private extern static void INTERNAL_CALL_GetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, out TierGraphicsSettingsEditorScript value);
private extern static void INTERNAL_CALL_SetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, ref TierGraphicsSettingsEditorScript settings);
public static bool HasShaderDefine(GraphicsTier tier, BuiltinShaderDefine defineHash) { return(HasShaderDefineImpl(tier, defineHash)); }
private static extern void INTERNAL_CALL_GetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, out TierSettings value);
private static extern void INTERNAL_CALL_SetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, ref TierSettings settings);
[NativeName("SetTierSettings")] extern internal static void SetTierSettingsImpl(BuildTargetGroup target, GraphicsTier tier, TierSettings settings);
public static TierSettings GetTierSettings(BuildTargetGroup target, GraphicsTier tier) { return(EditorGraphicsSettings.GetTierSettingsImpl(target, tier)); }
extern public static TierSettings GetTierSettings(BuildTargetGroup target, GraphicsTier tier);
public static TierSettings GetTierSettings(BuildTargetGroup target, GraphicsTier tier) { return GetTierSettingsImpl(target, tier); }
public VariantCompileInfo CompileVariant(ShaderType shaderType, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, BuiltinShaderDefine[] platformKeywords, GraphicsTier tier) { return(CompileVariant(shaderType, keywords, shaderCompilerPlatform, buildTarget, platformKeywords, tier, false)); }
extern public static BuiltinShaderDefine[] GetShaderPlatformKeywordsForBuildTarget(ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, GraphicsTier tier);
public PreprocessedVariant PreprocessVariant(ShaderType shaderType, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, BuiltinShaderDefine[] platformKeywords, GraphicsTier tier, bool stripLineDirectives) { return(ShaderUtil.PreprocessShaderVariant(SourceShader, SubshaderIndex, m_PassIndex, shaderType, platformKeywords, keywords, shaderCompilerPlatform, buildTarget, tier, stripLineDirectives)); }
extern internal static ShaderData.VariantCompileInfo CompileShaderVariant([NotNull] Shader shader, int subShaderIndex, int passId, ShaderType shaderType, BuiltinShaderDefine[] platformKeywords, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, GraphicsTier tier, bool outputForExternalTool);
extern internal static ShaderData.PreprocessedVariant PreprocessShaderVariant([NotNull] Shader shader, int subShaderIndex, int passId, ShaderType shaderType, BuiltinShaderDefine[] platformKeywords, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, GraphicsTier tier, bool stripLineDirectives);
internal static extern void MakeTierSettingsAutomatic(BuildTargetGroup target, GraphicsTier tier, bool automatic);
extern public static bool HasShaderDefine(GraphicsTier tier, BuiltinShaderDefine defineHash);
public VariantCompileInfo CompileVariant(ShaderType shaderType, string[] keywords, ShaderCompilerPlatform shaderCompilerPlatform, BuildTarget buildTarget, GraphicsTier tier) { var platformKeywords = ShaderUtil.GetShaderPlatformKeywordsForBuildTarget(shaderCompilerPlatform, buildTarget, tier); return(ShaderUtil.CompileShaderVariant(SourceShader, SubshaderIndex, m_PassIndex, shaderType, platformKeywords, keywords, shaderCompilerPlatform, buildTarget, tier)); }