public override void PopulateCommandBuffer(CommandBuffer cb) { FogModel.Settings settings = base.model.settings; Material mat = base.context.materialFactory.Get("Hidden/Post FX/Fog"); mat.shaderKeywords = null; mat.SetColor(Uniforms._FogColor, RenderSettings.fogColor); mat.SetFloat(Uniforms._Density, RenderSettings.fogDensity); mat.SetFloat(Uniforms._Start, RenderSettings.fogStartDistance); mat.SetFloat(Uniforms._End, RenderSettings.fogEndDistance); FogMode fogMode = RenderSettings.fogMode; if (fogMode == FogMode.Linear) { mat.EnableKeyword("FOG_LINEAR"); } else if (fogMode == FogMode.Exponential) { mat.EnableKeyword("FOG_EXP"); } else if (fogMode == FogMode.ExponentialSquared) { mat.EnableKeyword("FOG_EXP2"); } RenderTextureFormat format = !base.context.isHdr ? RenderTextureFormat.Default : RenderTextureFormat.DefaultHDR; cb.GetTemporaryRT(Uniforms._TempRT, base.context.width, base.context.height, 0x18, FilterMode.Bilinear, format); cb.Blit(2, Uniforms._TempRT); cb.Blit(Uniforms._TempRT, 2, mat, !settings.excludeSkybox ? 0 : 1); cb.ReleaseTemporaryRT(Uniforms._TempRT); }
// Token: 0x06001E8D RID: 7821 RVA: 0x0017C964 File Offset: 0x0017AB64 public override void PopulateCommandBuffer(CommandBuffer cb) { FogModel.Settings settings = base.model.settings; Material material = this.context.materialFactory.Get("Hidden/Post FX/Fog"); material.shaderKeywords = null; Color value = GraphicsUtils.isLinearColorSpace ? RenderSettings.fogColor.linear : RenderSettings.fogColor; material.SetColor(FogComponent.Uniforms._FogColor, value); material.SetFloat(FogComponent.Uniforms._Density, RenderSettings.fogDensity); material.SetFloat(FogComponent.Uniforms._Start, RenderSettings.fogStartDistance); material.SetFloat(FogComponent.Uniforms._End, RenderSettings.fogEndDistance); switch (RenderSettings.fogMode) { case FogMode.Linear: material.EnableKeyword("FOG_LINEAR"); break; case FogMode.Exponential: material.EnableKeyword("FOG_EXP"); break; case FogMode.ExponentialSquared: material.EnableKeyword("FOG_EXP2"); break; } RenderTextureFormat format = this.context.isHdr ? RenderTextureFormat.DefaultHDR : RenderTextureFormat.Default; cb.GetTemporaryRT(FogComponent.Uniforms._TempRT, this.context.width, this.context.height, 24, FilterMode.Bilinear, format); cb.Blit(BuiltinRenderTextureType.CameraTarget, FogComponent.Uniforms._TempRT); cb.Blit(FogComponent.Uniforms._TempRT, BuiltinRenderTextureType.CameraTarget, material, settings.excludeSkybox ? 1 : 0); cb.ReleaseTemporaryRT(FogComponent.Uniforms._TempRT); }
public override void PopulateCommandBuffer(CommandBuffer cb) { FogModel.Settings settings = base.model.settings; Material material = this.context.materialFactory.Get("Hidden/Post FX/Fog"); material.shaderKeywords = null; material.SetColor(FogComponent.Uniforms._FogColor, RenderSettings.fogColor); material.SetFloat(FogComponent.Uniforms._Density, RenderSettings.fogDensity); material.SetFloat(FogComponent.Uniforms._Start, RenderSettings.fogStartDistance); material.SetFloat(FogComponent.Uniforms._End, RenderSettings.fogEndDistance); FogMode fogMode = RenderSettings.fogMode; if (fogMode != FogMode.Linear) { if (fogMode != FogMode.Exponential) { if (fogMode == FogMode.ExponentialSquared) { material.EnableKeyword("FOG_EXP2"); } } else { material.EnableKeyword("FOG_EXP"); } } else { material.EnableKeyword("FOG_LINEAR"); } RenderTextureFormat format = (!this.context.isHdr) ? RenderTextureFormat.Default : RenderTextureFormat.DefaultHDR; cb.GetTemporaryRT(FogComponent.Uniforms._TempRT, this.context.width, this.context.height, 24, FilterMode.Bilinear, format); cb.Blit(BuiltinRenderTextureType.CameraTarget, FogComponent.Uniforms._TempRT); cb.Blit(FogComponent.Uniforms._TempRT, BuiltinRenderTextureType.CameraTarget, material, (!settings.excludeSkybox) ? 0 : 1); cb.ReleaseTemporaryRT(FogComponent.Uniforms._TempRT); }
// Token: 0x0600681C RID: 26652 RVA: 0x00027A33 File Offset: 0x00025C33 public void EOONHGFEMDO(FogModel.Settings BGBMIEJJQKC) { this.m_Settings = BGBMIEJJQKC; }
// Token: 0x06006823 RID: 26659 RVA: 0x00027A33 File Offset: 0x00025C33 public void LEMOMMDPLKK(FogModel.Settings BGBMIEJJQKC) { this.m_Settings = BGBMIEJJQKC; }
// Token: 0x06006821 RID: 26657 RVA: 0x00027A33 File Offset: 0x00025C33 public void GJOHNHLCMID(FogModel.Settings BGBMIEJJQKC) { this.m_Settings = BGBMIEJJQKC; }
// Token: 0x0600681E RID: 26654 RVA: 0x00027A33 File Offset: 0x00025C33 public void KMDFEEPLPIH(FogModel.Settings BGBMIEJJQKC) { this.m_Settings = BGBMIEJJQKC; }