Skip to content

Commit

Permalink
Feature/task 711 unitychan eyes toon ev curve issue (unity3d-jp#35)
Browse files Browse the repository at this point in the history
* Removed warrnings in the shader unnecessary arg in a function.

* Updated Unity chan eye material.
  • Loading branch information
H3idi-X authored Aug 19, 2021
1 parent 4946945 commit 118d1db
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,16 @@ Material:
m_PrefabAsset: {fileID: 0}
m_Name: ToonShader_Eye_Clipping_StencilMask_Firefly
m_Shader: {fileID: 4800000, guid: 873188af6a7b5ca49aa69929a5d863c1, type: 3}
m_ShaderKeywords: _ _EMISSIVE_SIMPLE _IS_ANGELRING_OFF _IS_CLIPPING_MODE _IS_OUTLINE_CLIPPING_YES
m_ShaderKeywords: _ _EMISSIVE_SIMPLE _IS_ANGELRING_OFF _IS_CLIPPING_TRANSMODE _IS_OUTLINE_CLIPPING_YES
_OUTLINE_NML
m_LightmapFlags: 5
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: 2449
m_CustomRenderQueue: 3000
stringTagMap:
IgnoreProjection: False
RenderType: TransparentCutout
disabledShaderPasses:
- SRPDEFAULTUNLIT
IgnoreProjection: true
RenderType: Transparent
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
Expand Down Expand Up @@ -240,7 +239,7 @@ Material:
- _BumpScaleMatcap: 1
- _CameraRolling_Stabilizer: 0
- _ClippingMatteMode: 0
- _ClippingMode: 1
- _ClippingMode: 2
- _Clipping_Level: 0
- _CoatMask: 0
- _ColorShift_Speed: 0
Expand Down Expand Up @@ -368,8 +367,8 @@ Material:
- _Rotate_EmissiveUV: 0
- _Rotate_MatCapUV: 0
- _Rotate_NormalMapForMatCapUV: 0
- _SPRDefaultUnlitColorMask: 15
- _SRPDefaultUnlitColMode: 1
- _SPRDefaultUnlitColorMask: 0
- _SRPDefaultUnlitColMode: 2
- _SSRefractionProjectionModel: 0
- _Scroll_EmissiveU: 0
- _Scroll_EmissiveV: 0
Expand Down Expand Up @@ -411,7 +410,7 @@ Material:
- _TransparentCullMode: 2
- _TransparentDepthPostpassEnable: 0
- _TransparentDepthPrepassEnable: 0
- _TransparentEnabled: 0
- _TransparentEnabled: 1
- _TransparentSortPriority: 0
- _TransparentWritingMotionVec: 0
- _TweakHighColorOnShadow: 0
Expand All @@ -432,20 +431,20 @@ Material:
- _UseShadowThreshold: 0
- _Use_1stAs2nd: 0
- _Use_BaseAs1st: 0
- _ZOverDrawMode: 0
- _ZOverDrawMode: 1
- _ZTestDepthEqualForOpaque: 4
- _ZTestGBuffer: 4
- _ZTestModeDistortion: 8
- _ZTestTransparent: 4
- _ZWrite: 1
- _ZWriteMode: 1
- _ZWriteMode: 0
- _isUnityToonshader: 1
- _simpleUI: 0
- _utsTechnique: 0
- _utsVersion: 2.075
- _utsVersionX: 0
- _utsVersionY: 0
- _utsVersionZ: 2
- _utsVersionY: 2
- _utsVersionZ: 1
m_Colors:
- _1st_ShadeColor: {r: 1, g: 1, b: 1, a: 1}
- _2nd_ShadeColor: {r: 0, g: 0, b: 0, a: 1}
Expand Down Expand Up @@ -481,3 +480,4 @@ Material:
- _UVMappingMask: {r: 1, g: 0, b: 0, a: 0}
- _UVMappingMaskEmissive: {r: 1, g: 0, b: 0, a: 0}
- _ViewShift: {r: 0, g: 0, b: 0, a: 1}
m_BuildTextureStacks: []

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions com.unity.toonshader/Runtime/HDRP/Shaders/HDRPToon.shader
Original file line number Diff line number Diff line change
Expand Up @@ -632,8 +632,6 @@ Shader "HDRP/Toon"
HLSLPROGRAM

#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch
//enable GPU instancing support
#pragma multi_compile_instancing
#pragma instancing_options renderinglayer
#pragma multi_compile _ DOTS_INSTANCING_ON

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -635,8 +635,6 @@ Shader "HDRP/ToonTessellation"
HLSLPROGRAM

#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch
//enable GPU instancing support
#pragma multi_compile_instancing
#pragma instancing_options renderinglayer
#pragma multi_compile _ DOTS_INSTANCING_ON

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ void Frag(PackedVaryingsToPS packedInput,
float3 envLightColor = envColor;
float3 envLightIntensity = GetLightAttenuation(envLightColor) < 1 ? GetLightAttenuation(envLightColor) : 1;
float3 finalColorWoEmissive = SATURATE_IF_SDR(finalColor) + (envLightColor * envLightIntensity * _GI_Intensity * smoothstep(1, 0, envLightIntensity / 2));
finalColorWoEmissive = GetExposureAdjustedColor(finalColorWoEmissive, posInput );
finalColorWoEmissive = GetExposureAdjustedColor(finalColorWoEmissive );
finalColor = finalColorWoEmissive + emissive;

#if defined(_SHADINGGRADEMAP)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ float WeightSample(PositionInputs positionInput)
}


float3 GetExposureAdjustedColor(float3 originalColor, PositionInputs posInput)
float3 GetExposureAdjustedColor(float3 originalColor)
{
if (_ToonEvAdjustmentCurve != 0)
{
Expand Down

0 comments on commit 118d1db

Please sign in to comment.