Skip to content

Commit

Permalink
slightly increase depth offset
Browse files Browse the repository at this point in the history
  • Loading branch information
LGhassen committed Apr 19, 2020
1 parent ad25c2b commit 1affed0
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion scatterer/Scatterer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public partial class Scatterer: MonoBehaviour
bool coreInitiated = false;
public bool isActive = false;
public bool unifiedCameraMode = false;
public string versionNumber = "0.056";
public string versionNumber = "0.0600";

void Awake ()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Pass {
ZWrite Off

Blend DstColor Zero //multiplicative
Offset 0.0, -0.05
Offset 0.0, -0.07

CGPROGRAM
#pragma vertex vert
Expand Down Expand Up @@ -103,7 +103,7 @@ Pass {
ZWrite Off

Blend OneMinusDstColor One //soft additive
Offset 0.0, -0.05
Offset 0.0, -0.07

CGPROGRAM
#pragma vertex vert
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ Shader "Scatterer/OceanWhiteCaps"
"IgnoreProjector"="True"}

Blend SrcAlpha OneMinusSrcAlpha
Offset 0.0, -0.10 //give a superior depth offset to that of localScattering to prevent scattering that should be behind ocean from appearing in front
Offset 0.0, -0.14

Cull Back

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ Shader "Scatterer/OceanWhiteCapsPixelLights"
"IgnoreProjector"="True"}

Blend SrcAlpha OneMinusSrcAlpha
Offset 0.0, -0.10 //give a superior depth offset to that of localScattering to prevent scattering that should be behind ocean from appearing in front
Offset 0.0, -0.14 //give a superior depth offset to that of localScattering to prevent scattering that should be behind ocean from appearing in front

Cull Back

Expand Down Expand Up @@ -574,7 +574,7 @@ Shader "Scatterer/OceanWhiteCapsPixelLights"


Blend One OneMinusSrcColor //"reverse" soft-additive
Offset 0.0, -0.10 //give a superior depth offset to that of localScattering to prevent scattering that should be behind ocean from appearing in front
Offset 0.0, -0.14 //give a superior depth offset to that of localScattering to prevent scattering that should be behind ocean from appearing in front

CGPROGRAM
#include "UnityCG.cginc"
Expand Down

0 comments on commit 1affed0

Please sign in to comment.