local M={AcrylicBlur=require(script.AcrylicBlur);CreateAcrylic=require(script.CreateAcrylic);AcrylicPaint=require(script.AcrylicPaint)}function M.init()local B=Instance.new("\068\101\112\116\104\079\102\070\105\101\108\100\069\102\102\101\099\116")B.FarIntensity=0 B.InFocusRadius=.1 B.NearIntensity=1 local f={}function M.Enable()for M,B in pairs(f)do B.Enabled=false end B.Parent=game:GetService("\076\105\103\104\116\105\110\103")end function M.Disable()for M,B in pairs(f)do B.Enabled=B.enabled end B.Parent=nil end local function e()local function M(M)if M:IsA("\068\101\112\116\104\079\102\070\105\101\108\100\069\102\102\101\099\116")then f[M]={enabled=M.Enabled}end end for B,f in pairs((game:GetService("\076\105\103\104\116\105\110\103")):GetChildren())do M(f)end if(game:GetService("\087\111\114\107\115\112\097\099\101")).CurrentCamera then for B,f in pairs((game:GetService("\087\111\114\107\115\112\097\099\101")).CurrentCamera:GetChildren())do M(f)end end end e()M.Enable()end return M
local Acrylic = {
	AcrylicBlur = require(script.AcrylicBlur),
	CreateAcrylic = require(script.CreateAcrylic),
	AcrylicPaint = require(script.AcrylicPaint),
}

function Acrylic.init()
	local baseEffect = Instance.new("DepthOfFieldEffect")
	baseEffect.FarIntensity = 0
	baseEffect.InFocusRadius = 0.1
	baseEffect.NearIntensity = 1

	local depthOfFieldDefaults = {}

	function Acrylic.Enable()
		for _, effect in pairs(depthOfFieldDefaults) do
			effect.Enabled = false
		end
		baseEffect.Parent = game:GetService("Lighting")
	end

	function Acrylic.Disable()
		for _, effect in pairs(depthOfFieldDefaults) do
			effect.Enabled = effect.enabled
		end
		baseEffect.Parent = nil
	end

	local function registerDefaults()
		local function register(object)
			if object:IsA("DepthOfFieldEffect") then
				depthOfFieldDefaults[object] = { enabled = object.Enabled }
			end
		end

		for _, child in pairs(game:GetService("Lighting"):GetChildren()) do
			register(child)
		end

		if game:GetService("Workspace").CurrentCamera then
			for _, child in pairs(game:GetService("Workspace").CurrentCamera:GetChildren()) do
				register(child)
			end
		end
	end

	registerDefaults()
	Acrylic.Enable()
end

return Acrylic
