浏览代码

HDRenderPipeline: Fix minor issue with duplicate code

/main
Sebastien Lagarde 7 年前
当前提交
5b8a555c
共有 2 个文件被更改,包括 0 次插入35 次删除
  1. 25
      ScriptableRenderPipeline/HDRenderPipeline/Material/RenderPipelineMaterial.cs
  2. 10
      Tests/GraphicsTests/RenderPipeline/HDRenderPipeline/Scenes/0xxx.meta

25
ScriptableRenderPipeline/HDRenderPipeline/Material/RenderPipelineMaterial.cs


{
public class RenderPipelineMaterial : Object
{
public static List<RenderPipelineMaterial> GetRenderPipelineMaterialList()
{
var baseType = typeof(RenderPipelineMaterial);
var assembly = baseType.Assembly;
var types = assembly.GetTypes()
.Where(t => t.IsSubclassOf(baseType))
.Select(Activator.CreateInstance)
.Cast<RenderPipelineMaterial>()
.ToList();
// Note: If there is a need for an optimization in the future of this function, user can
// simply fill the materialList manually by commenting the code abode and returning a
// custom list of materials they use in their game.
//
// return new List<RenderPipelineMaterial>
// {
// new Lit(),
// new Unlit(),
// ...
// };
return types;
}
// GBuffer management
public virtual int GetMaterialGBufferCount() { return 0; }
public virtual void GetMaterialGBufferDescription(out RenderTextureFormat[] RTFormat, out RenderTextureReadWrite[] RTReadWrite)

10
Tests/GraphicsTests/RenderPipeline/HDRenderPipeline/Scenes/0xxx.meta


fileFormatVersion: 2
guid: 405d053465ae98342849302f26ddfee0
folderAsset: yes
timeCreated: 1508423740
licenseType: Pro
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
正在加载...
取消
保存