比较提交
合并到: unity-tech-cn:main
unity-tech-cn:/main
unity-tech-cn:/scriptablerenderloop-materialgraph
unity-tech-cn:/batch_rendering
unity-tech-cn:/vr_sandbox
unity-tech-cn:/Branch_Batching2
unity-tech-cn:/mikko-renderpass
unity-tech-cn:/fptl_cleanup
unity-tech-cn:/vr_fptl_sandbox
unity-tech-cn:/Branch_batcher
unity-tech-cn:/MobileDeferredRenderPass
unity-tech-cn:/vr_api_testbed
unity-tech-cn:/RenderPassXR_Sandbox
unity-tech-cn:/classicDeferredMobile
unity-tech-cn:/EnableVulkanAndES3
unity-tech-cn:/OnTileRenderPass2
unity-tech-cn:/sample_game
unity-tech-cn:/culling
unity-tech-cn:/OTDRP-develop
unity-tech-cn:/Add-support-for-light-specular-color-tint
unity-tech-cn:/stochastic_alpha_test
unity-tech-cn:/Yibing-Project-2
unity-tech-cn:/xr-hdrp-rt-test
unity-tech-cn:/system-shock-transitional-shader
unity-tech-cn:/feature-runtimeTextureCache
unity-tech-cn:/shader-library-include-paths
unity-tech-cn:/asmdef
unity-tech-cn:/namespace
unity-tech-cn:/feature-ReflectionProbeFit
unity-tech-cn:/prototype-decals
unity-tech-cn:/DrawSettings
unity-tech-cn:/projects-TheLastStand
unity-tech-cn:/iridesence
unity-tech-cn:/lw-nolightlist
unity-tech-cn:/Add-physical-light-unity-support
unity-tech-cn:/LightweightPipelineExperimental
unity-tech-cn:/switch_support
unity-tech-cn:/feature-ScreenSpaceProjection
unity-tech-cn:/use-roughness
unity-tech-cn:/LW-BakedIndirect
unity-tech-cn:/Branch_FixObjectMotion
unity-tech-cn:/srp_batcher
unity-tech-cn:/LW-LightOptimizations
unity-tech-cn:/Branch_ScriptableCulling
unity-tech-cn:/LW-LowEnd
unity-tech-cn:/feature-ReflectionProbeBaking
unity-tech-cn:/Improve-shader-generator
unity-tech-cn:/improve-shader-generator-data
unity-tech-cn:/2018.1
unity-tech-cn:/lwr-xr-shader-fixes-sandbox
unity-tech-cn:/uifoldout-fix
unity-tech-cn:/lw-callbacktests
unity-tech-cn:/lwrp-xr-sssm-DrawProc
unity-tech-cn:/lwrp-xr-tim-hacks
unity-tech-cn:/ss3HDRP
unity-tech-cn:/build-automation
unity-tech-cn:/HDRP_SurfaceShader
unity-tech-cn:/tag-1.1.0-beta
unity-tech-cn:/xr-hdrp-pyramids
unity-tech-cn:/lw-bias_per_cascade
unity-tech-cn:/040SimpleLighting
unity-tech-cn:/lw-tangentspacelightingtest
unity-tech-cn:/Lux-for-HDRI
unity-tech-cn:/HDRP_GraphicTests
unity-tech-cn:/projects-system-shock-2018.1
unity-tech-cn:/Change-cluster-Tile-to-dynamic-branch
unity-tech-cn:/Reduce-shader-variant
unity-tech-cn:/lw-shadow-optimization
unity-tech-cn:/LW-DistortionPass
unity-tech-cn:/lw-shader-optimization
unity-tech-cn:/Branch_RemoveCascadeBordersInUI
unity-tech-cn:/Branch_EnableLastSplitFade
unity-tech-cn:/Branch_DebugExposure
unity-tech-cn:/Documentation
unity-tech-cn:/lw-bugfixes
unity-tech-cn:/Branch_DebugExposure2
unity-tech-cn:/Branch_DebugWindowFix
unity-tech-cn:/lw-shadow-keyword
unity-tech-cn:/backport-shader-optimization
unity-tech-cn:/tag-1.1.4-preview
unity-tech-cn:/StackLitWork
unity-tech-cn:/tag-1.1.5-preview
unity-tech-cn:/tag-1.1.6-preview
unity-tech-cn:/stacklit
unity-tech-cn:/StackLit2
unity-tech-cn:/hdrp-staging
拉取从: unity-tech-cn:system-shock-transitional-shader
unity-tech-cn:/main
unity-tech-cn:/scriptablerenderloop-materialgraph
unity-tech-cn:/batch_rendering
unity-tech-cn:/vr_sandbox
unity-tech-cn:/Branch_Batching2
unity-tech-cn:/mikko-renderpass
unity-tech-cn:/fptl_cleanup
unity-tech-cn:/vr_fptl_sandbox
unity-tech-cn:/Branch_batcher
unity-tech-cn:/MobileDeferredRenderPass
unity-tech-cn:/vr_api_testbed
unity-tech-cn:/RenderPassXR_Sandbox
unity-tech-cn:/classicDeferredMobile
unity-tech-cn:/EnableVulkanAndES3
unity-tech-cn:/OnTileRenderPass2
unity-tech-cn:/sample_game
unity-tech-cn:/culling
unity-tech-cn:/OTDRP-develop
unity-tech-cn:/Add-support-for-light-specular-color-tint
unity-tech-cn:/stochastic_alpha_test
unity-tech-cn:/Yibing-Project-2
unity-tech-cn:/xr-hdrp-rt-test
unity-tech-cn:/system-shock-transitional-shader
unity-tech-cn:/feature-runtimeTextureCache
unity-tech-cn:/shader-library-include-paths
unity-tech-cn:/asmdef
unity-tech-cn:/namespace
unity-tech-cn:/feature-ReflectionProbeFit
unity-tech-cn:/prototype-decals
unity-tech-cn:/DrawSettings
unity-tech-cn:/projects-TheLastStand
unity-tech-cn:/iridesence
unity-tech-cn:/lw-nolightlist
unity-tech-cn:/Add-physical-light-unity-support
unity-tech-cn:/LightweightPipelineExperimental
unity-tech-cn:/switch_support
unity-tech-cn:/feature-ScreenSpaceProjection
unity-tech-cn:/use-roughness
unity-tech-cn:/LW-BakedIndirect
unity-tech-cn:/Branch_FixObjectMotion
unity-tech-cn:/srp_batcher
unity-tech-cn:/LW-LightOptimizations
unity-tech-cn:/Branch_ScriptableCulling
unity-tech-cn:/LW-LowEnd
unity-tech-cn:/feature-ReflectionProbeBaking
unity-tech-cn:/Improve-shader-generator
unity-tech-cn:/improve-shader-generator-data
unity-tech-cn:/2018.1
unity-tech-cn:/lwr-xr-shader-fixes-sandbox
unity-tech-cn:/uifoldout-fix
unity-tech-cn:/lw-callbacktests
unity-tech-cn:/lwrp-xr-sssm-DrawProc
unity-tech-cn:/lwrp-xr-tim-hacks
unity-tech-cn:/ss3HDRP
unity-tech-cn:/build-automation
unity-tech-cn:/HDRP_SurfaceShader
unity-tech-cn:/tag-1.1.0-beta
unity-tech-cn:/xr-hdrp-pyramids
unity-tech-cn:/lw-bias_per_cascade
unity-tech-cn:/040SimpleLighting
unity-tech-cn:/lw-tangentspacelightingtest
unity-tech-cn:/Lux-for-HDRI
unity-tech-cn:/HDRP_GraphicTests
unity-tech-cn:/projects-system-shock-2018.1
unity-tech-cn:/Change-cluster-Tile-to-dynamic-branch
unity-tech-cn:/Reduce-shader-variant
unity-tech-cn:/lw-shadow-optimization
unity-tech-cn:/LW-DistortionPass
unity-tech-cn:/lw-shader-optimization
unity-tech-cn:/Branch_RemoveCascadeBordersInUI
unity-tech-cn:/Branch_EnableLastSplitFade
unity-tech-cn:/Branch_DebugExposure
unity-tech-cn:/Documentation
unity-tech-cn:/lw-bugfixes
unity-tech-cn:/Branch_DebugExposure2
unity-tech-cn:/Branch_DebugWindowFix
unity-tech-cn:/lw-shadow-keyword
unity-tech-cn:/backport-shader-optimization
unity-tech-cn:/tag-1.1.4-preview
unity-tech-cn:/StackLitWork
unity-tech-cn:/tag-1.1.5-preview
unity-tech-cn:/tag-1.1.6-preview
unity-tech-cn:/stacklit
unity-tech-cn:/StackLit2
unity-tech-cn:/hdrp-staging
此合并请求有变更与目标分支冲突。
/ScriptableRenderPipeline/Core/Editor/MaterialUpgrader.cs
/ScriptableRenderPipeline/HDRenderPipeline/Editor/UpgradeStandardShaderMaterials.cs
/ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/LitProperties.hlsl
10 次代码提交
作者 | SHA1 | 备注 | 提交日期 |
---|---|---|---|
Paul Melamed | d5c19ff9 | only upgrade materials with the correct shader | 7 年前 |
Paul Melamed | 573dbe39 | fix lights | 7 年前 |
Paul Melamed | 7a08434c | cleanup some common code | 7 年前 |
Paul Melamed | c4d15fce | convert Adam/Standard (Specular Setup) | 7 年前 |
Paul Melamed | 86ed9235 | fix detail tiling conversion | 7 年前 |
Paul Melamed | 1165cc74 | Specular setup does not have _Metallic | 7 年前 |
Paul Melamed | bd6f0c7f | Renamed _SS to transitional | 7 年前 |
Paul Melamed | f735f83d | Added partial support for specular setup conversion | 7 年前 |
Paul Melamed | 740ffb6b | Add convert project folder option | 7 年前 |
Paul Melamed | 6a8f9743 | Transitional shader for system shock material upgrade | 7 年前 |
共有 8 个文件被更改,包括 875 次插入 和 0 次删除
-
3ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/LitProperties.hlsl
-
35ScriptableRenderPipeline/HDRenderPipeline/Editor/UpgradeStandardShaderMaterials.cs
-
120ScriptableRenderPipeline/Core/Editor/MaterialUpgrader.cs
-
505ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/LitTransitonal.shader
-
66ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/Editor/LitTransitionalUI.cs
-
30ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/Editor/StandardSpecularToHDLitTransitionalMaterialUpgrader.cs
-
30ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/Editor/StandardToHDLitTransitionalMaterialUpgrader.cs
-
86ScriptableRenderPipeline/HDRenderPipeline/ShaderPass/ShaderPassGBufferTransitional.hlsl
|
|||
Shader "HDRenderPipeline/LitTransitional" |
|||
{ |
|||
Properties |
|||
{ |
|||
// Following set of parameters represent the parameters node inside the MaterialGraph. |
|||
// They are use to fill a SurfaceData. With a MaterialGraph this should not exist. |
|||
|
|||
// Reminder. Color here are in linear but the UI (color picker) do the conversion sRGB to linear |
|||
_BaseColor("BaseColor", Color) = (1,1,1,1) |
|||
_BaseColorMap("BaseColorMap", 2D) = "white" {} |
|||
|
|||
_Metallic("_Metallic", Range(0.0, 1.0)) = 0 |
|||
_Smoothness("Smoothness", Range(0.0, 1.0)) = 1.0 |
|||
_MaskMap("MaskMap", 2D) = "white" {} |
|||
_OcclusionMap("Occlusion", 2D) = "white" {} |
|||
_DetailMapLegacy("Detail Map", 2D) = "white" {} |
|||
_DetailMaskMapLegacy("Detail Mask Map", 2D) = "white" {} |
|||
_SmoothnessRemapMin("SmoothnessRemapMin", Float) = 0.0 |
|||
_SmoothnessRemapMax("SmoothnessRemapMax", Float) = 1.0 |
|||
|
|||
_NormalMap("NormalMap", 2D) = "bump" {} // Tangent space normal map |
|||
_NormalMapOS("NormalMapOS", 2D) = "white" {} // Object space normal map - no good default value |
|||
_NormalScale("_NormalScale", Range(0.0, 2.0)) = 1 |
|||
|
|||
_BentNormalMap("_BentNormalMap", 2D) = "bump" {} |
|||
_BentNormalMapOS("_BentNormalMapOS", 2D) = "white" {} |
|||
|
|||
_HeightMap("HeightMap", 2D) = "black" {} |
|||
// Caution: Default value of _HeightAmplitude must be (_HeightMax - _HeightMin) * 0.01 |
|||
[HideInInspector] _HeightAmplitude("Height Amplitude", Float) = 0.02 // In world units. This will be computed in the UI. |
|||
_HeightMin("Heightmap Min", Float) = -1 |
|||
_HeightMax("Heightmap Max", Float) = 1 |
|||
_HeightCenter("Height Center", Range(0.0, 1.0)) = 0.5 // In texture space |
|||
|
|||
_DetailMap("DetailMap", 2D) = "grey" {} |
|||
_DetailMask("DetailMask", 2D) = "white" {} |
|||
_DetailNormalMap("DetailNormalMap", 2D) = "bump" {} |
|||
_DetailAlbedoScale("_DetailAlbedoScale", Range(0.0, 2.0)) = 1 |
|||
_DetailNormalScale("_DetailNormalScale", Range(0.0, 2.0)) = 1 |
|||
_DetailSmoothnessScale("_DetailSmoothnessScale", Range(0.0, 2.0)) = 1 |
|||
|
|||
_TangentMap("TangentMap", 2D) = "bump" {} |
|||
_TangentMapOS("TangentMapOS", 2D) = "white" {} |
|||
_Anisotropy("Anisotropy", Range(-1.0, 1.0)) = 0 |
|||
_AnisotropyMap("AnisotropyMap", 2D) = "white" {} |
|||
|
|||
_SubsurfaceProfile("Subsurface Profile", Int) = 0 |
|||
_SubsurfaceRadius("Subsurface Radius", Range(0.0, 1.0)) = 1.0 |
|||
_SubsurfaceRadiusMap("Subsurface Radius Map", 2D) = "white" {} |
|||
_Thickness("Thickness", Range(0.0, 1.0)) = 1.0 |
|||
_ThicknessMap("Thickness Map", 2D) = "white" {} |
|||
|
|||
_CoatCoverage("Coat Coverage", Range(0.0, 1.0)) = 1.0 |
|||
_CoatIOR("Coat IOR", Range(0.0, 1.0)) = 0.5 |
|||
|
|||
_SpecularColor("SpecularColor", Color) = (1, 1, 1, 1) |
|||
_SpecularColorMap("SpecularColorMap", 2D) = "white" {} |
|||
|
|||
// Following options are for the GUI inspector and different from the input parameters above |
|||
// These option below will cause different compilation flag. |
|||
[ToggleOff] _EnableSpecularOcclusion("Enable specular occlusion", Float) = 0.0 |
|||
|
|||
_EmissiveColor("EmissiveColor", Color) = (0, 0, 0) |
|||
_EmissiveColorMap("EmissiveColorMap", 2D) = "white" {} |
|||
_EmissiveIntensity("EmissiveIntensity", Float) = 0 |
|||
[ToggleOff] _AlbedoAffectEmissive("Albedo Affect Emissive", Float) = 0.0 |
|||
|
|||
_DistortionVectorMap("DistortionVectorMap", 2D) = "black" {} |
|||
[ToggleOff] _DistortionEnable("Enable Distortion", Float) = 0.0 |
|||
[ToggleOff] _DistortionDepthTest("Distortion Depth Test Enable", Float) = 0.0 |
|||
[Enum(Add, 0, Multiply, 1)] _DistortionBlendMode("Distortion Blend Mode", Int) = 0 |
|||
[HideInInspector] _DistortionSrcBlend("Distortion Blend Src", Int) = 0 |
|||
[HideInInspector] _DistortionDstBlend("Distortion Blend Dst", Int) = 0 |
|||
[HideInInspector] _DistortionBlurSrcBlend("Distortion Blur Blend Src", Int) = 0 |
|||
[HideInInspector] _DistortionBlurDstBlend("Distortion Blur Blend Dst", Int) = 0 |
|||
[HideInInspector] _DistortionBlurBlendMode("Distortion Blur Blend Mode", Int) = 0 |
|||
_DistortionScale("Distortion Scale", Float) = 1 |
|||
_DistortionBlurScale("Distortion Blur Scale", Float) = 1 |
|||
_DistortionBlurRemapMin("DistortionBlurRemapMin", Float) = 0.0 |
|||
_DistortionBlurRemapMax("DistortionBlurRemapMax", Float) = 1.0 |
|||
|
|||
[ToggleOff] _AlphaCutoffEnable("Alpha Cutoff Enable", Float) = 0.0 |
|||
_AlphaCutoff("Alpha Cutoff", Range(0.0, 1.0)) = 0.5 |
|||
|
|||
// Transparency |
|||
[Enum(None, 0, Plane, 1, Sphere, 2)]_RefractionMode("Refraction Mode", Int) = 0 |
|||
_IOR("Indice Of Refraction", Range(1.0, 2.5)) = 1.0 |
|||
_ThicknessMultiplier("Thickness Multiplier", Float) = 1.0 |
|||
_TransmittanceColor("Transmittance Color", Color) = (1.0, 1.0, 1.0) |
|||
_ATDistance("Transmittance Absorption Distance", Float) = 1.0 |
|||
[ToggleOff] _PreRefractionPass("PreRefractionPass", Float) = 0.0 |
|||
|
|||
// Stencil state |
|||
[HideInInspector] _StencilRef("_StencilRef", Int) = 2 // StencilLightingUsage.RegularLighting (fixed at compile time) |
|||
|
|||
// Blending state |
|||
[HideInInspector] _SurfaceType("__surfacetype", Float) = 0.0 |
|||
[HideInInspector] _BlendMode("__blendmode", Float) = 0.0 |
|||
[HideInInspector] _SrcBlend("__src", Float) = 1.0 |
|||
[HideInInspector] _DstBlend("__dst", Float) = 0.0 |
|||
[HideInInspector] _ZWrite("__zw", Float) = 1.0 |
|||
[HideInInspector] _CullMode("__cullmode", Float) = 2.0 |
|||
[HideInInspector] _ZTestMode("_ZTestMode", Int) = 8 |
|||
|
|||
[ToggleOff] _EnableFogOnTransparent("Enable Fog", Float) = 1.0 |
|||
[ToggleOff] _EnableBlendModePreserveSpecularLighting("Enable Blend Mode Preserve Specular Lighting", Float) = 1.0 |
|||
|
|||
[ToggleOff] _DoubleSidedEnable("Double sided enable", Float) = 0.0 |
|||
[Enum(None, 0, Mirror, 1, Flip, 2)] _DoubleSidedNormalMode("Double sided normal mode", Float) = 1 |
|||
[HideInInspector] _DoubleSidedConstants("_DoubleSidedConstants", Vector) = (1, 1, -1, 0) |
|||
|
|||
[Enum(UV0, 0, Planar, 4, TriPlanar, 5)] _UVBase("UV Set for base", Float) = 0 |
|||
_TexWorldScale("Scale to apply on world coordinate", Float) = 1.0 |
|||
[HideInInspector] _InvTilingScale("Inverse tiling scale = 2 / (abs(_BaseColorMap_ST.x) + abs(_BaseColorMap_ST.y))", Float) = 1 |
|||
[HideInInspector] _UVMappingMask("_UVMappingMask", Color) = (1, 0, 0, 0) |
|||
[Enum(TangentSpace, 0, ObjectSpace, 1)] _NormalMapSpace("NormalMap space", Float) = 0 |
|||
|
|||
[Enum(Subsurface Scattering, 0, Standard, 1, Anisotropy, 2, ClearCoat, 3, Specular Color, 4)] _MaterialID("MaterialId", Int) = 1 // MaterialId.RegularLighting |
|||
|
|||
[Enum(None, 0, Vertex displacement, 1, Pixel displacement, 2)] _DisplacementMode("DisplacementMode", Int) = 0 |
|||
[ToggleOff] _DisplacementLockObjectScale("displacement lock object scale", Float) = 1.0 |
|||
[ToggleOff] _DisplacementLockTilingScale("displacement lock tiling scale", Float) = 1.0 |
|||
[ToggleOff] _DepthOffsetEnable("Depth Offset View space", Float) = 0.0 |
|||
|
|||
_PPDMinSamples("Min sample for POM", Range(1.0, 64.0)) = 5 |
|||
_PPDMaxSamples("Max sample for POM", Range(1.0, 64.0)) = 15 |
|||
_PPDLodThreshold("Start lod to fade out the POM effect", Range(0.0, 16.0)) = 5 |
|||
_PPDPrimitiveLength("Primitive length for POM", Float) = 1 |
|||
_PPDPrimitiveWidth("Primitive width for POM", Float) = 1 |
|||
[HideInInspector] _InvPrimScale("Inverse primitive scale for non-planar POM", Vector) = (1, 1, 0, 0) |
|||
|
|||
[Enum(UV0, 0, UV1, 1, UV2, 2, UV3, 3)] _UVDetail("UV Set for detail", Float) = 0 |
|||
[HideInInspector] _UVDetailsMappingMask("_UVDetailsMappingMask", Color) = (1, 0, 0, 0) |
|||
[ToggleOff] _LinkDetailsWithBase("LinkDetailsWithBase", Float) = 1.0 |
|||
[Enum(Use Emissive Color, 0, Use Emissive Mask, 1)] _EmissiveColorMode("Emissive color mode", Float) = 1 |
|||
|
|||
// Wind |
|||
[ToggleOff] _EnableWind("Enable Wind", Float) = 0.0 |
|||
_InitialBend("Initial Bend", float) = 1.0 |
|||
_Stiffness("Stiffness", float) = 1.0 |
|||
_Drag("Drag", float) = 1.0 |
|||
_ShiverDrag("Shiver Drag", float) = 0.2 |
|||
_ShiverDirectionality("Shiver Directionality", Range(0.0, 1.0)) = 0.5 |
|||
|
|||
// Caution: C# code in BaseLitUI.cs call LightmapEmissionFlagsProperty() which assume that there is an existing "_EmissionColor" |
|||
// value that exist to identify if the GI emission need to be enabled. |
|||
// In our case we don't use such a mechanism but need to keep the code quiet. We declare the value and always enable it. |
|||
// TODO: Fix the code in legacy unity so we can customize the beahvior for GI |
|||
_EmissionColor("Color", Color) = (1, 1, 1) |
|||
} |
|||
|
|||
HLSLINCLUDE |
|||
|
|||
#pragma target 4.5 |
|||
#pragma only_renderers d3d11 ps4 metal // TEMP: until we go futher in dev |
|||
//#pragma enable_d3d11_debug_symbols |
|||
|
|||
//------------------------------------------------------------------------------------- |
|||
// Variant |
|||
//------------------------------------------------------------------------------------- |
|||
|
|||
#pragma shader_feature _ALPHATEST_ON |
|||
#pragma shader_feature _DEPTHOFFSET_ON |
|||
#pragma shader_feature _DOUBLESIDED_ON |
|||
#pragma shader_feature _ _VERTEX_DISPLACEMENT _PIXEL_DISPLACEMENT |
|||
#pragma shader_feature _VERTEX_DISPLACEMENT_LOCK_OBJECT_SCALE |
|||
#pragma shader_feature _DISPLACEMENT_LOCK_TILING_SCALE |
|||
#pragma shader_feature _PIXEL_DISPLACEMENT_LOCK_OBJECT_SCALE |
|||
#pragma shader_feature _VERTEX_WIND |
|||
#pragma shader_feature _ _REFRACTION_PLANE _REFRACTION_SPHERE |
|||
|
|||
#pragma shader_feature _ _MAPPING_PLANAR _MAPPING_TRIPLANAR |
|||
#pragma shader_feature _NORMALMAP_TANGENT_SPACE |
|||
#pragma shader_feature _ _REQUIRE_UV2 _REQUIRE_UV3 |
|||
|
|||
#pragma shader_feature _NORMALMAP |
|||
#pragma shader_feature _MASKMAP |
|||
#pragma shader_feature _OCCLUSIONMAP |
|||
#pragma shader_feature _BENTNORMALMAP |
|||
#pragma shader_feature _EMISSIVE_COLOR_MAP |
|||
#pragma shader_feature _ENABLESPECULAROCCLUSION |
|||
#pragma shader_feature _HEIGHTMAP |
|||
#pragma shader_feature _TANGENTMAP |
|||
#pragma shader_feature _ANISOTROPYMAP |
|||
#pragma shader_feature _DETAIL_MAP |
|||
#pragma shader_feature _DETAIL_MAP_LEGACY |
|||
#pragma shader_feature _DETAIL_MASK_MAP_LEGACY |
|||
#pragma shader_feature _SUBSURFACE_RADIUS_MAP |
|||
#pragma shader_feature _THICKNESSMAP |
|||
#pragma shader_feature _SPECULARCOLORMAP |
|||
|
|||
// Keyword for transparent |
|||
#pragma shader_feature _SURFACE_TYPE_TRANSPARENT |
|||
#pragma shader_feature _ _BLENDMODE_ALPHA _BLENDMODE_ADD _BLENDMODE_MULTIPLY _BLENDMODE_PRE_MULTIPLY |
|||
#pragma shader_feature _BLENDMODE_PRESERVE_SPECULAR_LIGHTING |
|||
#pragma shader_feature _ENABLE_FOG_ON_TRANSPARENT |
|||
|
|||
// MaterialId are used as shader feature to allow compiler to optimize properly |
|||
// Note _MATID_STANDARD is not define as there is always the default case "_". We assign default as _MATID_STANDARD, so we never test _MATID_STANDARD |
|||
#pragma shader_feature _ _MATID_SSS _MATID_ANISO _MATID_SPECULAR _MATID_CLEARCOAT |
|||
|
|||
#pragma multi_compile LIGHTMAP_OFF LIGHTMAP_ON |
|||
#pragma multi_compile DIRLIGHTMAP_OFF DIRLIGHTMAP_COMBINED |
|||
#pragma multi_compile DYNAMICLIGHTMAP_OFF DYNAMICLIGHTMAP_ON |
|||
// enable dithering LOD crossfade |
|||
#pragma multi_compile _ LOD_FADE_CROSSFADE |
|||
// TODO: We should have this keyword only if VelocityInGBuffer is enable, how to do that ? |
|||
//#pragma multi_compile VELOCITYOUTPUT_OFF VELOCITYOUTPUT_ON |
|||
|
|||
//------------------------------------------------------------------------------------- |
|||
// Define |
|||
//------------------------------------------------------------------------------------- |
|||
|
|||
#define UNITY_MATERIAL_LIT // Need to be define before including Material.hlsl |
|||
// Use surface gradient normal mapping as it handle correctly triplanar normal mapping and multiple UVSet |
|||
#define SURFACE_GRADIENT |
|||
// This shader support vertex modification |
|||
#define HAVE_VERTEX_MODIFICATION |
|||
|
|||
//------------------------------------------------------------------------------------- |
|||
// Include |
|||
//------------------------------------------------------------------------------------- |
|||
|
|||
#include "../../../Core/ShaderLibrary/Common.hlsl" |
|||
#include "../../../Core/ShaderLibrary/Wind.hlsl" |
|||
#include "../../ShaderPass/FragInputs.hlsl" |
|||
#include "../../ShaderPass/ShaderPass.cs.hlsl" |
|||
|
|||
|
|||
//------------------------------------------------------------------------------------- |
|||
// variable declaration |
|||
//------------------------------------------------------------------------------------- |
|||
|
|||
TEXTURE2D(_DetailMapLegacy); |
|||
SAMPLER2D(sampler_DetailMapLegacy); |
|||
|
|||
TEXTURE2D(_DetailMaskMapLegacy); |
|||
SAMPLER2D(sampler_DetailMaskMapLegacy); |
|||
|
|||
TEXTURE2D(_OcclusionMap); |
|||
SAMPLER2D(sampler_OcclusionMap); |
|||
|
|||
#include "../../Material/Lit/LitProperties.hlsl" |
|||
|
|||
// All our shaders use same name for entry point |
|||
#pragma vertex Vert |
|||
#pragma fragment Frag |
|||
|
|||
ENDHLSL |
|||
|
|||
SubShader |
|||
{ |
|||
Pass |
|||
{ |
|||
Name "GBuffer" // Name is not used |
|||
Tags { "LightMode" = "GBuffer" } // This will be only for opaque object based on the RenderQueue index |
|||
|
|||
Cull [_CullMode] |
|||
|
|||
Stencil |
|||
{ |
|||
Ref [_StencilRef] |
|||
Comp Always |
|||
Pass Replace |
|||
} |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_GBUFFER |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitSharePass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassGBufferTransitional.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
// This pass is the same as GBuffer only it does not do alpha test (the clip instruction is removed) |
|||
// This is due to the fact that on GCN, any shader with a clip instruction cannot benefit from HiZ so when we do a prepass, in order to get the most performance, we need to make a special case in the subsequent GBuffer pass. |
|||
Pass |
|||
{ |
|||
Name "GBufferWithPrepass" // Name is not used |
|||
Tags { "LightMode" = "GBufferWithPrepass" } // This will be only for opaque object based on the RenderQueue index |
|||
|
|||
Cull [_CullMode] |
|||
|
|||
Stencil |
|||
{ |
|||
Ref [_StencilRef] |
|||
Comp Always |
|||
Pass Replace |
|||
} |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_GBUFFER |
|||
#define _BYPASS_ALPHA_TEST |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitSharePass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassGBufferTransitional.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "GBufferDebugDisplay" // Name is not used |
|||
Tags{ "LightMode" = "GBufferDebugDisplay" } // This will be only for opaque object based on the RenderQueue index |
|||
|
|||
Cull [_CullMode] |
|||
|
|||
Stencil |
|||
{ |
|||
Ref [_StencilRef] |
|||
Comp Always |
|||
Pass Replace |
|||
} |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define DEBUG_DISPLAY |
|||
#define SHADERPASS SHADERPASS_GBUFFER |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Debug/DebugDisplay.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitSharePass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassGBufferTransitional.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
// Extracts information for lightmapping, GI (emission, albedo, ...) |
|||
// This pass it not used during regular rendering. |
|||
Pass |
|||
{ |
|||
Name "META" |
|||
Tags{ "LightMode" = "Meta" } |
|||
|
|||
Cull Off |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
// Lightmap memo |
|||
// DYNAMICLIGHTMAP_ON is used when we have an "enlighten lightmap" ie a lightmap updated at runtime by enlighten.This lightmap contain indirect lighting from realtime lights and realtime emissive material.Offline baked lighting(from baked material / light, |
|||
// both direct and indirect lighting) will hand up in the "regular" lightmap->LIGHTMAP_ON. |
|||
|
|||
#define SHADERPASS SHADERPASS_LIGHT_TRANSPORT |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitMetaPass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassLightTransport.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "ShadowCaster" |
|||
Tags{ "LightMode" = "ShadowCaster" } |
|||
|
|||
Cull[_CullMode] |
|||
|
|||
ZClip Off |
|||
ZWrite On |
|||
ZTest LEqual |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_SHADOWS |
|||
#define USE_LEGACY_UNITY_MATRIX_VARIABLES |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitDepthPass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassDepthOnly.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "DepthOnly" |
|||
Tags{ "LightMode" = "DepthOnly" } |
|||
|
|||
Cull[_CullMode] |
|||
|
|||
ZWrite On |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_DEPTH_ONLY |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitDepthPass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassDepthOnly.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "Motion Vectors" |
|||
Tags{ "LightMode" = "MotionVectors" } // Caution, this need to be call like this to setup the correct parameters by C++ (legacy Unity) |
|||
|
|||
Cull[_CullMode] |
|||
|
|||
ZWrite Off // TODO: Test Z equal here. |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_VELOCITY |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitVelocityPass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassVelocity.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "Distortion" // Name is not used |
|||
Tags { "LightMode" = "DistortionVectors" } // This will be only for transparent object based on the RenderQueue index |
|||
|
|||
Blend [_DistortionSrcBlend] [_DistortionDstBlend], [_DistortionBlurSrcBlend] [_DistortionBlurDstBlend] |
|||
BlendOp Add, [_DistortionBlurBlendOp] |
|||
ZTest [_ZTestMode] |
|||
ZWrite off |
|||
Cull [_CullMode] |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_DISTORTION |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Material/Material.hlsl" |
|||
#include "ShaderPass/LitDistortionPass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassDistortion.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "Forward" // Name is not used |
|||
Tags { "LightMode" = "Forward" } // This will be only for transparent object based on the RenderQueue index |
|||
|
|||
Blend [_SrcBlend] [_DstBlend] |
|||
ZWrite [_ZWrite] |
|||
Cull [_CullMode] |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define SHADERPASS SHADERPASS_FORWARD |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Lighting/Forward.hlsl" |
|||
// TEMP until pragma work in include |
|||
#pragma multi_compile LIGHTLOOP_SINGLE_PASS LIGHTLOOP_TILE_PASS |
|||
|
|||
#include "../../Lighting/Lighting.hlsl" |
|||
#include "ShaderPass/LitSharePass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassForward.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
Pass |
|||
{ |
|||
Name "ForwardDebugDisplay" // Name is not used |
|||
Tags{ "LightMode" = "ForwardDebugDisplay" } // This will be only for transparent object based on the RenderQueue index |
|||
|
|||
Blend[_SrcBlend][_DstBlend] |
|||
ZWrite[_ZWrite] |
|||
Cull[_CullMode] |
|||
|
|||
HLSLPROGRAM |
|||
|
|||
#define DEBUG_DISPLAY |
|||
#define SHADERPASS SHADERPASS_FORWARD |
|||
#include "../../ShaderVariables.hlsl" |
|||
#include "../../Debug/DebugDisplay.hlsl" |
|||
#include "../../Lighting/Forward.hlsl" |
|||
// TEMP until pragma work in include |
|||
#pragma multi_compile LIGHTLOOP_SINGLE_PASS LIGHTLOOP_TILE_PASS |
|||
|
|||
#include "../../Lighting/Lighting.hlsl" |
|||
#include "ShaderPass/LitSharePass.hlsl" |
|||
#include "LitData.hlsl" |
|||
#include "../../ShaderPass/ShaderPassForward.hlsl" |
|||
|
|||
ENDHLSL |
|||
} |
|||
|
|||
} |
|||
|
|||
CustomEditor "Experimental.Rendering.HDPipeline.LitTransitionalGUI" |
|||
} |
|
|||
using System; |
|||
using UnityEngine; |
|||
using UnityEngine.Experimental.Rendering; |
|||
using UnityEngine.Experimental.Rendering.HDPipeline; |
|||
|
|||
|
|||
namespace UnityEditor.Experimental.Rendering.HDPipeline |
|||
{ |
|||
class LitTransitionalGUI : LitGUI |
|||
{ |
|||
protected MaterialProperty occlusionMap = new MaterialProperty(); |
|||
protected const string kOcclusionMap = "_OcclusionMap"; |
|||
protected MaterialProperty detailMapLegacy = new MaterialProperty(); |
|||
protected const string kDetailMapLegacy = "_DetailMapLegacy"; |
|||
protected MaterialProperty detailMaskMapLegacy = new MaterialProperty(); |
|||
protected const string kDetailMaskMapLegacy = "_DetailMaskMapLegacy"; |
|||
|
|||
protected static class Styles |
|||
{ |
|||
public static GUIContent occlusionMapText = new GUIContent("Occlusion Map", "Occlusion Map"); |
|||
public static GUIContent detailMaskMapLegacyText = new GUIContent("Detail Mask Map", "Detail Mask Map"); |
|||
public static GUIContent detailMapLegacyText = new GUIContent("Detail Map", "Detail Map"); |
|||
public static string LegacyText = "Legacy"; |
|||
} |
|||
|
|||
protected override void MaterialPropertiesGUI(Material material) |
|||
{ |
|||
EditorGUILayout.LabelField(Styles.LegacyText, EditorStyles.boldLabel); |
|||
|
|||
EditorGUI.indentLevel++; |
|||
m_MaterialEditor.TexturePropertySingleLine(Styles.occlusionMapText, occlusionMap); |
|||
m_MaterialEditor.TexturePropertySingleLine(Styles.detailMapLegacyText, detailMapLegacy); |
|||
m_MaterialEditor.TexturePropertySingleLine(Styles.detailMaskMapLegacyText, detailMaskMapLegacy); |
|||
EditorGUI.indentLevel--; |
|||
base.MaterialPropertiesGUI(material); |
|||
|
|||
} |
|||
|
|||
protected override void FindMaterialProperties(MaterialProperty[] props) |
|||
{ |
|||
base.FindMaterialProperties(props); |
|||
occlusionMap = FindProperty(string.Format("{0}{1}", kOcclusionMap, ""), props); |
|||
detailMapLegacy = FindProperty(string.Format("{0}{1}", kDetailMapLegacy, ""), props); |
|||
detailMaskMapLegacy = FindProperty(string.Format("{0}{1}", kDetailMaskMapLegacy, ""), props); |
|||
} |
|||
|
|||
static public void SetupLitTransitionalKeywords(Material material) |
|||
{ |
|||
SetKeyword(material, "_OCCLUSIONMAP", material.GetTexture(kOcclusionMap)); |
|||
SetKeyword(material, "_DETAIL_MAP_LEGACY", material.GetTexture(kDetailMapLegacy)); |
|||
SetKeyword(material, "_DETAIL_MASK_MAP_LEGACY", material.GetTexture(kDetailMaskMapLegacy)); |
|||
} |
|||
|
|||
protected override void SetupMaterialKeywordsAndPassInternal(Material material) |
|||
{ |
|||
base.SetupMaterialKeywordsAndPassInternal(material); |
|||
SetupLitTransitionalKeywords(material); |
|||
} |
|||
|
|||
static public void SetupMaterialKeywordsAndPass(Material material) |
|||
{ |
|||
LitGUI.SetupMaterialKeywordsAndPass(material); |
|||
SetupLitTransitionalKeywords(material); |
|||
} |
|||
} |
|||
} |
|
|||
using NUnit.Framework; |
|||
using UnityEngine; |
|||
|
|||
namespace UnityEditor.Experimental.Rendering.HDPipeline |
|||
{ |
|||
class StandardSpecularToHDLitTransitionalMaterialUpgrader : MaterialUpgrader |
|||
{ |
|||
public StandardSpecularToHDLitTransitionalMaterialUpgrader() : this("Standard (Specular setup)", "HDRenderPipeline/Lit", LitGUI.SetupMaterialKeywordsAndPass) { } |
|||
|
|||
public StandardSpecularToHDLitTransitionalMaterialUpgrader(string sourceShaderName, string destShaderName, MaterialFinalizer finalizer) |
|||
{ |
|||
RenameShader(sourceShaderName, destShaderName, finalizer); |
|||
CommonRename(); |
|||
|
|||
RenameTexture("_SpecGlossMap", "_SpecularColorMap"); |
|||
} |
|||
|
|||
public override void Convert(Material srcMaterial, Material dstMaterial) |
|||
{ |
|||
base.Convert(srcMaterial, dstMaterial); |
|||
CommonConvert(srcMaterial, dstMaterial); |
|||
|
|||
dstMaterial.SetFloat("_MaterialID", 4.0f); |
|||
Color c = new Color(1,1,1,1); |
|||
dstMaterial.SetColor("_SpecularColor", c); |
|||
float smoothness = srcMaterial.GetFloat("_Glossiness"); |
|||
dstMaterial.SetFloat("_Smoothness", smoothness * smoothness); |
|||
} |
|||
} |
|||
} |
|
|||
using NUnit.Framework; |
|||
using UnityEngine; |
|||
|
|||
namespace UnityEditor.Experimental.Rendering.HDPipeline |
|||
{ |
|||
public class StandardToHDLitTransitionalMaterialUpgrader : MaterialUpgrader |
|||
{ |
|||
public StandardToHDLitTransitionalMaterialUpgrader() : this("Standard", "HDRenderPipeline/LitTransitional", LitGUI.SetupMaterialKeywordsAndPass) { } |
|||
|
|||
public StandardToHDLitTransitionalMaterialUpgrader(string sourceShaderName, string destShaderName, MaterialFinalizer finalizer) |
|||
{ |
|||
RenameShader(sourceShaderName, destShaderName, finalizer); |
|||
CommonRename(); |
|||
|
|||
RenameTexture("_MetallicGlossMap", "_MaskMap"); |
|||
RenameFloat("_Metallic", "_Metallic"); |
|||
} |
|||
|
|||
public override void Convert(Material srcMaterial, Material dstMaterial) |
|||
{ |
|||
base.Convert(srcMaterial, dstMaterial); |
|||
CommonConvert(srcMaterial, dstMaterial); |
|||
|
|||
if (srcMaterial.GetTexture("_MetallicGlossMap") != null) |
|||
{ |
|||
dstMaterial.SetFloat("_Metallic", 1.0f); |
|||
} |
|||
} |
|||
} |
|||
} |
|
|||
#if SHADERPASS != SHADERPASS_GBUFFER |
|||
#error SHADERPASS_is_not_correctly_define |
|||
#endif |
|||
|
|||
#include "VertMesh.hlsl" |
|||
|
|||
PackedVaryingsType Vert(AttributesMesh inputMesh) |
|||
{ |
|||
VaryingsType varyingsType; |
|||
varyingsType.vmesh = VertMesh(inputMesh); |
|||
return PackVaryingsType(varyingsType); |
|||
} |
|||
|
|||
#ifdef TESSELLATION_ON |
|||
|
|||
PackedVaryingsToPS VertTesselation(VaryingsToDS input) |
|||
{ |
|||
VaryingsToPS output; |
|||
output.vmesh = VertMeshTesselation(input.vmesh); |
|||
return PackVaryingsToPS(output); |
|||
} |
|||
|
|||
#include "TessellationShare.hlsl" |
|||
|
|||
#endif // TESSELLATION_ON |
|||
|
|||
half3 LerpWhiteTo(half3 b, half t) |
|||
{ |
|||
half oneMinusT = 1 - t; |
|||
return half3(oneMinusT, oneMinusT, oneMinusT) + b * t; |
|||
} |
|||
|
|||
|
|||
void Frag( PackedVaryingsToPS packedInput, |
|||
OUTPUT_GBUFFER(outGBuffer) |
|||
OUTPUT_GBUFFER_VELOCITY(outVelocityBuffer) |
|||
#ifdef _DEPTHOFFSET_ON |
|||
, out float outputDepth : SV_Depth |
|||
#endif |
|||
) |
|||
{ |
|||
FragInputs input = UnpackVaryingsMeshToFragInputs(packedInput.vmesh); |
|||
|
|||
// input.unPositionSS is SV_Position |
|||
PositionInputs posInput = GetPositionInput(input.unPositionSS.xy, _ScreenSize.zw); |
|||
UpdatePositionInput(input.unPositionSS.z, input.unPositionSS.w, input.positionWS, posInput); |
|||
float3 V = GetWorldSpaceNormalizeViewDir(input.positionWS); |
|||
|
|||
SurfaceData surfaceData; |
|||
BuiltinData builtinData; |
|||
GetSurfaceAndBuiltinData(input, V, posInput, surfaceData, builtinData); |
|||
|
|||
#ifdef _OCCLUSIONMAP |
|||
UVMapping occlusionTexcoord; |
|||
ZERO_INITIALIZE(UVMapping, occlusionTexcoord); |
|||
occlusionTexcoord.uv = input.texCoord0; |
|||
surfaceData.ambientOcclusion = SAMPLE_UVMAPPING_TEXTURE2D(_OcclusionMap, sampler_OcclusionMap, occlusionTexcoord).g; |
|||
#else |
|||
surfaceData.ambientOcclusion = 1.0f; |
|||
#endif |
|||
|
|||
#ifdef _DETAIL_MAP_LEGACY |
|||
UVMapping detailTexcoord; |
|||
ZERO_INITIALIZE(UVMapping, detailTexcoord); |
|||
detailTexcoord.uv = input.texCoord0 * _DetailMap_ST.xy + _DetailMap_ST.zw; |
|||
float3 detailAlbedo = saturate(SAMPLE_UVMAPPING_TEXTURE2D(_DetailMapLegacy, sampler_DetailMapLegacy, detailTexcoord).rgb * 2.0f); |
|||
float detailMask = 1.0f; |
|||
#ifdef _DETAIL_MASK_MAP_LEGACY |
|||
detailMask = SAMPLE_UVMAPPING_TEXTURE2D(_DetailMaskMapLegacy, sampler_DetailMaskMapLegacy, detailTexcoord).a; |
|||
#endif |
|||
surfaceData.baseColor *= LerpWhiteTo (detailAlbedo, detailMask); |
|||
#endif |
|||
|
|||
BSDFData bsdfData = ConvertSurfaceDataToBSDFData(surfaceData); |
|||
|
|||
PreLightData preLightData = GetPreLightData(V, posInput, bsdfData); |
|||
|
|||
float3 bakeDiffuseLighting = GetBakedDiffuseLigthing(surfaceData, builtinData, bsdfData, preLightData); |
|||
|
|||
ENCODE_INTO_GBUFFER(surfaceData, bakeDiffuseLighting, outGBuffer); |
|||
ENCODE_VELOCITY_INTO_GBUFFER(builtinData.velocity, outVelocityBuffer); |
|||
|
|||
#ifdef _DEPTHOFFSET_ON |
|||
outputDepth = posInput.depthRaw; |
|||
#endif |
|||
} |
撰写
预览
正在加载...
取消
保存
Reference in new issue