From df2791adfcd5c2173102a3e11125d80951de6ff3 Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Fri, 14 Feb 2025 23:20:59 +0530 Subject: Add gif for sin pattern --- 4-im-a-sinner/main.ua | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to '4-im-a-sinner/main.ua') diff --git a/4-im-a-sinner/main.ua b/4-im-a-sinner/main.ua index 00dfb26..a4f0390 100644 --- a/4-im-a-sinner/main.ua +++ b/4-im-a-sinner/main.ua @@ -1,9 +1,8 @@ -W ← 400 # width -H ← 400 # height -S ← 0.08 # scale -I ← 30 # max iterations -Ox ← 0 # offset x -Oy ← 0 # offset y +W ← 400 # width +H ← 400 # height +S ← 0.08 # scale +F ← 20 # number of frames for gif +Fps ← 10 # frame rate for gif ToPixel ← ⍣( 0.16_0.16_0.21 ⍤.>0 @@ -13,9 +12,12 @@ ToPixel ← ⍣( | 0.31_0.23_0.64 ⍤.≤1.1⌵ | 0.09_0.57_0.6 ⍤.≤1.3⌵ | 0.16_0.16_0.21 - # | 0.74_0.58_0.98 ) -Iterations ← - ⊙(∿×2×) ◡(+ ⊓∿(∿+η) ∩(×.)) °ℂ -Img ← ∵(ToPixel Iterations) ⊞ℂ ∩(÷S -0.5 ÷W) ⊓(-Oy)(-Ox) ⇡H⇡W +Equation ← - ⊙(∿××) ◡(+ ⊓∿(∿+η) ∩(×.)) °ℂ +Grid ← ⊞ℂ ∩(÷S -0.5 ÷W) ⇡H⇡W +Img ← ∵(ToPixel Equation: 2) Grid &fwa "./4-im-a-sinner/output.png" img "png" Img + +Frames ← ≡(∵(ToPixel Equation) Grid) ×6 ÷F-÷2F⇡+1F +&fwa "./4-im-a-sinner/output.gif" gif Fps Frames -- cgit v1.3.1