A transition for your SwiftUI views that simulates the 1993 classic DOOM screen wipe (the melting effect, you know the one!)
Important
This transition utilizes SwiftUI 5's .layerEffect. AppKit/UIKit powered views will not work. This includes views like TextField
.
Use it like any other transition:
import DoomWipe
MyView()
.transition(.doomWipe)
Additionally, you can initialize a Shader
with custom parameters to setup your own transitions. Or to apply the .layerEffect
wherever.
import DoomWipe
let doomWipe = DoomWipeShader(
dimensions: viewDimensions,
animationPosition: time,
direction: .down
)
let shader: Shader = doomWipe.shader