Skip to main content

DepthOfFieldEffect

Handles interpolation of depth of field, which is tricky due to how Roblox implemented the shader and how it interacts with other depth of field effects.

Functions​

SetFocusDistanceTarget​

DepthOfFieldEffect.SetFocusDistanceTarget(
focusDistanceTarget: number,
doNotAnimate: boolean?
) → ()

Sets the target depth of field distance

SetInFocusRadiusTarget​

DepthOfFieldEffect.SetInFocusRadiusTarget(
inFocusRadiusTarget: number,
doNotAnimate: boolean?
) → ()

Sets the target depth of field radius

SetNearIntensityTarget​

DepthOfFieldEffect.SetNearIntensityTarget(
nearIntensityTarget: number,
doNotAnimate: boolean?
) → ()

Sets the near intensity target

SetFarIntensityTarget​

DepthOfFieldEffect.SetFarIntensityTarget(
farIntensityTarget: number,
doNotAnimate: boolean?
) → ()

Sets the far intensity target

GetFocusDistanceTarget​

DepthOfFieldEffect.GetFocusDistanceTarget(self: DepthOfFieldEffect) → number

Retrieves the distance target

GetInFocusRadiusTarget​

DepthOfFieldEffect.GetInFocusRadiusTarget(self: DepthOfFieldEffect) → number

Retrieves the radius target

GetNearIntensityTarget​

DepthOfFieldEffect.GetNearIntensityTarget(self: DepthOfFieldEffect) → number

Retrieve the near intensity target

GetFarIntensityTarget​

DepthOfFieldEffect.GetFarIntensityTarget(self: DepthOfFieldEffect) → number

Retrieve the far intensity target

Show raw api
{
    "functions": [
        {
            "name": "SetFocusDistanceTarget",
            "desc": "Sets the target depth of field distance",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                },
                {
                    "name": "focusDistanceTarget",
                    "desc": "",
                    "lua_type": "number"
                },
                {
                    "name": "doNotAnimate",
                    "desc": "",
                    "lua_type": "boolean?"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 87,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "SetInFocusRadiusTarget",
            "desc": "Sets the target depth of field radius",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                },
                {
                    "name": "inFocusRadiusTarget",
                    "desc": "",
                    "lua_type": "number"
                },
                {
                    "name": "doNotAnimate",
                    "desc": "",
                    "lua_type": "boolean?"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 102,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "SetNearIntensityTarget",
            "desc": "Sets the near intensity target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                },
                {
                    "name": "nearIntensityTarget",
                    "desc": "",
                    "lua_type": "number"
                },
                {
                    "name": "doNotAnimate",
                    "desc": "",
                    "lua_type": "boolean?"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 117,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "SetFarIntensityTarget",
            "desc": "Sets the far intensity target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                },
                {
                    "name": "farIntensityTarget",
                    "desc": "",
                    "lua_type": "number"
                },
                {
                    "name": "doNotAnimate",
                    "desc": "",
                    "lua_type": "boolean?"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 132,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "GetFocusDistanceTarget",
            "desc": "Retrieves the distance target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 146,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "GetInFocusRadiusTarget",
            "desc": "Retrieves the radius target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 154,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "GetNearIntensityTarget",
            "desc": "Retrieve the near intensity target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 162,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        },
        {
            "name": "GetFarIntensityTarget",
            "desc": "Retrieve the far intensity target",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "DepthOfFieldEffect"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 170,
                "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
            }
        }
    ],
    "properties": [],
    "types": [],
    "name": "DepthOfFieldEffect",
    "desc": "Handles interpolation of depth of field, which is tricky due to how Roblox implemented the shader\nand how it interacts with other depth of field effects.",
    "source": {
        "line": 8,
        "path": "src/depthoffield/src/Client/DepthOfFieldEffect.lua"
    }
}