浏览代码

Add convert project folder option

/system-shock-transitional-shader
Paul Melamed 7 年前
当前提交
740ffb6b
共有 2 个文件被更改,包括 5 次插入12 次删除
  1. 11
      ScriptableRenderPipeline/Core/Editor/MaterialUpgrader.cs
  2. 6
      ScriptableRenderPipeline/HDRenderPipeline/Editor/UpgradeStandardShaderMaterials.cs

11
ScriptableRenderPipeline/Core/Editor/MaterialUpgrader.cs


if (UnityEditor.EditorUtility.DisplayCancelableProgressBar(progressBarName, string.Format("({0} of {1}) {2}", materialIndex, totalMaterialCount, path), (float)materialIndex / (float)totalMaterialCount))
break;
Material m = UnityEditor.AssetDatabase.LoadMainAssetAtPath(path) as Material;
Upgrade_SS(m, upgraders, flags);
//SaveAssetsAndFreeMemory();
Material material = UnityEditor.AssetDatabase.LoadMainAssetAtPath(path) as Material;
Upgrade(material, upgraders, flags);
public static void Upgrade_SS(Material material, List<MaterialUpgrader> upgraders, UpgradeFlags flags)
{
}
public static void Upgrade(Material material, MaterialUpgrader upgrader, UpgradeFlags flags)
{

6
ScriptableRenderPipeline/HDRenderPipeline/Editor/UpgradeStandardShaderMaterials.cs


return upgraders;
}
/*
MaterialUpgrader.UpgradeProjectFolder_SS(GetHDUpgraders(), "Upgrade to HD Material");
MaterialUpgrader.UpgradeProjectFolder_SS(GetHDUpgraders_SS(), "Upgrade to HD Material");
*/
[MenuItem("RenderPipeline/HDRenderPipeline/Material Upgraders/Upgrade Standard Materials to Lit Materials (SS) - Selection", false, 2)]
static void UpgradeMaterialsSelection_SS()

正在加载...
取消
保存