using System;
using Cpp2IlInjected;
using UnityEngine;
using UnityEngine.Experimental.Rendering.Universal;
using UnityEngine.Rendering;
using UnityEngine.Rendering.Universal;

// Token: 0x020002EB RID: 747
[Token(Token = "0x20002EB")]
public class GameVolumeController : MonoBehaviour
{
	// Token: 0x06001BE8 RID: 7144 RVA: 0x000020D3 File Offset: 0x000002D3
	[Token(Token = "0x6001BE8")]
	[Address(RVA = "0x54C170", Offset = "0x54AF70", VA = "0x18054C170")]
	public void Init()
	{
		throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
	}

	// Token: 0x06001BE9 RID: 7145 RVA: 0x000020D3 File Offset: 0x000002D3
	[Token(Token = "0x6001BE9")]
	[Address(RVA = "0x54CCC0", Offset = "0x54BAC0", VA = "0x18054CCC0")]
	private void Update()
	{
		throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
	}

	// Token: 0x06001BEA RID: 7146 RVA: 0x000422BC File Offset: 0x000404BC
	[Token(Token = "0x6001BEA")]
	[Address(RVA = "0x54CC30", Offset = "0x54BA30", VA = "0x18054CC30")]
	private void UpdateVolumeSettings(ScreenSettings settings)
	{
		FloatParameter postExposure = this.colorAdjustments.postExposure;
		int num = 0;
		float brightnessValue = settings.GetBrightnessValue();
		postExposure.value = num;
		Bloom bloom = this.bloom;
		bool bloomEffect = settings.bloomEffect;
		bloom.active = bloomEffect;
		DepthOfField depthOfField = this.dof;
		bool depthOfField2 = settings.depthOfField;
		depthOfField.active = depthOfField2;
	}

	// Token: 0x06001BEB RID: 7147 RVA: 0x0004231C File Offset: 0x0004051C
	[Token(Token = "0x6001BEB")]
	[Address(RVA = "0x54BF30", Offset = "0x54AD30", VA = "0x18054BF30")]
	public void EnableAimEffect(bool enable)
	{
		if (!enable)
		{
			this.ResetDefaultDofValues();
			return;
		}
		this.dof.focusDistance.value = 20f;
		this.dof.focalLength.value = 100f;
		Renderer2DData rendererData = ((IRenderPass2D)this.dof.aperture).rendererData;
	}

	// Token: 0x06001BEC RID: 7148 RVA: 0x00042378 File Offset: 0x00040578
	[Token(Token = "0x6001BEC")]
	[Address(RVA = "0x54C0C0", Offset = "0x54AEC0", VA = "0x18054C0C0")]
	public void EnableStoryEffect(bool enable)
	{
		if (!enable)
		{
			this.ResetDefaultDofValues();
			return;
		}
		this.dof.focusDistance.value = 1f;
		this.dof.focalLength.value = 30f;
		Renderer2DData rendererData = ((IRenderPass2D)this.dof.aperture).rendererData;
	}

	// Token: 0x06001BED RID: 7149 RVA: 0x000423D4 File Offset: 0x000405D4
	[Token(Token = "0x6001BED")]
	[Address(RVA = "0x54C660", Offset = "0x54B460", VA = "0x18054C660")]
	private void ResetDefaultDofValues()
	{
		DepthOfField depthOfField = this.dof;
		int num = 0;
		if (!(depthOfField == num))
		{
			MinFloatParameter focusDistance = this.dof.focusDistance;
			float num2 = this.defaultDofFocusDistance;
			focusDistance.value = num2;
			ClampedFloatParameter focalLength = this.dof.focalLength;
			float num3 = this.defaultDofFocalLength;
			focalLength.value = num3;
			ClampedFloatParameter aperture = this.dof.aperture;
			float num4 = this.defaultDofAperture;
			aperture.value = num4;
		}
	}

	// Token: 0x06001BEE RID: 7150 RVA: 0x00042450 File Offset: 0x00040650
	[Token(Token = "0x6001BEE")]
	[Address(RVA = "0x54BFE0", Offset = "0x54ADE0", VA = "0x18054BFE0")]
	public void EnableLightningMode(bool enable)
	{
		this.bLightningMode = enable;
	}

	// Token: 0x06001BEF RID: 7151 RVA: 0x00042464 File Offset: 0x00040664
	[Token(Token = "0x6001BEF")]
	[Address(RVA = "0x54BFF0", Offset = "0x54ADF0", VA = "0x18054BFF0")]
	public void EnableStage04BlackFog(bool enable)
	{
		this.bStage04BlackFog = enable;
	}

