From 2a4445f6e8f5f3af9f0eb990298be760bf8b6b42 Mon Sep 17 00:00:00 2001 From: hyzboy Date: Thu, 17 Dec 2020 16:53:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=97=A7=E7=9A=84=E6=9D=90?= =?UTF-8?q?=E8=B4=A8=E7=B3=BB=E7=BB=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- inc/hgl/graph/material/Material.h | 68 ----------------------- inc/hgl/graph/material/PBRMaterial.h | 23 -------- inc/hgl/graph/material/StandardMaterial.h | 40 ------------- 3 files changed, 131 deletions(-) delete mode 100644 inc/hgl/graph/material/Material.h delete mode 100644 inc/hgl/graph/material/PBRMaterial.h delete mode 100644 inc/hgl/graph/material/StandardMaterial.h diff --git a/inc/hgl/graph/material/Material.h b/inc/hgl/graph/material/Material.h deleted file mode 100644 index 5c0cf66b..00000000 --- a/inc/hgl/graph/material/Material.h +++ /dev/null @@ -1,68 +0,0 @@ -#ifndef HGL_GRAPH_MATERIAL_INCLUDE -#define HGL_GRAPH_MATERIAL_INCLUDE - -#include -#include - -MATERIAL_NAMESPACE_BEGIN - enum class BlendMode - { - Opaque=0, - Mask, - Alpha, - Additive, - Subtractive, - Modulate, - PreMultiAlpha, // 预计算好一半的Alpha - - BEGIN_RANGE =Opaque, - END_RANGE =PreMultiAlpha, - RANGE_SIZE =END_RANGE-BEGIN_RANGE+1 - };//enum class BlendMode - - /** - * 延迟渲染阶段流程 - */ - enum class DeferredRenderPass - { - Opaque, ///<不透明部分 - Mask, ///<遮罩部分 - - Composition, /// -MATERIAL_NAMESPACE_BEGIN -/** - * 标准PBR材质
- * BaseColor/Normal/Metallic/Roughness四个属性必须都有。如未提供,则会使用const方式提供一个数值 - */ -class PBRMaterial:public Material -{ -public: - - PBRMaterial(const UTF8String & n, - const BlendMode & bm =BlendMode::Opaque, - const bool ts =false, - const bool wf =false): - Material(n,MCC_CNMR,bm,ts,wf){} - - virtual ~PBRMaterial()=default; -};//class PBRMaterial:public Material -MATERIAL_NAMESPACE_END -#endif//HGL_GRAPH_MATERIAL_PBR_INCLUDE diff --git a/inc/hgl/graph/material/StandardMaterial.h b/inc/hgl/graph/material/StandardMaterial.h deleted file mode 100644 index dbe81d95..00000000 --- a/inc/hgl/graph/material/StandardMaterial.h +++ /dev/null @@ -1,40 +0,0 @@ -#ifndef HGL_GRAPH_MATERIAL_STANDARD_INCLUDE -#define HGL_GRAPH_MATERIAL_STANDARD_INCLUDE - -#include -MATERIAL_NAMESPACE_BEGIN -/** - * 传统标准材质 - */ -class StandardMaterial:public Material -{ -public: - - enum class DataSource - { - Const, - Param, - Texture, - Position, - };// - - struct - { - Component comp; ///<成份 - DataSource source; ///<来源 - DataFormat format; ///<数据格式 - }; - -public: - - StandardMaterial( const UTF8String & n, - const ComponentBitsConfig & cbf, - const BlendMode & bm =BlendMode::Opaque, - const bool ts =false, - const bool wf =false): - Material(n,cbf,bm,ts,wf){} - - virtual ~StandardMaterial()=default; -};//class StandardMaterial:public Material -MATERIAL_NAMESPACE_END -#endif//HGL_GRAPH_MATERIAL_STANDARD_INCLUDE