From ee52ad23aeaafb78af6017b4839be608e5b8ad0d Mon Sep 17 00:00:00 2001 From: hyzboy Date: Sat, 1 Feb 2020 23:38:30 +0800 Subject: [PATCH] to update the code of cnmr.gbuffer --- CMakeLists.txt | 1 + res/shader/cnmr.gbuffer | 7 ++----- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 23806317..ba00406b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -36,6 +36,7 @@ SET(ULRE CMCore spirv-cross-core SPIRV glslang + OGLCompiler ${JSONCPP_LIBRARY} ${RENDER_LIBRARY} ${Vulkan_LIBRARIES}) diff --git a/res/shader/cnmr.gbuffer b/res/shader/cnmr.gbuffer index 1caa5429..3fa9672a 100644 --- a/res/shader/cnmr.gbuffer +++ b/res/shader/cnmr.gbuffer @@ -12,11 +12,8 @@ [attribute_to_gbuffer] - gb_color_metallic.rgb =BaseColor; - gb_color_metallic.a =Metallic; - - gb_normal_roughness.rgb =Normal; - gb_normal_roughness.a =Roughness; + gb_color_metallic =vec4(BaseColor,Metallic); + gb_normal_roughness =vec4(Normal, Roughness); [gbuffer_to_attribute]