	// Token: 0x06001BF0 RID: 7152 RVA: 0x00042478 File Offset: 0x00040678
	[Token(Token = "0x6001BF0")]
	[Address(RVA = "0x54C000", Offset = "0x54AE00", VA = "0x18054C000")]
	public void EnableStage04Room08Effect(bool enable)
	{
		bool flag = this.bVignette;
		this.bStage04Room08Story = enable;
		if (!enable)
		{
			if (flag)
			{
				ClampedFloatParameter intensity = this.vignette.intensity;
				int num = 0;
				intensity.value = (float)num;
			}
			this.ResetDefaultDofValues();
			return;
		}
		if (flag)
		{
			this.vignette.intensity.value = 0.6f;
		}
		Renderer2DData rendererData = ((IRenderPass2D)this.dof.focusDistance).rendererData;
	}

	// Token: 0x06001BF1 RID: 7153 RVA: 0x000020D3 File Offset: 0x000002D3
	[Token(Token = "0x6001BF1")]
	[Address(RVA = "0x54C750", Offset = "0x54B550", VA = "0x18054C750")]
	public void SetProfile(VolumeProfile profile)
	{
		throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
	}

	// Token: 0x06001BF2 RID: 7154 RVA: 0x000424E8 File Offset: 0x000406E8
	[Token(Token = "0x6001BF2")]
	[Address(RVA = "0x54C540", Offset = "0x54B340", VA = "0x18054C540")]
	private void OnDisable()
	{
		Game.OnScreenSettingsChanged -= new Action(this.UpdateVolumeSettings);
		this.ResetDefaultDofValues();
	}

	// Token: 0x06001BF3 RID: 7155 RVA: 0x0004250C File Offset: 0x0004070C
	[Token(Token = "0x6001BF3")]
	[Address(RVA = "0x3088F0", Offset = "0x3076F0", VA = "0x1803088F0")]
	public GameVolumeController()
	{
	}

	// Token: 0x0400257B RID: 9595
	[FieldOffset(Offset = "0x18")]
	[Token(Token = "0x400257B")]
	private Volume volume;

	// Token: 0x0400257C RID: 9596
	[FieldOffset(Offset = "0x20")]
	[Token(Token = "0x400257C")]
	private ColorAdjustments colorAdjustments;

	// Token: 0x0400257D RID: 9597
	[FieldOffset(Offset = "0x28")]
	[Token(Token = "0x400257D")]
	private Bloom bloom;

	// Token: 0x0400257E RID: 9598
	[FieldOffset(Offset = "0x30")]
	[Token(Token = "0x400257E")]
	private DepthOfField dof;

	// Token: 0x0400257F RID: 9599
	[FieldOffset(Offset = "0x38")]
	[Token(Token = "0x400257F")]
	private Vignette vignette;

	// Token: 0x04002580 RID: 9600
	[FieldOffset(Offset = "0x40")]
	[Token(Token = "0x4002580")]
	private ChromaticAberration chromaticAberration;

	// Token: 0x04002581 RID: 9601
	[FieldOffset(Offset = "0x48")]
	[Token(Token = "0x4002581")]
	private SplitToning splitToning;

	// Token: 0x04002582 RID: 9602
	[FieldOffset(Offset = "0x50")]
	[Token(Token = "0x4002582")]
	private float defaultDofFocusDistance;

	// Token: 0x04002583 RID: 9603
	[FieldOffset(Offset = "0x54")]
	[Token(Token = "0x4002583")]
	private float defaultDofFocalLength;

	// Token: 0x04002584 RID: 9604
	[FieldOffset(Offset = "0x58")]
	[Token(Token = "0x4002584")]
	private float defaultDofAperture;

	// Token: 0x04002585 RID: 9605
	[FieldOffset(Offset = "0x5C")]
	[Token(Token = "0x4002585")]
	private bool bChromaticAberration;

	// Token: 0x04002586 RID: 9606
	[FieldOffset(Offset = "0x60")]
	[Token(Token = "0x4002586")]
	private float fChromaticAberrationIntensity;

	// Token: 0x04002587 RID: 9607
	[FieldOffset(Offset = "0x64")]
	[Token(Token = "0x4002587")]
	private bool bSplitToning;

	// Token: 0x04002588 RID: 9608
	[FieldOffset(Offset = "0x68")]
	[Token(Token = "0x4002588")]
	private float fSplitToningColorWeight;

	// Token: 0x04002589 RID: 9609
	[FieldOffset(Offset = "0x6C")]
	[Token(Token = "0x4002589")]
	private bool bLightningMode;

	// Token: 0x0400258A RID: 9610
	[FieldOffset(Offset = "0x6D")]
	[Token(Token = "0x400258A")]
	private bool bVignette;

	// Token: 0x0400258B RID: 9611
	[FieldOffset(Offset = "0x6E")]
	[Token(Token = "0x400258B")]
	private bool bStage04BlackFog;

	// Token: 0x0400258C RID: 9612
	[FieldOffset(Offset = "0x70")]
	[Token(Token = "0x400258C")]
	private float fVignetteIntensity;

	// Token: 0x0400258D RID: 9613
	[FieldOffset(Offset = "0x74")]
	[Token(Token = "0x400258D")]
	private bool bStage04Room08Story;
}
