BrushCue Example: Blur Reveal Animation¶
You can use this tool online at https://www.brushcue.com/tools/blur-reveal-animation
In [ ]:
!pip install brushcue
In [ ]:
import brushcue as bc
duration = 3.0
@bc.brushcue_fn
def frame(time):
input_image = bc.Composition.monet_women_with_parasol()
blur_strength = 20.0
input_image_bounds = input_image.bounds()
return input_image.gaussian_blur(
(blur_strength * (1.0 - (time / duration)))
).crop(
bc.Bounds2f.from_x_y_width_height(
0.0, 0.0, input_image_bounds.width(), input_image_bounds.height()
)
)
graph = bc.Sequence.graph(duration, frame)
ctx = bc.Context()
sequence = graph.execute(ctx)
# Render `sequence` to a video file as needed.