mirror of
https://github.com/thegatesbrowser/thegates.git
synced 2025-08-24 20:17:31 -04:00
24 lines
591 B
GDScript
24 lines
591 B
GDScript
extends Control
|
|
class_name VignetteBlur
|
|
|
|
const BLUR_AMOUNT = &"BlurAmount"
|
|
const UV_SCALE = &"UVScale"
|
|
|
|
@export var blur_amount: float
|
|
@export var blur_amount_started: float
|
|
@export var uv_scale: Vector2
|
|
@export var uv_scale_startd: Vector2
|
|
|
|
|
|
func thumbnail_params() -> void:
|
|
set_param(BLUR_AMOUNT, blur_amount)
|
|
set_param(UV_SCALE, uv_scale)
|
|
|
|
|
|
func gate_started_params() -> void:
|
|
set_param(BLUR_AMOUNT, blur_amount_started)
|
|
set_param(UV_SCALE, uv_scale_startd)
|
|
|
|
|
|
func set_param(param: StringName, value: Variant) -> void:
|
|
(material as ShaderMaterial).set_shader_parameter(param, value)
|