Allow independent distortion of rgb channels

This commit is contained in:
2025-11-19 10:38:30 +00:00
parent 8759431fec
commit 610936a5fa
6 changed files with 72 additions and 31 deletions
+5 -4
View File
@@ -11,16 +11,17 @@ testEvent :: World -> World
testEvent w = fromMaybe w $ do
cpos <- w ^? cWorld . lWorld . creatures . ix 0 . crPos . _xy
let distR = 50
t1 = (V2 1 (-1))
t2 = (V2 1 1)
t3 = (V2 distR 0)
distortionBulge =
RadialDistortion
cpos
(V2 distR 0)
(V2 0 distR)
(V2 1 (-1))
(V2 1 1)
(V2 distR 0)
t1 t2 t3 t1 t2 t3 t1 t2 t3
20
return $ w & cWorld . lWorld . distortions .~ [distortionBulge
, distortionBulge & rdPos +~ 50
, distortionBulge & rdPos +~ 50 & rdT1R +~ V2 (-1) 1
, distortionBulge & rdPos +~ (-50)
]