function ScreenSpace.GetDepthForWidth(V,K)local q=ScreenSpace.AspectRatio()local I=math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)local y=q*I local S,w=ScreenSpace.ViewSizeX(),ScreenSpace.ViewSizeY()return-(S*K)/((V*2)*y)end function ScreenSpace.GetDepthForHeight(V,K)local q=math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)local I=ScreenSpace.ViewSizeY()return-(I*K)/((V*2)*q)end

function ScreenSpace.GetDepthForWidth(screenWidth, worldWidth)
	local aspectRatio = ScreenSpace.AspectRatio()
	local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
	local wfactor = aspectRatio*hfactor
	local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
	--
	return -(sx * worldWidth) / (screenWidth * 2 * wfactor)	
end
function ScreenSpace.GetDepthForHeight(screenHeight, worldHeight)
	local hfactor = math.tan(math.rad(Workspace.CurrentCamera.FieldOfView)/2)
	local sy = ScreenSpace.ViewSizeY()
	--
	return -(sy * worldHeight) / (screenHeight * 2 * hfactor)	
end
