Import L1 (celery) as l1/
This commit is contained in:
9
l1/sexp_effects/effects/invert.sexp
Normal file
9
l1/sexp_effects/effects/invert.sexp
Normal file
@@ -0,0 +1,9 @@
|
||||
;; Invert effect - inverts all colors
|
||||
;; Uses vectorized invert-img primitive for fast processing
|
||||
;; amount param: 0 = no invert, 1 = full invert (threshold at 0.5)
|
||||
|
||||
(require-primitives "color_ops")
|
||||
|
||||
(define-effect invert
|
||||
:params ((amount :type float :default 1 :range [0 1]))
|
||||
(if (> amount 0.5) (color_ops:invert-img frame) frame))
|
||||
Reference in New Issue
Block a user