RealityControl{ global: import "common.ulb" import "Standard.ulb" int numformulas=3; Formula f[3]; f[0]=new @formulaClass1(0) f[1]=new @formulaClass2(0) f[2]=new @formulaClass3(0) init: z = #pixel int count=0; #z = f[count%numformulas].Init(#pixel) f[1].Init(#pixel); f[2].Init(#pixel); loop: ;------Start Plugins ----------- if @ask_Startplugins == true #z = f[count%numformulas].Iterate(#z) count=count+1 endif ;------Main Formula ------------ z = #z ;z = fn1(asinh(cotan(z)^@power + @seed)) if @RCcontrols == 0 if @mixRC == 0 z = fn1(asinh(cotan(z)^@power + @seed)) z = fn2(asinh(z) + (1/log(acos(z) - cos(@seed)/z))) z = fn3(z) elseif @mixRC == 1 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(imag(z)) - cos(@seed)/z))) z = fn3(z) elseif @mixRC == 2 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(real(z)) - cos(@seed)/z))) z = fn3(z) elseif @mixRC == 3 z = fn1(asinh(cotan(z)^@power + real(@seed))) z = fn2(asinh(z) + (1/log(acos(z) - cos(imag(@seed)/z)))) z = fn3(z) elseif @mixRC == 4 z = fn1(asinh(cotan(z)^@power + imag(@seed))) z = fn2(asinh(z) + (1/log(acos(z) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 5 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(real(z)) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 6 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(real(z)) - cos(imag(@seed)/z)))) z = fn3(z) elseif @mixRC == 7 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(imag(z)) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 8 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + imag(1/log(acos(z) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 9 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - imag(cos(@seed)/z)))) z = fn3(z) elseif @mixRC == 10 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - cos(@seed)/z))) z = fn3(z) elseif @mixRC == 11 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - real(cos(@seed)/z)))) z = fn3(z) elseif @mixRC == 12 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(real(z)) - cos(real(@seed)/imag(z))))) z = fn3(z) elseif @mixRC == 13 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - imag(cos(@seed)/z)))) z = fn3(z) elseif @mixRC == 14 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + imag(1/log(acos(real(z)) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 15 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(real(z)) - cos(real(@seed)/z)))) z = fn3(z) elseif @mixRC == 16 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(real(z)) - cos(real(@seed)/real(z))))) z = fn3(z) elseif @mixRC == 17 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(real(z)) - cos(real(@seed)/imag(z))))) z = fn3(z) elseif @mixRC == 18 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - imag(cos(@seed)/real(z))))) z = fn3(z) elseif @mixRC == 19 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + real(1/log(acos(z) - imag(cos(@seed)/imag(z))))) z = fn3(z) elseif @mixRC == 20 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(imag(z)) - cos(real(@seed)/real(z))))) z = fn3(z) elseif @mixRC == 21 z = fn1(asinh(cotan(z)^real(@power) + @seed)) z = fn2(asinh(z) + (1/log(acos(imag(z)) - cos(real(@seed)/imag(z))))) z = fn3(z) endif elseif @RCcontrols == 1 if @a1 == 0 AA = #z Elseif @a1 == 1 AA = Real(#z) Elseif @a1 == 2 AA = imag(#z) endif if @a2 == 0 AB = @power elseif @a2 == 1 AB = real(@power) elseif @a2 == 2 AB = imag(@power) endif if @a3 == 0 AC = @Seed elseif @a3 == 1 AC = real(@Seed) elseif @a3 == 2 AC = imag(@Seed) endif if @a4 == 0 AD = cotan(AA) elseif @a4 == 1 AD = real(cotan(AA)) elseif @a4 == 2 AD = imag(cotan(AA)) endif if @a5 == 0 AE = AD^AB elseif @a5 == 1 AE = real(AD^AB) elseif @a5 == 2 AE = imag(AD^AB) endif if @a6 == 0 AF = AE+AC elseif @a6 == 1 AF = real(AE+AC) elseif @a6 == 2 AF = imag(AE+AC) endif if @a7 == 0 AG = asinh(AF) elseif @a7 == 1 AG = real(asinh(AF)) elseif @a7 == 2 AG = imag(asinh(AF)) endif if @a8 == 0 AH = fn1(AG) elseif @a8 == 1 AH = real(fn1(AG)) elseif @a8 == 2 AH = imag(fn1(AG)) endif if @a9 == 0 z = AH elseif @a9 == 1 z = real(AH) elseif @a9 == 2 z = imag(AH) endif ;z = fn2(asinh(z) + (1/log(acos(z) - cos(@seed)/z))) if @b0 == 0 BA = z elseif @b0 == 1 BA = real(z) elseif @b0 == 2 BA = imag(z) endif if @b1 == 0 BB = @seed elseif @b1 == 1 BB = real(@seed) elseif @b1 == 2 BB = imag(@seed) endif if @b2 == 0 BC = acos(BA) elseif @b2 == 1 BC = real(acos(BA)) elseif @b2 == 2 BC = imag(acos(BA)) endif if @b3 == 0 BD = cos(BB) elseif @b3 == 1 BD = real(cos(BB)) elseif @b3 == 2 BD = imag(cos(BB)) endif if @b4 == 0 BE = BD/BA elseif @b4 == 1 BE = real(BD/BA) elseif @b4 == 2 BE = imag(BD/BA) endif if @b5 == 0 BF = BC - BE elseif @b5 == 1 BF = real(BC - BE) elseif @b5 == 2 BF = imag(BC - BE) endif if @b6 == 0 BG = log(BF) elseif @b6 == 1 BG = real(log(BF)) elseif @b6 == 2 BG = imag(log(BF)) endif if @b7 == 0 BH = 1/BG elseif @b7 == 1 BH = real(1/BG) elseif @b7 == 2 BH = imag(1/BG) endif if @b8 == 0 BI = asinh(BA) elseif @b8 == 1 BI = real(asinh(BA)) elseif @b9 == 2 BI = imag(asinh(BA)) endif if @b10 == 0 BJ = BI + BH elseif @b10 == 1 BJ = real(BI + BH) elseif @b10 == 2 BJ = imag(BI + BH) endif if @b11 == 0 BK = fn2(BJ) elseif @b11 == 1 BK = real(fn2(BJ)) elseif @b11 == 2 BK = imag(fn2(BJ)) endif if @b12 == 0 z = BK elseif @b12 == 1 z = real(BK) elseif @b12 == 2 z = imag(BK) endif ; z = fn3(z) if @c0 == 0 CA = z elseif @c0 == 1 CA = real(z) elseif @c0 == 2 CA = imag(z) endif if @c1 == 0 CB = fn3(CA) elseif @c1 == 1 CB = real(fn3(CA)) elseif @c1 == 2 CB = imag(fn3(CA)) endif if @c2 == 0 z = CB elseif @c2 == 1 z = real(CB) elseif @c2 == 2 z = imag(CB) endif endif ;------Ending Plugins ---------- if @ask_endplugins == true #z = f[count%numformulas].Iterate(#z) count=count+1 endif ;--- Chaotica if @Chaos == True if fn4(z)+@ChaosFactor> pixel z=z+pixel else z=z*pixel endif endif ;------DetailPump--------------- if @DetailPump == 0 Elseif @DetailPump == 1 z = z * (9.5/10) Elseif @DetailPump == 2 z = z * (9/10) Elseif @DetailPump == 3 z = z * (8/10) Elseif @DetailPump == 4 z = z * (7/10) Elseif @DetailPump == 5 z = z * (6/10) Elseif @DetailPump == 6 z = z * (5/10) Elseif @DetailPump == 7 z = z * (4/10) Elseif @DetailPump == 8 z = z * (3/10) Elseif @DetailPump == 9 z = z * (2/10) Elseif @DetailPump == 10 z = z * (1/10) Elseif @DetailPump == 11 z = z * z Elseif @DetailPump == 12 z = z * 2 Elseif @DetailPump == 13 z = z * 3 Elseif @DetailPump == 14 z = z * 4 Elseif @DetailPump == 15 z = z * 5 Elseif @DetailPump == 16 z = z * 6 Elseif @DetailPump == 17 z = z * 7 Elseif @DetailPump == 18 z = z * 8 Elseif @DetailPump == 19 z = z * 9 Elseif @DetailPump == 20 z = z * 10 elseif @DetailPump == 21 z = z * @DetailSelf elseif @DetailPump == 22 z = z / @DetailSelfD Endif ;-------End Reality Controls if @EndRC == 0 z = fn4(z) Elseif @EndRC == 1 z = real(fn4(z)) Elseif @EndRC == 2 z = imag(fn4(z)) endif ; ----------final function bailout: |z| <= @bailout default: title = "Reality Play" heading caption = "External Formula Controls" endheading Formula param formulaClass1 caption = "Formula #1" default = Standard_Pixel endparam Formula param formulaClass2 caption = "Formula #1" default = Standard_Pixel endparam Formula param formulaClass3 caption = "Formula #1" default = Standard_Pixel endparam bool param @ask_endplugins caption = "ending plugins" default = false endparam bool param @ask_Startplugins caption = "Starting Plugins" default = true endparam heading caption = "reality controls" endheading param RCcontrols enum = "Mix" "Self" default = 0 endparam param mixRC enum = "none" "Mix-1" "Mix-2" "Mix-3" "Mix-4" "Mix-5" "Mix-6" "Mix-7" "Mix-8" "Mix-9" "Mix-10" "Mix-11" "Mix-12" "Mix-13" "Mix-14" "Mix-15" "Mix-16" "Mix-17" "Mix-18" "Mix-19" "Mix-20" "Mix-21" caption = "Mixed Reality" default = 0 visible = @RCcontrols == 0 endparam param EndRC enum = "None" "Real" "Imaginary" caption = "End Reality Controls" default = 0 visible = @RCcontrols == 1 endparam param a1 enum = "None" "Real" "Imaginary" caption = "A1" default = 0 visible = @RCcontrols == 1 endparam param a2 enum = "None" "Real" "Imaginary" caption = "A2" default = 0 visible = @RCcontrols == 1 endparam param a3 enum = "None" "Real" "Imaginary" caption = "A3" default = 0 visible = @RCcontrols == 1 endparam param a4 enum = "None" "Real" "Imaginary" caption = "A4" default = 0 visible = @RCcontrols == 1 endparam param a5 enum = "None" "Real" "Imaginary" caption = "A5" default = 0 visible = @RCcontrols == 1 endparam param a6 enum = "None" "Real" "Imaginary" caption = "A6" default = 0 visible = @RCcontrols == 1 endparam param a7 enum = "None" "Real" "Imaginary" caption = "A7" default = 0 visible = @RCcontrols == 1 endparam param a8 enum = "None" "Real" "Imaginary" caption = "A8" default = 0 visible = @RCcontrols == 1 endparam param a9 enum = "None" "Real" "Imaginary" caption = "A9" default = 0 visible = @RCcontrols == 1 endparam param b0 enum = "None" "Real" "Imaginary" caption = "b0" default = 0 visible = @RCcontrols == 1 endparam param b1 enum = "None" "Real" "Imaginary" caption = "b1" default = 0 visible = @RCcontrols == 1 endparam param b2 enum = "None" "Real" "Imaginary" caption = "b2" default = 0 visible = @RCcontrols == 1 endparam param b3 enum = "None" "Real" "Imaginary" caption = "b3" default = 0 visible = @RCcontrols == 1 endparam param b4 enum = "None" "Real" "Imaginary" caption = "b" default = 0 visible = @RCcontrols == 1 endparam param b5 enum = "None" "Real" "Imaginary" caption = "b5" default = 0 visible = @RCcontrols == 1 endparam param b6 enum = "None" "Real" "Imaginary" caption = "b6" default = 0 visible = @RCcontrols == 1 endparam param b7 enum = "None" "Real" "Imaginary" caption = "b7" default = 0 visible = @RCcontrols == 1 endparam param b8 enum = "None" "Real" "Imaginary" caption = "b8" default = 0 visible = @RCcontrols == 1 endparam param b9 enum = "None" "Real" "Imaginary" caption = "b9" default = 0 visible = @RCcontrols == 1 endparam param b10 enum = "None" "Real" "Imaginary" caption = "b10" default = 0 visible = @RCcontrols == 1 endparam param b11 enum = "None" "Real" "Imaginary" caption = "b11" default = 0 visible = @RCcontrols == 1 endparam param b12 enum = "None" "Real" "Imaginary" caption = "b12" default = 0 visible = @RCcontrols == 1 endparam param c0 enum = "None" "Real" "Imaginary" caption = "c0" default = 0 visible = @RCcontrols == 1 endparam param c1 enum = "None" "Real" "Imaginary" caption = "c1" default = 0 visible = @RCcontrols == 1 endparam param c2 enum = "None" "Real" "Imaginary" caption = "c2" default = 0 visible = @RCcontrols == 1 endparam heading caption = "Internal Formula Controls" endheading param seed caption = "Julia seed" default = (-1.25, 0) endparam param power caption = "Power" default = (2,0) endparam param bailout caption = "Bailout value" default = 4.0 min = 1.0 endparam heading caption = "Details" endheading param DetailPump enum = "none" "10%" "20%" "30%" "40%" "50%" "60%" "70%" "80%" "90%" "100%" "z" "*2" "*3" "*4" "*5" "*6" "*7" "*8" "*9" "*10" "Self *" "Self /" caption = "Detail Pump" default = 0 endparam param DetailSelf caption = "Self Detail Pump *" default = (0, 0) visible = @DetailPump == 21 endparam param DetailSelfD caption = "Self Detail Pump /" default = (0, 0) visible = @DetailPump == 22 endparam bool param Chaos caption = "Chaotic" default = false endparam param ChaosFactor caption = "Factor of Chaos" default = (0,0) visible = @Chaos == true endparam heading caption = "Function Controls" endheading func fn1 caption = "Function" default = ident () endfunc func fn2 caption = "Function 2" default = ident () endfunc func fn3 caption = "Function 3" default = abs () endfunc func fn4 caption = "Function 4" default = conj () endfunc switch: type = "Mandelbrot" power = power bailout = bailout } Mandelbrot++ { init: z = #pixel loop: z = atan(z^@power) + (@Seed) z = asin(log(z^@start) - (@feed)^(1/@power)) z = fn1(fn2(fn3(fn4(z)))) ;--- Chaotica if @Chaos == True if fn4(z)+@ChaosFactor> pixel z=z+pixel else z=z*pixel endif endif ;------DetailPump--------------- if @DetailPump == 0 Elseif @DetailPump == 1 z = z * (9.5/10) Elseif @DetailPump == 2 z = z * (9/10) Elseif @DetailPump == 3 z = z * (8/10) Elseif @DetailPump == 4 z = z * (7/10) Elseif @DetailPump == 5 z = z * (6/10) Elseif @DetailPump == 6 z = z * (5/10) Elseif @DetailPump == 7 z = z * (4/10) Elseif @DetailPump == 8 z = z * (3/10) Elseif @DetailPump == 9 z = z * (2/10) Elseif @DetailPump == 10 z = z * (1/10) Elseif @DetailPump == 11 z = z * z Elseif @DetailPump == 12 z = z * 2 Elseif @DetailPump == 13 z = z * 3 Elseif @DetailPump == 14 z = z * 4 Elseif @DetailPump == 15 z = z * 5 Elseif @DetailPump == 16 z = z * 6 Elseif @DetailPump == 17 z = z * 7 Elseif @DetailPump == 18 z = z * 8 Elseif @DetailPump == 19 z = z * 9 Elseif @DetailPump == 20 z = z * 10 elseif @DetailPump == 21 z = z * @DetailSelf elseif @DetailPump == 22 z = z / @DetailSelfD Endif bailout: |z| <= @bailout default: title = "Mandelbrot ++" center = (0, 0) heading caption = "Function Controls" endheading func fn1 caption = "Function" default = ident () endfunc func fn2 caption = "Function 2" default = ident () endfunc func fn3 caption = "Function 3" default = ident () endfunc func fn4 caption = "Function 4" default = ident () endfunc heading caption = "Formula Controls" endheading param start caption = "Arms" default = (2,0) endparam param power caption = "Power" default = (2,0) endparam param Seed caption = "Seed" default = (-1.47,0) endparam param Feed caption = "Feed" default = (1,0) endparam param bailout caption = "Bailout value" default = (4.0,0) endparam heading caption = "Details" endheading param DetailPump enum = "none" "10%" "20%" "30%" "40%" "50%" "60%" "70%" "80%" "90%" "100%" "z" "*2" "*3" "*4" "*5" "*6" "*7" "*8" "*9" "*10" "Self *" "Self /" caption = "Detail Pump" default = 0 endparam param DetailSelf caption = "Self Detail Pump *" default = (0, 0) visible = @DetailPump == 21 endparam param DetailSelfD caption = "Self Detail Pump /" default = (0, 0) visible = @DetailPump == 22 endparam bool param Chaos caption = "Chaotic" default = false endparam param ChaosFactor caption = "Factor of Chaos" default = (0,0) visible = @Chaos == true endparam switch: type = "Julia" seed = #pixel power = power bailout = bailout } Cat++ { init: complex z = pixel complex p = @parameter zc = fn3(z/1)*2.2 z = @base*(z - zc)/@power loop: IF (imag(z)>0.5) z = @myfn3(@base*real(@myfn4(z)) + fn4(@base*imag(z)-@changer))/@smalldetails ELSEIF (real(z)>0.5) z = @myfn3(@base*real(@myfn4(z))-@changer + fn4(@base*imag(z)))/@smalldetails ELSEIF (real(z)>0.1) z = @myfn3(@p1*fn1(@myfn2(@changer/@myfn4(z+@p1))))/@smalldetails ELSEIF (imag(z)<-0.1) z = @myfn3(@base*imag(@myfn4(z))+@changer + fn4(@base*real(@myfn4(z))))/@smalldetails ELSE z = @myfn3(fn2(((@myfn4(z)^@innerpower+p+@changer)/(3*@myfn4(z)+p-@changer))^@innerpower) + #pixel/.3)/@smalldetails ENDIF if @JFormula == 0 z = @Jfn4(@Jfn2(@Jfn1(z)^@Jpower) + @Jfn3(@Jseed)) elseif @JFormula == 1 z = @Jfn4(@Jfn2(@Jfn1(z)^@Jpower) - @Jfn3(@Jseed)) elseif @JFormula == 1 z = @Jfn4(@Jfn2(@Jfn1(z)^@Jpower) * @Jfn3(@Jseed)) elseif @JFormula == 1 z = @Jfn4(@Jfn2(@Jfn1(z)^@Jpower) / @Jfn3(@Jseed)) elseif @JFormula == 1 z = @Jfn4(@Jfn2(@Jfn1(z)^@Jpower) ^ @Jfn3(@Jseed)) endif if @DJulia == true if @DJFormula == 0 z = @DJfn4(@DJfn2(@DJfn1(z)^@DJpower) + @DJfn3(@DJseed)) elseif @DJFormula = 1 z = @DJfn4(@DJfn2(@DJfn1(z)^@DJpower) - @DJfn3(@DJseed)) elseif @DJFormula = 2 z = @DJfn4(@DJfn2(@DJfn1(z)^@DJpower) * @DJfn3(@DJseed)) elseif @DJFormula = 3 z = @DJfn4(@DJfn2(@DJfn1(z)^@DJpower) / @DJfn3(@DJseed)) elseif @DJFormula = 4 z = @DJfn4(@DJfn2(@DJfn1(z)^@DJpower) ^ @DJfn3(@DJseed)) endif endif if @bar == true IF real(z) * imag(@Bstart) + real(@Bstart) * imag(z) >= 0 z = @bBase * (@bfn1(z - @bChange) * @bfn3(@Bstart)) ELSE z = @bBase * (@bfn2(z + @bChange) * @bfn4(@Bstart)) ENDIF endif ;--- Chaotica if @Chaos == True if z+@ChaosFactor> pixel z=z+pixel else z=z*pixel endif endif ;------DetailPump--------------- if @DetailPump == 0 Elseif @DetailPump == 1 z = z * (9.5/10) Elseif @DetailPump == 2 z = z * (9/10) Elseif @DetailPump == 3 z = z * (8/10) Elseif @DetailPump == 4 z = z * (7/10) Elseif @DetailPump == 5 z = z * (6/10) Elseif @DetailPump == 6 z = z * (5/10) Elseif @DetailPump == 7 z = z * (4/10) Elseif @DetailPump == 8 z = z * (3/10) Elseif @DetailPump == 9 z = z * (2/10) Elseif @DetailPump == 10 z = z * (1/10) Elseif @DetailPump == 11 z = z * z Elseif @DetailPump == 12 z = z * 2 Elseif @DetailPump == 13 z = z * 3 Elseif @DetailPump == 14 z = z * 4 Elseif @DetailPump == 15 z = z * 5 Elseif @DetailPump == 16 z = z * 6 Elseif @DetailPump == 17 z = z * 7 Elseif @DetailPump == 18 z = z * 8 Elseif @DetailPump == 19 z = z * 9 Elseif @DetailPump == 20 z = z * 10 elseif @DetailPump == 21 z = z * @DetailSelf elseif @DetailPump == 22 z = z / @DetailSelfD Endif bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && @myfn1(real(z)) <= @bailout) || \ (@test == 2 && @myfn1(imag(z)) <= @bailout) || \ (@test == 3 && (@myfn1(real(z)) <= @bailout && @myfn1(imag(z)) < @bailout)) || \ (@test == 4 && (@myfn1(real(z)) <= @bailout || @myfn1(imag(z)) < @bailout)) || \ (@test == 5 && (@myfn1(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (@myfn1(real(z) + imag(z)) <= @bailout)) default: title = "Cat ++" center = (0.5, 0.1) magn = 0.6 maxiter = 500 param base caption = "Base" default = 1.65556 endparam param smalldetails caption = "Swing Shift" default = (1.0,0.0) endparam param changer caption = "Innereds" default = 0.92222 endparam Param innerpower caption = "Innerals" default = 3.32222 endparam param power caption = "Zoom/Rotate" default = (3.2381,-0.85714) endparam param p1 caption = "Shifting Details" default = (0.96429,-0.47619) endparam param parameter caption = "Flux Details" default = (2.00952,1.74762) endparam param bailout caption = "Bailout" default = 1e20 endparam param test caption = "Shape Modifier" default = 6 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam heading caption = "Addons" endheading bool param bar caption = "Add Bar" default = false endparam param bStart caption = "Bar Starting" default = (1.0,1.0) visible = @bar == True endparam param bChange caption = "Bar Changer" default = (1.0,1.0) visible = @bar == True endparam param bBase caption = "Bar Base" default = (1.0,1.0) visible = @bar == True endparam complex func Bfn1 caption = "Bar Function 1" default = ident() visible = @bar == True endfunc complex func Bfn2 caption = "Bar Function 2" default = ident() visible = @bar == True endfunc complex func Bfn3 caption = "Bar Function 3" default = ident() visible = @bar == True endfunc complex func Bfn4 caption = "Bar Function 4" default = ident() visible = @bar == True endfunc heading caption = "Julia Controls" endheading param Jpower caption = "Julia Power" default = (1.39286,-.53571) endparam param JSeed caption = "Julia Seed" default = (-.31524,-.44048) endparam param Jformula caption = "Julia's Math" enum = "+" "-" "*" "/" "^" default = 0 endparam complex func Jfn1 caption = "Julia Function 1" default = flip() endfunc complex func Jfn2 caption = "Julia Function 2" default = ident() endfunc complex func Jfn3 caption = "Julia Function 3" default = ident() endfunc complex func Jfn4 caption = "Julia Function 4" default = ident() endfunc bool param DJulia caption = "Double It" default = false endparam param DJpower caption = "Doubled Julia Power" default = (1.39286,-.53571) visible = @DJulia == True endparam param DJSeed caption = "Doubled Julia Seed" default = (-.31524,-.44048) visible = @DJulia == True endparam param DJformula caption = "Julia's Math" enum = "+" "-" "*" "/" "^" default = 0 visible = @DJulia == True endparam complex func DJfn1 caption = "Double Julia Function 1" default = flip() visible = @DJulia == True endfunc complex func DJfn2 caption = "Double Julia Function 2" default = ident() visible = @DJulia == True endfunc complex func DJfn3 caption = "Double Julia Function 3" default = ident() visible = @DJulia == True endfunc complex func DJfn4 caption = "Double Julia Function 4" default = ident() visible = @DJulia == True endfunc heading caption = "Function Controls" endheading func fn1 caption = "Function" default = acos () endfunc func fn2 caption = "Function 2" default = round () endfunc func fn3 caption = "Function 3" default = ident () endfunc func fn4 caption = "Function 4" default = flip () endfunc complex func myfn1 caption = "Function 5" default = sqr() endfunc complex func myfn2 caption = "Function 6" default = cos() endfunc complex func myfn3 caption = "Function 7" default = flip() endfunc complex func myfn4 caption = "Function 8" default = ident() endfunc heading caption = "Details" endheading param DetailPump enum = "none" "10%" "20%" "30%" "40%" "50%" "60%" "70%" "80%" "90%" "100%" "z" "*2" "*3" "*4" "*5" "*6" "*7" "*8" "*9" "*10" "Self *" "Self /" caption = "Detail Pump" default = 0 endparam param DetailSelf caption = "Self Detail Pump *" default = (0, 0) visible = @DetailPump == 21 endparam param DetailSelfD caption = "Self Detail Pump /" default = (0, 0) visible = @DetailPump == 22 endparam bool param Chaos caption = "Chaotic" default = false endparam param ChaosFactor caption = "Factor of Chaos" default = (0,0) visible = @Chaos == true endparam switch: type = "Julia" seed = #pixel power = power bailout = bailout } SimpleYetGood { init: complex z = pixel zc = @myfn9(@myfn6(z/2)*2) z = @myfn7(2*@myfn8(z - zc)/2) loop: z = z - (z*@DR) IF (imag(z)>0.5) z = @base*@myfn5(real(z/@p1)) + fn3(@base*imag(z/@p1)-@change) ELSEIF (real(z)>0.5) z = @base*@myfn5(real(z/@p1))-@change + fn4(@base*imag(z/@p1)) ELSEIF (real(z)<0.5) z=fn1(p1)*fn2(z+p1)-0.1 ELSEIF (imag(z)<-0.1) z = @base*@myfn5(imag(z/@p1))+@change + flip(@base*real(z/@p1)) ELSE z = @base*@myfn5(real(z/@p1)) + flip(@base*imag(z/@p1)) ENDIF bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && @myfn10(real(z)) <= @bailout) || \ (@test == 2 && @myfn10(imag(z)) <= @bailout) || \ (@test == 3 && (@myfn10(real(z)) <= @bailout && @myfn10(imag(z)) < @bailout)) || \ (@test == 4 && (@myfn10(real(z)) <= @bailout || @myfn10(imag(z)) < @bailout)) || \ (@test == 5 && (@myfn10(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (@myfn10(real(z) + imag(z)) <= @bailout)) default: title = "Squirrel Calm" center = (0.5, 0.1) magn = 1.0 maxiter = 500 param p1 caption = "Insides" default=(-0.2,0) endparam param base caption = "Base" default = (2.0,0) endparam param change caption = "shifts" default = (1.0,0.0) endparam param DR caption = "Detail Ranger" default = 0.0 endparam param bailout caption = "Bailout" default = 1e20 endparam param test caption = "Shape Modifier" default = 0 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam complex func myfn10 caption = "BailOut Function" default = sqr() endfunc func fn1 default=cotanh() endfunc func fn2 default=sqr() endfunc func fn3 default=flip() endfunc func fn4 default=flip() endfunc complex func myfn5 caption = "Function 5" default = ident() endfunc complex func myfn6 caption = "Function 6" default = tan() endfunc complex func myfn7 caption = "Function 7" default = asinh() endfunc complex func myfn8 caption = "Function 8" default = asinh() endfunc complex func myfn9 caption = "Function 9" default = round() endfunc complex func myfn10 caption = "BailOut Function" default = sqr() endfunc } MoutainsAmongUs { init: z = #pixel complex oz = z complex c = @distcenter IF (@centermove) c = #center ENDIF complex r = (0,1) ^ (@angle / 90.0) complex r2 = (0,1) ^ (@anglestep / 90.0) complex r3 = (0,1) ^ (@distangle / 90.0) float fiter = @noisestart BOOL noise = false complex z = pixel zc = fn3(sqr(z/2)*2) z = fn4(2*(z - zc)/2) loop: if @Julias == true if @jstart == true z = @jf2(@jf1(z)^@Jspower) - @jf3(@Jsseed) z = @jf4(z) endif endif IF (@noiseskip != 0); we are skipping some iterations fiter = fiter - 1; one less to go before we add noise WHILE (fiter < 0.0); iterations all used up IF (noise); we are currently adding noise noise = false; so stop fiter = fiter + @noiseskip; skip this many iterations ELSE; we aren't currently adding noise noise = true; so start fiter = fiter + @noiseiter; do this many iterations ENDIF ENDWHILE ENDIF IF (@coloronly); only using fBm on coloring z = oz; restore z from un-fBm'ed copy ENDIF if @Julias == true if @jblend == true IF (imag(z)>0.5) z = @jf2(@jf1(@base*fn1(real(fn2(z))))^@jbpower) + @jf3(flip(@base*imag(z)-@changer)) ELSEIF (real(z)>0.5) z = @jf2(@jf1(@base*fn1(real(fn2(z)))-@changer)^@jbpower) + @jf3(flip(@base*imag(z))) ELSEIF (real(z)<0.5) z=cosh(p1)*exp(fn2(z)+p1)-0.1 ELSEIF (imag(z)<-0.1) z = @jf2(@jf1(@base*fn1(imag(fn2(z))))^@jbpower) + @changer + @jf3(flip(@base*real(z))) ELSE z = @jf2(@jf1(@base*fn1(real(fn2(z))))^@jbpower) + @jf3(flip(@base*imag(z))) ENDIF if @jbform == 0 z = @jf4(z - @jbseed) elseif @jbform == 1 z = @jf4(z + @jbseed) elseif @jbform == 2 z = @jf4(z * @jbseed) elseif @jbform == 3 z = @jf4(z / @jbseed) elseif @jbform == 4 z = @jf4(z ^ @jbseed) endif endif IF (imag(z)>0.5) z = @base*fn1(real(fn2(z))) + flip(@base*imag(z)-@changer) ELSEIF (real(z)>0.5) z = @base*fn1(real(fn2(z)))-@changer + flip(@base*imag(z)) ELSEIF (real(z)<0.5) z=cosh(p1)*exp(fn2(z)+p1)-0.1 ELSEIF (imag(z)<-0.1) z = @base*fn1(imag(fn2(z)))+@changer + flip(@base*real(z)) ELSE z = @base*fn1(real(fn2(z))) + flip(@base*imag(z)) ENDIF if @jmid == true z = @jf2(@jf1(z)^@Jmpower) - @jf3(@Jmseed) z = @jf4(z) endif elseif @Julias == false IF (imag(z)>0.5) z = @base*fn1(real(fn2(z))) + flip(@base*imag(z)-@changer) ELSEIF (real(z)>0.5) z = @base*fn1(real(fn2(z)))-@changer + flip(@base*imag(z)) ELSEIF (real(z)<0.5) z=cosh(p1)*exp(fn2(z)+p1)-0.1 ELSEIF (imag(z)<-0.1) z = @base*fn1(imag(fn2(z)))+@changer + flip(@base*real(z)) ELSE z = @base*fn1(real(fn2(z))) + flip(@base*imag(z)) ENDIF endif IF (@coloronly); only using fBm on coloring oz = z ENDIF IF (@noiseskip == 0.0 || noise); adding noise this iteration complex p = z * @scale * r + @offset float sum = 0.0 float freq = 1.0 complex v = (0,0) int i = @octaves WHILE (i > 0) ; determine integer coordinate for corners of square ; surrounding p float bx0 = floor(real(p)) % 256 float by0 = floor(imag(p)) % 256 IF (bx0 < 0) bx0 = bx0 + 256 ENDIF IF (by0 < 0) by0 = by0 + 256 ENDIF float bx1 = (bx0 + 1) % 256 float by1 = (by0 + 1) % 256 float rx0 = real(p) - floor(real(p)) float ry0 = imag(p) - floor(imag(p)) float rx1 = rx0 - 1 float ry1 = ry0 - 1 ; create a "random" index for each corner ; (this is where Intel's version differs from Perlin's; ; I used Intel's version because it doesn't require a ; pre-computed random table, which is difficult to manage ; in UF.) float b00 = (bx0^@npower % 65536 + by0)^@npower % 65536 float b10 = (bx1^@npower % 65536 + by0)^@npower % 65536 float b01 = (bx0^@npower % 65536 + by1)^@npower % 65536 float b11 = (bx1^@npower % 65536 + by1)^@npower % 65536 ; produce a "random" vector for each corner float g_b00_0 = (b00)^@npower*0.25 % 512 - 256 float g_b10_0 = (b10)^@npower*0.25 % 512 - 256 float g_b01_0 = (b01)^@npower*0.25 % 512 - 256 float g_b11_0 = (b11)^@npower*0.25 % 512 - 256 float g_b00_1 = (b00+1)^@npower*0.25 % 512 - 256 float g_b10_1 = (b10+1)^@npower*0.25 % 512 - 256 float g_b01_1 = (b01+1)^@npower*0.25 % 512 - 256 float g_b11_1 = (b11+1)^@npower*0.25 % 512 - 256 ; normalize each vector float d = 0.0; d = 1 / sqrt(sqr(g_b00_0) + sqr(g_b00_1)) g_b00_0 = g_b00_0 * d g_b00_1 = g_b00_1 * d d = 1 / sqrt(sqr(g_b10_0) + sqr(g_b10_1)) g_b10_0 = g_b10_0 * d g_b10_1 = g_b10_1 * d d = 1 / sqrt(sqr(g_b01_0) + sqr(g_b01_1)) g_b01_0 = g_b01_0 * d g_b01_1 = g_b01_1 * d d = 1 / sqrt(sqr(g_b11_0) + sqr(g_b11_1)) g_b11_0 = g_b11_0 * d g_b11_1 = g_b11_1 * d ; produce colors for each corner float u1 = rx0 * g_b00_0 + ry0 * g_b00_1 float v1 = rx1 * g_b10_0 + ry0 * g_b10_1 float u2 = rx0 * g_b01_0 + ry1 * g_b01_1 float v2 = rx1 * g_b11_0 + ry1 * g_b11_1 ; interpolate between corners using ; bilinear filtering float sx = sqr(rx0) * (3 - rx0*2) float sy = sqr(ry0) * (3 - ry0*2) float a = u1 + sx*(v1-u1) float b = u2 + sx*(v2-u2) sum = sum + (a + sy*(b-a))*freq freq = freq * @step p = p * r2 / @step i = i - 1 ENDWHILE IF (@style == 0); radial distortion v = (z-c)/cabs(z-c) * r3; use vector based on angle to distortion center ELSEIF (@style == 1); linear distortion v = r3; just use rotation vector ENDIF z = z + v * sum*0.5*@distortion ENDIF z = z/@detailer IF (@coloronly == false); not just using fBm on coloring oz = z; value for bailout is fBm'ed z ENDIF if @Julias == true if @jend == true z = @jf2(@jf1(z)^@Jepower) - @jf3(@Jeseed) z = @jf4(z) endif endif bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && sqr(real(z)) <= @bailout) || \ (@test == 2 && sqr(imag(z)) <= @bailout) || \ (@test == 3 && (sqr(real(z)) <= @bailout && sqr(imag(z)) < @bailout)) || \ (@test == 4 && (sqr(real(z)) <= @bailout || sqr(imag(z)) < @bailout)) || \ (@test == 5 && (sqr(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (sqr(real(z) + imag(z)) <= @bailout)) default: title = "Moutains" center = (2.0457133441,-0.93736379106) magn = 4.3267738 angle = -114.8574 heading caption = "Addons" endheading bool param Julias caption = "Julias" default = false endparam bool param jstart caption = "Start" default = false visible = @Julias == True endparam param Jspower caption = "JPower" default = (2.0,0.0) visible = @jstart == True endparam param Jsseed caption = "JSeed" default = (-1.47,0.0) visible = @jstart == True endparam bool param jmid caption = "Before FBM" default = false visible = @Julias == True endparam param Jmpower caption = "JmPower" default = (2.0,0.0) visible = @jmid == True endparam param Jmseed caption = "JmSeed" default = (-1.47,0.0) visible = @jmid == True endparam bool param jend caption = "End" default = false visible = @Julias == True endparam param Jepower caption = "JePower" default = (2.0,0.0) visible = @jend == True endparam param Jeseed caption = "JeSeed" default = (-1.47,0.0) visible = @jend == True endparam bool param jblend caption = "Blend" default = false visible = @Julias == True endparam param Jbpower caption = "JbPower" default = (0.5,2) visible = @jblend == True endparam param jbform caption = "Form of Seed" default = 0 enum = "-" "+" "*" "/" "^" visible = @jblend == True endparam param Jbseed caption = "JbSeed" default = (1.3,-0.3) visible = @jblend == True endparam complex func jf1 caption = "Jf1" default = ident() visible = @Julias == True endfunc complex func jf2 caption = "Jf2" default = ident() visible = @Julias == True endfunc complex func jf3 caption = "Jf3" default = ident() visible = @Julias == True endfunc complex func jf4 caption = "Jf4" default = ident() visible = @Julias == True endfunc heading caption = "Formula" Endheading Param base caption = "Base" default = (2.0,0.0) endparam param changer caption = "Changer" default = (1.0,0.0) endparam param p1 caption = "Paramater 1" default=(-.15238,.57143) endparam param detailer caption = "Detailer" default = (1.0,0.0) endparam param bailout caption = "Bailout" default = 1e20 endparam param test caption = "Shape Modifier" default = 0 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam func fn1 default=abs() endfunc func fn2 default=conj() endfunc func fn3 default=ident() endfunc func fn4 default=ident() endfunc Heading caption = "Distortion" endheading param distortion caption = "Distortion Strength" default = .5 hint = "This is the amount the noise distorts the image." endparam param style caption = "Distortion Style" default = 0 enum = "radial" "linear" hint = "This selects whether the distortion will be focused \ around a single point, or directed along a line." endparam param distangle caption = "Distortion Angle" default = 0.0 hint = "This is the angle to rotate the distortion." endparam param distcenter caption = "Distortion Center" default = (0,0) hint = "Sets the center of distortion. If Use Screen \ Center is set, this item is ignored." endparam param centermove caption = "Use Screen Center" default = FALSE hint = "If set, distortion will be around the center of \ the window, regardless of the Distortion Center \ setting." endparam param offset caption = "Noise Offset" default = (0,0) hint = "This is the offset of the pattern. You can use this to shift \ the pattern around on the complex plane." endparam param scale caption = "Noise Scale" default = 1.0 hint = "This is the overall scale of the noise." endparam param angle caption = "Noise Rotation" default = 0.0 hint = "This is the angle, in degrees, of the noise." endparam param step caption = "Noise Scale Step" default = 0.5 hint = "This is the step in scale between noise iterations." endparam param anglestep caption = "Noise Rotation Step" default = 37.0 hint = "This is the angle, in degrees, to rotate between noise \ iterations." endparam param octaves caption = "Noise Octaves" default = 7 min = 1 hint = "This is the number of iterations of the noise formula." endparam param npower caption = "Noise Exponent" default = 2.0 hint = "This is the exponent used to scramble numbers." endparam param noisestart caption = "Start Iteration" default = 0.0 hint = "This is the iteration at which to start adding noise." endparam param noiseiter caption = "Noise Iterations" default = 1e20 hint = "This is the number of iterations to add noise to." endparam param noiseskip caption = "Skip Iterations" default = 0.0 hint = "This is the number of iterations to skip adding noise \ before starting again." endparam param coloronly caption = "Coloring Only" default = false hint = "If set, noise will only apply to pixel values passed \ to the coloring algorithm; it will not be included in \ the fractal calculation between iterations." endparam switch: type = "dmj-fBmMandel" power = @power bailout = @bailout distortion = @distortion style = @style distangle = @distangle distcenter = @distcenter centermove = @centermove offset = @offset scale = @scale angle = @angle step = @step anglestep = @anglestep octaves = @octaves npower = @npower noisestart = @noisestart noiseiter = @noiseiter noiseskip = @noiseskip coloronly = @coloronly } loopings{ init: bool done = false b = #pixel loop: a = fn1(@radikand /fn3(b)) if @basedc == 0 c = (a/b) elseif @basedc == 1 c = (a*b) elseif @basedc == 2 c = (a-b) elseif @basedc == 3 c = (a+b) elseif @basedc == 4 c = (a^b) endif if @basedk == 0 k = (b/a) elseif @basedk == 1 k = (b*a) elseif @basedk == 2 k = (b-a) elseif @basedk == 3 k = (b+a) elseif @basedk == 4 k = (b^a) endif #z = (c) / @base If fn2(k) < @epsilon done = true else if @based == 0 b = @myfn5(fn4(c) / @quotient); Parameter added to avoid all points to be outside elseif @based == 1 b = @myfn5(fn4(c) * @quotient) elseif @based == 2 b = @myfn5(fn4(c) - @quotient) elseif @based == 3 b = @myfn5(fn4(c) + @quotient) elseif @based == 4 b = @myfn5(fn4(c) ^ @quotient) endif if @based2 == 0 b = b elseif @based2 == 1 b = b/@base elseif @based2 == 2 b = b*@base elseif @based2 == 3 b = b-@base elseif @based2 == 4 b = b+@base elseif @based2 == 5 b = b^@base endif endif bailout: done == false default: title = "Drunk Loops" heading caption = "Formula Controls" endheading param basedc caption = "Edit A+B" default = 3 enum = "/" "*" "-" "+" "^" endparam param basedk caption = "Edit If b-a" default = 2 enum = "/" "*" "-" "+" "^" endparam param based caption = "Edit Quotient" default = 0 enum = "/" "*" "-" "+" "^" endparam param based2 caption = "Edit Based" default = 1 enum = "none" "/" "*" "-" "+" "^" endparam param base caption = "Base" default = (2.0,0.0) endparam param @epsilon caption = "Fating" default=(.442423,.507576) endparam param @quotient caption = "Spin" default=(1.624242,1.466667) endparam param @radikand caption = "Fat Spin" default=(.07879,3.97576) endparam heading caption = "Functions" endheading func fn1 caption = "F1" default= ident() endfunc func fn2 caption = "F2" default= abs() endfunc func fn3 caption = "F3" default= ident() endfunc func fn4 caption = "F4" default= ident () endfunc complex func @myfn5 caption = "F5" default = ident() endfunc } kpksquare { init: complex z = pixel zc = fn4(z/@sizesq)*@sizesq if @Startflow == true if @fform == 0 z = (@base*(z - zc)/@power)^@fpower + @jseed elseif @fform ==1 z = (@base*(z - zc)/@power)^@fpower - @jseed elseif @fform ==2 z = (@base*(z - zc)/@power)^@fpower * @jseed elseif @fform ==3 z = (@base*(z - zc)/@power)^@fpower / @jseed elseif @fform ==4 z = ((@base*(z - zc)/@power)^@fpower) ^ @jseed endif else z = @base*(z - zc)/@power endif loop: IF (imag(z)>0.5) if @form1 == 0 z = fn3(@base*real(z))^@jpower + @f1(2*imag(z)-@change) elseif @form1 == 1 z = fn3(@base*real(z))^@jpower - @f1(2*imag(z)-@change) elseif @form1 == 2 z = fn3(@base*real(z))^@jpower * @f1(2*imag(z)-@change) elseif @form1 == 3 z = fn3(@base*real(z))^@jpower / @f1(2*imag(z)-@change) elseif @form1 == 4 z = (fn3(@base*real(z))^@jpower) ^ @f1(2*imag(z)-@change) endif ELSEIF (real(z)>0.5) if @form2 == 0 z = fn3(@base*real(z)-@change)^@jpower + @f2(2*imag(z)) elseif @form2 == 1 z = fn3(@base*real(z)-@change)^@jpower - @f2(2*imag(z)) elseif @form2 == 2 z = fn3(@base*real(z)-@change)^@jpower * @f2(2*imag(z)) elseif @form2 == 3 z = fn3(@base*real(z)-@change)^@jpower / @f2(2*imag(z)) elseif @form2 == 4 z = (fn3(@base*real(z)-@change)^@jpower) ^ @f2(2*imag(z)) endif ELSEIF (real(z)<0.1) if @form3 == 0 z = fn3(@base*fn1(z)-@change)^@jpower + @f3(2*imag(z)) elseif @form3 == 1 z = fn3(@base*fn1(z)-@change)^@jpower - @f3(2*imag(z)) elseif @form3 == 2 z = fn3(@base*fn1(z)-@change)^@jpower * @f3(2*imag(z)) elseif @form3 == 3 z = fn3(@base*fn1(z)-@change)^@jpower / @f3(2*imag(z)) elseif @form3 == 4 z = (fn3(@base*fn1(z)-@change)^@jpower) ^ @f3(2*imag(z)) endif ELSE if @form4 == 0 z = fn3(@base*fn2(z))^@jpower + @f4(2*imag(z)) elseif @form4 == 1 z = fn3(@base*fn2(z))^@jpower - @f4(2*imag(z)) elseif @form4 == 2 z = fn3(@base*fn2(z))^@jpower * @f4(2*imag(z)) elseif @form4 == 3 z = fn3(@base*fn2(z))^@jpower / @f4(2*imag(z)) elseif @form4 == 4 z = (fn3(@base*fn2(z))^@jpower) ^ @f4(2*imag(z)) endif if @AddFun == 0 z = @AF1(@AF(z)) elseif @AddFun == 1 ;+ z = @AF1(z)+@AF(z) elseif @AddFun == 2 ;- z = @AF1(z)-@AF(z) elseif @AddFun == 3 ;* z = @AF1(z)*@AF(z) elseif @AddFun == 4 ;/ z = @AF1(z)/@AF(z) elseif @AddFun == 5 ;^ z = @AF1(z)^@AF(z) endif ENDIF if @endflow == true if @efform == 0 z = (z)^@efpower + @ejseed elseif @efform ==1 z = (z)^@efpower - @ejseed elseif @efform ==2 z = (z)^@efpower * @ejseed elseif @efform ==3 z = (z)^@efpower / @ejseed elseif @efform ==4 z = ((z)^@efpower) ^ @ejseed endif endif z = z * (@detailer) bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && sqr(real(z)) <= @bailout) || \ (@test == 2 && sqr(imag(z)) <= @bailout) || \ (@test == 3 && (sqr(real(z)) <= @bailout && sqr(imag(z)) < @bailout)) || \ (@test == 4 && (sqr(real(z)) <= @bailout || sqr(imag(z)) < @bailout)) || \ (@test == 5 && (sqr(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (sqr(real(z) + imag(z)) <= @bailout)) default: title = "Square Funnies" center = (0.4, 0.4) magn = 1.5 maxiter = 500 heading caption="Form Controls" endheading param form1 caption = "form 1" default = 3 enum = "+" "-" "*" "/" "^" endparam complex func f1 caption = "Control Function 1" default = asin() endfunc param form2 caption = "form 2" default = 1 enum = "+" "-" "*" "/" "^" endparam complex func f2 caption = "Control Function 2" default = tan() endfunc param form3 caption = "form 4" default = 2 enum = "+" "-" "*" "/" "^" endparam complex func f3 caption = "Control Function 3" default = acosh() endfunc param form4 caption = "form 4" default = 0 enum = "+" "-" "*" "/" "^" endparam complex func f4 caption = "Control Function 4" default = zero() endfunc param AddFun caption = "Add Function" default = 0 enum = "none" "+" "-" "*" "/" "^" endparam complex func AF1 caption = "Added Function Shunt" default = ident() endfunc complex func AF caption = "Added Function Final" default = ident() endfunc heading Caption="Start Control" endheading bool param Startflow caption = "Start Flow" default = false endparam func fn4 caption = "Start Formula" default = round() visible = @Startflow == True endfunc param fform caption = "Start Flow Formula" default = 1 enum = "+" "-" "*" "/" "^" visible = @Startflow == True endparam param jseed caption = "Start Flow" default = (0,0) visible = @Startflow == True endparam param fpower caption = "Start Flow Power" default = (1,0) visible = @Startflow == True endparam heading Caption="Formula Controls" endheading param base caption = "Base" default = (2,0) endparam param jpower caption = "Powering" default = (1,0) endparam param change caption = "Change" default = (1,0) endparam param power caption = "Power" default = (2,0) endparam param detailer caption = "Detailer" default = (1.0,0.0) endparam param sizesq caption = "Magnification" default = 1 endparam param bailout caption = "Bailout" default = 1e20 endparam heading Caption="End Control" endheading bool param endflow caption = "Start Flow" default = false endparam param efform caption = "end Flow Formula" default = 1 enum = "+" "-" "*" "/" "^" visible = @endflow == True endparam param ejseed caption = "End Flow" default = (0,0) visible = @endflow == True endparam param efpower caption = "end Flow Power" default = (1,0) visible = @endflow == True endparam heading caption = "Functions" endheading param test caption = "Shape Modifier" default = 0 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam func fn1 caption = "Function 1" default = sin() endfunc func fn2 caption = "Function 2" default = abs() endfunc func fn3 caption = "Function 3" default = ident() endfunc } MAU2 { init: complex z = pixel complex p = @parameter zc = fn3(z/@sizesq)*@sizesq z = @twoset*(z - zc)/@power loop: IF (imag(z)>0.5) ;z = fn4(@twoset*real(z) + flip(@twoset*imag(z)-@oneset)) IF @reals == 0 a1 = @ifn2(@twoset*real(z)) b1 = @ifn1(@twoset*imag(z)-@oneset) elseif @reals == 1; real flip a1 = @ifn2(@twoset*imag(z)) b1 = @ifn1(@twoset*real(z)-@oneset) elseif @reals == 2 ;all real a1 = @ifn2(@twoset*real(z)) b1 = @ifn1(@twoset*real(z)-@oneset) elseif @reals == 3 ;all imag a1 = @ifn2(@twoset*imag(z)) b1 = @ifn1(@twoset*imag(z)-@oneset) endif z = fn4(a1+b1) ;z = fn4(@oneset*real(z) - flip(@oneset/imag(z)-@twoset)) IF @reals == 0 aa = @ifn2(@oneset*real(z)) bb = @ifn1(@oneset/imag(z)-@twoset) z = fn4( aa - bb) elseif @reals == 1; real flip aa = @ifn2(@oneset*imag(z)) bb = @ifn1(@oneset/real(z)-@twoset) cc = @efn2(real(z)/@threeset - imag(z)) z = fn4( aa - bb + cc) elseif @reals == 2 ;all real aa = @ifn2(@oneset*real(z)) bb = @ifn1(@oneset/real(z)-@twoset) z = fn4( aa - bb) elseif @reals == 3 ;all imag aa = @ifn2(@oneset*imag(z)) bb = @ifn1(@oneset/imag(z)-@twoset) z = fn4( aa - bb) endif ELSEIF (real(z)>0.5) ;z = fn4(@twoset*real(z)-@oneset + flip(@twoset*imag(z))) a1 = @ifn2(@twoset*real(z)-@oneset) b1 = @ifn1(@twoset*imag(z)) z = fn4(a1+b1) ELSEIF (real(z)>0.1) z = fn4(p1*fn1(sin(@oneset/(z+p1)))) ELSEIF (real(z)<0.1) z = z^@power - @parameter ELSEIF (imag(z)<-0.1) ;z = fn4(@twoset*imag(z)+@oneset + flip(@twoset*real(z))) a1 = @ifn2(@twoset*imag(z)+@oneset) b1 = @ifn1(@twoset*real(z)) z = fn4(a1+b1) ELSE z = fn4(fn2(((z^@twoset+p+@oneset)/(3*z+p-@oneset))^@twoset) + #pixel/0.3) ENDIF z=@efn1(#z/@threeset) bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && sqr(real(z)) <= @bailout) || \ (@test == 2 && sqr(imag(z)) <= @bailout) || \ (@test == 3 && (sqr(real(z)) <= @bailout && sqr(imag(z)) < @bailout)) || \ (@test == 4 && (sqr(real(z)) <= @bailout || sqr(imag(z)) < @bailout)) || \ (@test == 5 && (sqr(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (sqr(real(z) + imag(z)) <= @bailout)) default: title = "Splattered Thoughts" center = (0.5, 0.1) magn = 0.6 maxiter = 500 heading caption = "Detail/Growth" endheading param p1 caption = "Internal Details 1" default=(.14157,.25038) endparam param parameter caption = "Internal Details 2" default = (-.35018,-1.97125) endparam param power caption = "Power" default = (.665,1.28732) endparam param sizesq caption = "growth" default = (0.7,0.0) endparam heading caption = "sets" endheading param oneset caption = "One Set" default = (1.77478,0.01192) endparam param twoset caption = "Two Set" default = (1.76161,0.19071) endparam param threeset caption = "Three Set" default = (1,0) endparam heading caption = "Bailout" endheading param bailout caption = "Bailout" default = 1e20 endparam param test caption = "Shape Modifier" default = 0 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam heading caption = "Functions" endheading func fn1 caption = "Function 1" default = acos() endfunc func fn2 caption = "Function 2" default = exp() endfunc func fn3 caption = "Function 3" default = tan() endfunc func fn4 caption = "Function 4" default = conj () endfunc func ifn1 caption = "Internal Function 1" default = flip () endfunc func ifn2 caption = "Internal Function 2" default = ident () endfunc func efn1 caption = "End Function" default = ident () endfunc func efn2 caption = "End Function Reals" default = ident () endfunc param reals caption = "Real or Imag" default = 0 enum = "No Change" "Flip Reality" "All Real" "All Imag" endparam } JuliaGrany{ ; ; Generic Julia set. ; init: z = 0 p = #pixel / @scale float x = real(p) float y = imag(p) float xx = 0 int iter = 0 ;z = #pixel ;barkly float kk = real(#pixel) float ii = imag(#pixel) float zz = real(@zjk) float ww = imag(@zjk) float cx = real(@c1i) float cy = imag(@c1i) float cz = real(@cjk) float cw = imag(@cjk) float zr = 0.0 float zi = 0.0 float zj = 0.0 float zk = 0.0 float cr = 0.0 float ci = 0.0 float cj = 0.0 float ck = 0.0 float rx = 0.0 float ry = 0.0 float rz = 0.0 ; (yz plane rotation) ry = ii*cos(#pi*@rotx/180) - zz*sin(#pi*@rotx/180) rz = ii*sin(#pi*@rotx/180) + zz*cos(#pi*@rotx/180) ii = ry zz = rz ry = cy*cos(#pi*@rotx/180) - cz*sin(#pi*@rotx/180) rz = cy*sin(#pi*@rotx/180) + cz*cos(#pi*@rotx/180) cy = ry cz = rz ; (xz plane rotation) rx = zz*sin(#pi*@roty/180) + kk*cos(#pi*@roty/180) rz = zz*cos(#pi*@roty/180) - kk*sin(#pi*@roty/180) kk = rx zz = rz rx = cz*sin(#pi*@roty/180) + cx*cos(#pi*@roty/180) rz = cz*cos(#pi*@roty/180) - cx*sin(#pi*@roty/180) cx = rx cz = rz ; (xy plane rotation) rx = kk*cos(#pi*@rotz/180) - ii*sin(#pi*@rotz/180) ry = kk*sin(#pi*@rotz/180) + ii*cos(#pi*@rotz/180) kk = rx ii = ry rx = cx*cos(#pi*@rotz/180) - cy*sin(#pi*@rotz/180) ry = cx*sin(#pi*@rotz/180) + cy*cos(#pi*@rotz/180) cx = rx cy = ry if @fourthdim == 3 zr = kk zi = ii zj = zz zk = ww cr = cx ci = cy cj = cz ck = cw elseif @fourthdim == 2 zr = kk zi = ii zj = ww zk = zz cr = cx ci = cy cj = cw ck = cz elseif @fourthdim == 1 zr = zz zi = ww zj = kk zk = ii cr = cz ci = cw cj = cx ck = cy else zr = ww zi = zz zj = kk zk = ii cr = cw ci = cz cj = cx ck = cy endif complex fa = zr - zk + flip(zi + zj) complex fb = zr + zk + flip(zi - zj) complex ca = cr - ck + flip(ci + cj) complex cb = cr + ck + flip(ci - cj) loop: jp = fn4(z^@power + @seed) jn = fn4(z^@power - @seed) iter = iter + 1 xx = x IF (imag(z)>0.5) x = x - @h * real(fn1((y/jn) + fn2(@a * (y + fn3(@b / y))))) y = y + @h * real(fn1((xx/jp) + fn2(@a * (xx + fn3(@b / xx))))) ELSEIF (imag(z)<-0.1) x = x - @h * real(fn1((y/jp) + fn2(@a * (y + fn3(@b * y))))) y = y + @h * real(fn1((xx/jn) + fn2(@a * (xx + fn3(@b * xx))))) ELSEIF (imag(z)>-0.1) x = x - @h * real(fn1((y/jn) + fn2(@a * (y + fn3(@b * y))))) y = y + @h * real(fn1((xx/jp) + fn2(@a * (xx + fn3(@b * xx))))) ELSEIF (real(z)>0.5) x = x - @h * real(fn1((y/jp) + fn2(@a * (y + fn3(@b * y))))) y = y + @h * real(fn1((xx/jn) + fn2(@a * (xx + fn3(@b * xx))))) ELSEIF (real(z)>0.1) x = x - @h * real(fn1((y/jn) + fn2(@a * (y + fn3(@b * y))))) y = y + @h * real(fn1((xx/jp) + fn2(@a * (xx + fn3(@b * xx))))) ELSE x = x - @h * real(fn1((y/jn) + fn2(@a * (y + fn3(@b * y))))) y = y + @h * real(fn1((xx/jp) + fn2(@a * (xx + fn3(@b * xx))))) ENDIF if @pk == 0 ;default k = @fn6(x + @fn5(y)) elseif @pk == 1 ;+ k = @fn6(x + @fn5(y)) elseif @pk == 2 ;- k = @fn6(x - @fn5(y)) elseif @pk == 3 ;* k = @fn6(x * @fn5(y)) elseif @pk == 4 ;/ k = @fn6(x / @fn5(y)) elseif @pk == 5 ;^ k = @fn6(x ^@fn5(y)) endif if (@var == 0) if real(fa) >= 0 fa = (fa - 1) * ca else fa = (fa + 1) * ca endif if real(b) >= 0 fb = (fb - 1) * cb else fb = (fb + 1) * cb endif elseif (@var == 1) if real(fa) * imag(ca) + real(ca) * imag(fa) >= 0 fa = (fa - 1) * ca else fa = (fa + 1) * ca endif if real(fb) * imag(cb) + real(cb) * imag(b) >= 0 fb = (fb - 1) * cb else fb = (fb + 1) * cb endif elseif (@var == 2) if real(fa) >= 0 fa = sqr(fa) - 1 else fa = sqr(fa) - 1 + ca * real(fa) endif if real(fb) >= 0 fb = sqr(fb) - 1 else fb = sqr(fb) - 1 + cb * real(fb) endif endif z = (fa + fb) / 2 IF (imag(z)<(@bs-(@bs*.1))) z = k - jp z = z/jn elseif (imag(z)<(@bs-(@bs*.2))) z = k - jn z = z/jp elseif (imag(z)<(@bs-(@bs*.3))) z = k + jp z = z/jn elseif (imag(z)<(@bs-(@bs*.4))) z = k + jn z = z/jp elseif (imag(z)<(@bs-(@bs*.5))) z = k * jp z = z/jn elseif (imag(z)<(@bs-(@bs*.6))) z = k * jn z = z/jp elseif (imag(z)<(@bs-(@bs*.7))) z = k - jn z = z/jp elseif (imag(z)<(@bs-(@bs*.8))) z = k - jp z = z/jn elseif (imag(z)<(@bs-(@bs*.9))) z = k + jn z = z/jp elseif (imag(z)<0.0) z = k + jp z = z/jn elseif (imag(z)<(@bs-(@bs*(-.9)))) z = k * jp z = z/jn elseif (imag(z)<(@bs-(@bs*(-.8)))) z = k * jn z = z/jp elseif (imag(z)<(@bs-(@bs*(-.7)))) z = k - jp z = z/jn elseif (imag(z)<(@bs-(@bs*(-.6)))) z = k - jn z = z/jp elseif (imag(z)<(@bs-(@bs*(-.5)))) z = k + jp z = z/jn elseif (imag(z)<(@bs-(@bs*(-.4)))) z = k + jn z = z/jp elseif (imag(z)<(@bs-(@bs*(-.3)))) z = k * jp z = z/jn elseif (imag(z)<(@bs-(@bs*(-.2)))) z = k * jn z = z/jp elseif (imag(z)<(@bs-(@bs*(-.1)))) z = k - jp z = z/jn elseif (imag(z)>(@bs-(@bs*(-1)))) z = k + jp z = z/jn else z = k - jn z = z/jp endif bailout: |z| <= @bailout default: title = "Textured Fields" param seed caption = "Julia seed" default = (-1.25, 0) endparam param power caption = "Power" default = (2.0,0.0) endparam param bs caption = "Bands" default = 1.0 endparam param pk caption = "Power Of K" default = 0 enum = "None" "+" "-" "*" "/" "^" endparam param a caption = "Alpha" default = 2.7 endparam param b caption = "Beta" default = 2.7 endparam param h caption = "Step size" default = 0.1 endparam param scale caption = "Scale" default = 1.0 endparam param var caption = "Variation" enum = "First""Second""Third" default = 0 endparam param fourthdim caption = "Fourth dimension" enum = "z1" "zi" "zj" "zk" default = 3 endparam param c1i caption = "(c1, ci)" default = (0.0, 1.44) endparam param cjk caption = "(cj, ck)" default = (0.0, 0.0) endparam param zjk caption = "(zj, zk)" default = (0.0, 0.0) endparam param rotx caption="x-rotation" hint="Rotates yz-plane." default=0.0 min=-360.0 max=360.0 endparam param roty caption="y-rotation" hint="Rotates zx-plane." default=0.0 min=-360.0 max=360.0 endparam param rotz caption="z-rotation" hint="Rotates xy-plane." default=0.0 min=-360.0 max=360.0 endparam func fn1 caption = "First Function" default = sin() endfunc func fn2 caption = "Second Function" default = sin() endfunc func fn3 caption = "Third Function" default = sin() endfunc func fn4 caption = "Fouth Function" default = sin() endfunc func fn5 caption = "Fifth Function" default = flip() endfunc func fn6 caption = "Sixth Function" default = ident() endfunc param bailout caption = "Bailout value" default = 4.0 min = 1.0 $IFDEF VER40 exponential = true $ENDIF endparam switch: type = "Mandelbrot" power = power bailout = bailout } JuliaChaos{ ; ; Generic Julia set. ; init: z = #pixel if @fbm == true complex oz = z complex c = @distcenter IF (@centermove) c = #center ENDIF complex r = (0,1) ^ (@angle / 90.0) complex r2 = (0,1) ^ (@anglestep / 90.0) complex r3 = (0,1) ^ (@distangle / 90.0) float fiter = @noisestart BOOL noise = false endif loop: if @fbm == true IF (@noiseskip != 0); we are skipping some iterations fiter = fiter - 1; one less to go before we add noise WHILE (fiter < 0.0); iterations all used up IF (noise); we are currently adding noise noise = false; so stop fiter = fiter + @noiseskip; skip this many iterations ELSE; we aren't currently adding noise noise = true; so start fiter = fiter + @noiseiter; do this many iterations ENDIF ENDWHILE ENDIF IF (@coloronly); only using fBm on coloring z = oz; restore z from un-fBm'ed copy ENDIF endif IF (imag(z)>@bs) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.1))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.2))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.3))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.4))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.5))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.6))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.7))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.8))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*.9))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>.0) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.9)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.8)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.7)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.6)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.5)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.4)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.3)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.2)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (imag(z)>(@bs-(@bs*(-.1)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (imag(z)<(@bs-(@bs*(-.1)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.1))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.2))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.3))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.4))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.5))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.6))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.7))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.8))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*.9))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>.0) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.9)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.8)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.7)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.6)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.5)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.4)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.3)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.2)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSEIF (real(z)>(@bs-(@bs*(-.1)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) endif ELSEIF (real(z)<(@bs-(@bs*(-.1)))) if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ELSE if @set_scattered == 0 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) elseif @set_scattered == 1 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 2 z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) elseif @set_scattered == 3 z = fn1(fn2(z^@power)/@indetailer - fn3(@seed)) z = fn1(fn2(z^@power)/@indetailer + fn3(@seed)) endif ENDIF z = fn4(z/@detailer) ;------------fbm---------------- if @fbm == true IF (@coloronly); only using fBm on coloring oz = z ENDIF IF (@noiseskip == 0.0 || noise); adding noise this iteration complex p = z * @scale * r + @offset float sum = 0.0 float freq = 1.0 complex v = (0,0) int i = @octaves WHILE (i > 0) ; determine integer coordinate for corners of square ; surrounding p float bx0 = floor(real(p)) % 256 float by0 = floor(imag(p)) % 256 IF (bx0 < 0) bx0 = bx0 + 256 ENDIF IF (by0 < 0) by0 = by0 + 256 ENDIF float bx1 = (bx0 + 1) % 256 float by1 = (by0 + 1) % 256 float rx0 = real(p) - floor(real(p)) float ry0 = imag(p) - floor(imag(p)) float rx1 = rx0 - 1 float ry1 = ry0 - 1 ; create a "random" index for each corner ; (this is where Intel's version differs from Perlin's; ; I used Intel's version because it doesn't require a ; pre-computed random table, which is difficult to manage ; in UF.) float b00 = (bx0^@npower % 65536 + by0)^@npower % 65536 float b10 = (bx1^@npower % 65536 + by0)^@npower % 65536 float b01 = (bx0^@npower % 65536 + by1)^@npower % 65536 float b11 = (bx1^@npower % 65536 + by1)^@npower % 65536 ; produce a "random" vector for each corner float g_b00_0 = (b00)^@npower*0.25 % 512 - 256 float g_b10_0 = (b10)^@npower*0.25 % 512 - 256 float g_b01_0 = (b01)^@npower*0.25 % 512 - 256 float g_b11_0 = (b11)^@npower*0.25 % 512 - 256 float g_b00_1 = (b00+1)^@npower*0.25 % 512 - 256 float g_b10_1 = (b10+1)^@npower*0.25 % 512 - 256 float g_b01_1 = (b01+1)^@npower*0.25 % 512 - 256 float g_b11_1 = (b11+1)^@npower*0.25 % 512 - 256 ; normalize each vector float d = 0.0; d = 1 / sqrt(sqr(g_b00_0) + sqr(g_b00_1)) g_b00_0 = g_b00_0 * d g_b00_1 = g_b00_1 * d d = 1 / sqrt(sqr(g_b10_0) + sqr(g_b10_1)) g_b10_0 = g_b10_0 * d g_b10_1 = g_b10_1 * d d = 1 / sqrt(sqr(g_b01_0) + sqr(g_b01_1)) g_b01_0 = g_b01_0 * d g_b01_1 = g_b01_1 * d d = 1 / sqrt(sqr(g_b11_0) + sqr(g_b11_1)) g_b11_0 = g_b11_0 * d g_b11_1 = g_b11_1 * d ; produce colors for each corner float u1 = rx0 * g_b00_0 + ry0 * g_b00_1 float v1 = rx1 * g_b10_0 + ry0 * g_b10_1 float u2 = rx0 * g_b01_0 + ry1 * g_b01_1 float v2 = rx1 * g_b11_0 + ry1 * g_b11_1 ; interpolate between corners using ; bilinear filtering float sx = sqr(rx0) * (3 - rx0*2) float sy = sqr(ry0) * (3 - ry0*2) float a = u1 + sx*(v1-u1) float b = u2 + sx*(v2-u2) sum = sum + (a + sy*(b-a))*freq freq = freq * @step p = p * r2 / @step i = i - 1 ENDWHILE IF (@style == 0); radial distortion v = (z-c)/cabs(z-c) * r3; use vector based on angle to distortion center ELSEIF (@style == 1); linear distortion v = r3; just use rotation vector ENDIF z = z + v * sum*0.5*@distortion ENDIF IF (@coloronly == false); not just using fBm on coloring oz = z; value for bailout is fBm'ed z ENDIF endif bailout: |z| <= @bailout default: title = "Scattered Julia" heading caption = "Julia Controls" endheading param seed caption = "Julia seed" default = (-0.4985,0.28629) endparam param power caption = "Power" default = (1.2485,0.334) endparam param detailer caption = "Detailer" default = (0.71371,0.334) endparam param indetailer caption = "Internal Detailer" default = 1.0 endparam param bs caption = "Band Size" default = 1.0 endparam heading caption = "FBM Controls" endheading bool param fbm caption = "FBM" default = false endparam ;-------------FBM-------------------; param distortion caption = "Distortion Strength" default = 1.0 hint = "This is the amount the noise distorts the image." visible = @fbm == True endparam param style caption = "Distortion Style" default = 0 enum = "radial" "linear" hint = "This selects whether the distortion will be focused \ around a single point, or directed along a line." visible = @fbm == True endparam param distangle caption = "Distortion Angle" default = 0.0 hint = "This is the angle to rotate the distortion." visible = @fbm == True endparam param distcenter caption = "Distortion Center" default = (0,0) hint = "Sets the center of distortion. If Use Screen \ Center is set, this item is ignored." visible = @fbm == True endparam param centermove caption = "Use Screen Center" default = FALSE hint = "If set, distortion will be around the center of \ the window, regardless of the Distortion Center \ setting." visible = @fbm == True endparam param offset caption = "Noise Offset" default = (0,0) hint = "This is the offset of the pattern. You can use this to shift \ the pattern around on the complex plane." visible = @fbm == True endparam param scale caption = "Noise Scale" default = .2 hint = "This is the overall scale of the noise." visible = @fbm == True endparam param angle caption = "Noise Rotation" default = 0.0 hint = "This is the angle, in degrees, of the noise." visible = @fbm == True endparam param step caption = "Noise Scale Step" default = 0.5 hint = "This is the step in scale between noise iterations." visible = @fbm == True endparam param anglestep caption = "Noise Rotation Step" default = 37.0 hint = "This is the angle, in degrees, to rotate between noise \ iterations." visible = @fbm == True endparam param octaves caption = "Noise Octaves" default = 7 min = 1 hint = "This is the number of iterations of the noise formula." visible = @fbm == True endparam param npower caption = "Noise Exponent" default = 2.0 hint = "This is the exponent used to scramble numbers." visible = @fbm == True endparam param noisestart caption = "Start Iteration" default = 0.0 hint = "This is the iteration at which to start adding noise." visible = @fbm == True endparam param noiseiter caption = "Noise Iterations" default = 10000.0 hint = "This is the number of iterations to add noise to." visible = @fbm == True endparam param noiseskip caption = "Skip Iterations" default = 0.0 hint = "This is the number of iterations to skip adding noise \ before starting again." visible = @fbm == True endparam param coloronly caption = "Coloring Only" default = false hint = "If set, noise will only apply to pixel values passed \ to the coloring algorithm; it will not be included in \ the fractal calculation between iterations." visible = @fbm == True endparam heading caption = "Function Controls" endheading param set_scattered caption = "Scattered" default = 0 enum = "None" "1" "2" "3" endparam func fn1 caption = "First Function" default = ident() endfunc func fn2 caption = "Second Function" default = ident() endfunc func fn3 caption = "Third Function" default = cotan() endfunc func fn4 caption = "Fouth Function" default = abs() endfunc heading caption = "Bailout" endheading param bailout caption = "Bailout value" default = 1e20 min = 1.0 $IFDEF VER40 exponential = true $ENDIF endparam switch: type = "Mandelbrot" power = @power bailout = @bailout distortion = @distortion style = @style distangle = @distangle distcenter = @distcenter centermove = @centermove offset = @offset scale = @scale angle = @angle step = @step anglestep = @anglestep octaves = @octaves npower = @npower noisestart = @noisestart noiseiter = @noiseiter noiseskip = @noiseskip coloronly = @coloronly } gnd-4D-Barnsley-Julia-RealityPlay { ; Hypercomplex Barnsley Julia formula ; version 1.12, August 2005 ; Gilles Nadeau, 12/08/2005 ; ; re-edit for reality play init: float xx = real(#pixel) float yy = imag(#pixel) float zz = real(@zjk) float ww = imag(@zjk) float cx = real(@c1i) float cy = imag(@c1i) float cz = real(@cjk) float cw = imag(@cjk) float zr = 0.0 float zi = 0.0 float zj = 0.0 float zk = 0.0 float cr = 0.0 float ci = 0.0 float cj = 0.0 float ck = 0.0 float rx = 0.0 float ry = 0.0 float rz = 0.0 ; (yz plane rotation) ry = yy*cos(#pi*@rotx/180) - zz*sin(#pi*@rotx/180) rz = yy*sin(#pi*@rotx/180) + zz*cos(#pi*@rotx/180) yy = ry zz = rz ry = cy*cos(#pi*@rotx/180) - cz*sin(#pi*@rotx/180) rz = cy*sin(#pi*@rotx/180) + cz*cos(#pi*@rotx/180) cy = ry cz = rz ; (xz plane rotation) rx = zz*sin(#pi*@roty/180) + xx*cos(#pi*@roty/180) rz = zz*cos(#pi*@roty/180) - xx*sin(#pi*@roty/180) xx = rx zz = rz rx = cz*sin(#pi*@roty/180) + cx*cos(#pi*@roty/180) rz = cz*cos(#pi*@roty/180) - cx*sin(#pi*@roty/180) cx = rx cz = rz ; (xy plane rotation) rx = xx*cos(#pi*@rotz/180) - yy*sin(#pi*@rotz/180) ry = xx*sin(#pi*@rotz/180) + yy*cos(#pi*@rotz/180) xx = rx yy = ry rx = cx*cos(#pi*@rotz/180) - cy*sin(#pi*@rotz/180) ry = cx*sin(#pi*@rotz/180) + cy*cos(#pi*@rotz/180) cx = rx cy = ry if @fourthdim == 3 zr = xx zi = yy zj = zz zk = ww cr = cx ci = cy cj = cz ck = cw elseif @fourthdim == 2 zr = xx zi = yy zj = ww zk = zz cr = cx ci = cy cj = cw ck = cz elseif @fourthdim == 1 zr = zz zi = ww zj = xx zk = yy cr = cz ci = cw cj = cx ck = cy else zr = ww zi = zz zj = xx zk = yy cr = cw ci = cz cj = cx ck = cy endif complex a = @fn6(@fn5(fn4(zr) - zk) + fn3(zi + zj)) complex b = @fn6(@fn5(fn4(zr) + zk) + fn3(zi - zj)) complex ca = @fn6(@fn5(fn4(cr) - ck) + fn3(ci + cj)) complex cb = @fn6(@fn5(fn4(cr) + ck) + fn3(ci - cj)) loop: if @treal == true if real(a)<@bs a = fn1(a - 1) * ca elseif real(a)<(@bs-(@bs*.1)) a = fn1(a - 1) + ca elseif real(a)<(@bs-(@bs*.2)) a = fn1(a - 1) * ca elseif real(a)<(@bs-(@bs*.3)) a = fn1(a - 1) + ca elseif real(a)<(@bs-(@bs*.4)) a = fn1(a - 1) * ca elseif real(a)<(@bs-(@bs*.5)) a = fn1(a - 1) + ca elseif real(a)<(@bs-(@bs*.6)) a = fn1(a - 1) * ca elseif real(a)<(@bs-(@bs*.7)) a = fn1(a - 1) + ca elseif real(a)<(@bs-(@bs*.8)) a = fn1(a - 1) * ca elseif real(a)<(@bs-(@bs*.9)) a = fn1(a - 1) + ca elseif real(a)<=0 a = fn1(a + 1) + ca elseif real(a)<((@bs*.9)-@bs) a = fn1(a + 1) * ca elseif real(a)<((@bs*.8)-@bs) a = fn1(a + 1) + ca elseif real(a)<((@bs*.7)-@bs) a = fn1(a + 1) * ca elseif real(a)<((@bs*.6)-@bs) a = fn1(a + 1) + ca elseif real(a)<((@bs*.5)-@bs) a = fn1(a + 1) * ca elseif real(a)<((@bs*.4)-@bs) a = fn1(a + 1) + ca elseif real(a)<((@bs*.3)-@bs) a = fn1(a + 1) * ca elseif real(a)<((@bs*.2)-@bs) a = fn1(a + 1) + ca elseif real(a)<((@bs*.1)-@bs) a = fn1(a + 1) * ca elseif real(a)<(@bs*(-1)) a = fn1(a + 1) + ca else a = fn1(a - 1) * ca endif if real(b)<@bs b = fn2(b + 1) * cb elseif real(b)<(@bs-(@bs*.1)) b = fn2(b + 1) + cb elseif real(b)<(@bs-(@bs*.2)) b = fn2(b + 1) * cb elseif real(b)<(@bs-(@bs*.3)) b = fn2(b + 1) + cb elseif real(b)<(@bs-(@bs*.4)) b = fn2(b + 1) * cb elseif real(b)<(@bs-(@bs*.5)) b = fn2(b + 1) + cb elseif real(b)<(@bs-(@bs*.6)) b = fn2(b + 1) * cb elseif real(b)<(@bs-(@bs*.7)) b = fn2(b + 1) + cb elseif real(b)<(@bs-(@bs*.8)) b = fn2(b + 1) * cb elseif real(b)<(@bs-(@bs*.9)) b = fn2(b + 1) + cb elseif real(b)<=0 b = fn2(b - 1) + cb elseif real(b)<((@bs*.9)-@bs) b = fn2(b - 1) * cb elseif real(b)<((@bs*.8)-@bs) b = fn2(b - 1) + cb elseif real(b)<((@bs*.7)-@bs) b = fn2(b - 1) * cb elseif real(b)<((@bs*.6)-@bs) b = fn2(b - 1) + cb elseif real(b)<((@bs*.5)-@bs) b = fn2(b - 1) * cb elseif real(b)<((@bs*.4)-@bs) b = fn2(b - 1) + cb elseif real(b)<((@bs*.3)-@bs) b = fn2(b - 1) * cb elseif real(b)<((@bs*.2)-@bs) b = fn2(b - 1) + cb elseif real(b)<((@bs*.1)-@bs) b = fn2(b - 1) * cb elseif real(b)<(@bs*(-1)) b = fn2(b - 1) + cb else b = fn2(b + 1) * cb endif else a = fn1(a-1)*ca b = fn2(b+1)*cb endif if @timag == true if imag(a)<@bs a = fn1(a - 1) * ca elseif imag(a)<(@bs-(@bs*.1)) a = fn1(a - 1) + ca elseif imag(a)<(@bs-(@bs*.2)) a = fn1(a - 1) * ca elseif imag(a)<(@bs-(@bs*.3)) a = fn1(a - 1) + ca elseif imag(a)<(@bs-(@bs*.4)) a = fn1(a - 1) * ca elseif imag(a)<(@bs-(@bs*.5)) a = fn1(a - 1) + ca elseif imag(a)<(@bs-(@bs*.6)) a = fn1(a - 1) * ca elseif imag(a)<(@bs-(@bs*.7)) a = fn1(a - 1) + ca elseif imag(a)<(@bs-(@bs*.8)) a = fn1(a - 1) * ca elseif imag(a)<(@bs-(@bs*.9)) a = fn1(a - 1) + ca elseif imag(a)<=0 a = fn1(a + 1) + ca elseif imag(a)<((@bs*.9)-@bs) a = fn1(a + 1) * ca elseif imag(a)<((@bs*.8)-@bs) a = fn1(a + 1) + ca elseif imag(a)<((@bs*.7)-@bs) a = fn1(a + 1) * ca elseif imag(a)<((@bs*.6)-@bs) a = fn1(a + 1) + ca elseif imag(a)<((@bs*.5)-@bs) a = fn1(a + 1) * ca elseif imag(a)<((@bs*.4)-@bs) a = fn1(a + 1) + ca elseif imag(a)<((@bs*.3)-@bs) a = fn1(a + 1) * ca elseif imag(a)<((@bs*.2)-@bs) a = fn1(a + 1) + ca elseif imag(a)<((@bs*.1)-@bs) a = fn1(a + 1) * ca elseif imag(a)<(@bs*(-1)) a = fn1(a + 1) + ca else a = fn1(a - 1) * ca endif if imag(b)<@bs b = fn2(b + 1) * cb elseif imag(b)<(@bs-(@bs*.1)) b = fn2(b + 1) + cb elseif imag(b)<(@bs-(@bs*.2)) b = fn2(b + 1) * cb elseif imag(b)<(@bs-(@bs*.3)) b = fn2(b + 1) + cb elseif imag(b)<(@bs-(@bs*.4)) b = fn2(b + 1) * cb elseif imag(b)<(@bs-(@bs*.5)) b = fn2(b + 1) + cb elseif imag(b)<(@bs-(@bs*.6)) b = fn2(b + 1) * cb elseif imag(b)<(@bs-(@bs*.7)) b = fn2(b + 1) + cb elseif imag(b)<(@bs-(@bs*.8)) b = fn2(b + 1) * cb elseif imag(b)<(@bs-(@bs*.9)) b = fn2(b + 1) + cb elseif imag(b)<=0 b = fn2(b - 1) + cb elseif imag(b)<((@bs*.9)-@bs) b = fn2(b - 1) * cb elseif imag(b)<((@bs*.8)-@bs) b = fn2(b - 1) + cb elseif imag(b)<((@bs*.7)-@bs) b = fn2(b - 1) * cb elseif imag(b)<((@bs*.6)-@bs) b = fn2(b - 1) + cb elseif imag(b)<((@bs*.5)-@bs) b = fn2(b - 1) * cb elseif imag(b)<((@bs*.4)-@bs) b = fn2(b - 1) + cb elseif imag(b)<((@bs*.3)-@bs) b = fn2(b - 1) * cb elseif imag(b)<((@bs*.2)-@bs) b = fn2(b - 1) + cb elseif imag(b)<((@bs*.1)-@bs) b = fn2(b - 1) * cb elseif imag(b)<(@bs*(-1)) b = fn2(b - 1) + cb else b = fn2(b + 1) * cb endif endif if @ajc == 0 elseif @ajc == 1 a = a^@power + @bost elseif @ajc == 2 a = a^@power - @bost elseif @ajc == 3 a = a^@power * @bost elseif @ajc == 4 a = a^@power / @bost elseif @ajc == 5 a = (a^@power)^@bost endif if @bjc == 0 elseif @bjc == 1 b = b^@power + @bost elseif @bjc == 2 b = b^@power - @bost elseif @bjc == 3 b = b^@power * @bost elseif @bjc == 4 b = b^@power / @bost elseif @bjc == 5 b = (b^@power)^@bost endif z = (a+b) / 2 bailout: (|a| + |b|) / 2 <= @bailout default: title = "4-D Barnsley Reality Play" center = (0.0,0.0) magn = 1.0 maxiter = 149 method = multipass periodicity = 0 param version caption = "Version" default = 1.12 visible = false endparam bool param treal caption = "Real Test" default = true endparam bool param timag caption = "Imag Test" default = false endparam param fourthdim caption = "Fourth dimension" enum = "z1" "zi" "zj" "zk" default = 3 endparam param ajc caption = "AJ" enum = "none" "+" "-" "*" "/" "^" default = 0 endparam param bjc caption = "BJ" enum = "none" "+" "-" "*" "/" "^" default = 0 endparam param bost caption = "bost" default = (2.0,0.0) visible = @ajc != 0 || @bjc != 0 endparam param power caption = "power" default = (2.0,0.0) visible = @ajc != 0 || @bjc != 0 endparam param bs caption = "Bands" default = -.2 endparam param c1i caption = "Left-Right" default = (0.0, 1.02) endparam param cjk caption = "Right-Left" default = (-.02, 0.01) endparam param zjk caption = "All Around" default = (-0.6, -0.4) endparam param rotx caption="x-rotation" hint="Rotates yz-plane." default=0.0 min=-360.0 max=360.0 endparam param roty caption="y-rotation" hint="Rotates zx-plane." default=0.0 min=-360.0 max=360.0 endparam param rotz caption="z-rotation" hint="Rotates xy-plane." default=0.0 min=-360.0 max=360.0 endparam func fn1 caption = "First Function" default = ident() endfunc func fn2 caption = "Second Function" default = ident() endfunc func fn3 caption = "Third Function" default = flip() endfunc func fn4 caption = "Fouth Function" default = ident() endfunc func fn5 caption = "Fifth Function" default = ident() endfunc func fn6 caption = "Sixth Function" default = ident() endfunc param bailout caption = "Bailout Value" default = 16.0 min = 0.0 endparam switch: type = "gnd-4D-Barnsley-Mandelbrot" version = @version cjk = @cjk var = @var fourthdim = @fourthdim rotx = @rotx roty = @roty rotz = @rotz bailout = @bailout } Insect9-j-reality { ;Andrea Spinozzi(Updated Aug2004) Init: z=#pixel c=@seed Loop: if (@invert == false) z=z else z=1/(z+#pixel) endif if @realy == true if real(z)<@bs z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba01)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba02)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba03)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba04)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba05)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba06)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba07)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba08)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs-(@bs*@ba09)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<=0 z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba09)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba08)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba07)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba06)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba05)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba04)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba03)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba02)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<((@bs*@ba01)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif real(z)<(@bs*(-1)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z else z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z endif endif ;realy if @imagy == true if imag(z)<@bs z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba01)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba02)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba03)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba04)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba05)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba06)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba07)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba08)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs-(@bs*@ba09)) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<=0 z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba09)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba08)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba07)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba06)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba05)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba04)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba03)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba02)-@bs) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<((@bs*@ba01)-@bs) z=@p-(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z elseif imag(z)<(@bs*(-1)) z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z else z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z endif endif ;imagy if @realy == false && @imagy == false z=@p+(c+z*(fn1(z)*fn2(z)*fn3(z)*fn4(z)*@fn5(z)))*z endif z = z / @detailer Bailout: |z| < @bailout Default: title="InterSected" center=(0.0,0.0) magn=1.5 maxiter=500 angle=90 method=multipass periodicity=0 Heading caption="Operators and Parameters" endheading param p caption="Parameter" default=(.061205,-0.155227) endparam param invert Caption="Invert Z" default=false endparam param @seed caption="Seed Value" default=(-1.094,0.226619) endparam bool param realy caption = "The Real World?" default = true endparam bool param imagy caption = "Imaginary World?" default = false endparam param bs caption = "band size" default = -2.116664 endparam param detailer caption = "Detailer" default = (1.0,0.0) endparam Heading caption="Functions" endheading func fn1 caption="Function 1" default=zero() endfunc func fn2 caption="Function 2" default=trunc() endfunc func fn3 caption="Function 3" default=asinh() endfunc func fn4 caption="Function 4" default=sin() endfunc func fn5 caption="Function 5" default=sin() endfunc param version caption="Version" default=1.0 visible=false endparam Heading caption = "BailOut" endheading param bailout caption="Bailout Value" default=30 min=0.0 endparam heading caption = "Advanced" endheading bool param advanced caption = "Adv Set" default = false endparam param ba01 caption = "Band .1" default = 0.1 visible = @advanced == true endparam param ba02 caption = "Band .2" default = 0.2 visible = @advanced == true endparam param ba03 caption = "Band .3" default = 0.3 visible = @advanced == true endparam param ba04 caption = "Band .4" default = 0.4 visible = @advanced == true endparam param ba05 caption = "Band .5" default = 0.5 visible = @advanced == true endparam param ba06 caption = "Band .6" default = 0.6 visible = @advanced == true endparam param ba07 caption = "Band .7" default = 0.7 visible = @advanced == true endparam param ba08 caption = "Band .8" default = 0.8 visible = @advanced == true endparam param ba09 caption = "Band .9" default = 0.9 visible = @advanced == true endparam Switch: type="Julia" seed=#pixel bailout=@bailout fn1=@fn1 fn2=@fn2 fn3=@fn3 fn4=@fn4 fn5=@fn5 p=@p op1=@op1 invert=@invert version=@version } RealitiveNow { init: z = #pixel loop: if @ins == 0 ;+ a = fn2(z^@power) + fn1(@seed) elseif @ins == 1 ;- a = fn2(z^@power) - fn1(@seed) elseif @ins == 2 ;* a = fn2(z^@power) * fn1(@seed) elseif @ins == 3 ;/ a = fn2(z^@power) / fn1(@seed) elseif @ins == 4 ;^ a = fn2(z^@power) ^ fn1(@seed) endif if @rl1 == 0 ;+ if @rsc == 0 ;+ z = fn4(z) + fn3(a+@speed1) elseif @rsc == 1 ;- z = fn4(z) + fn3(a-@speed1) elseif @rsc == 2 ;* z = fn4(z) + fn3(a*@speed1) elseif @rsc == 3 ;/ z = fn4(z) + fn3(a/@speed1) elseif @rsc == 4 ;^ z = fn4(z) + fn3(a^@speed1) endif elseif @rl1 == 1 ;- if @rsc == 0 ;+ z = fn4(z) - fn3(a+@speed1) elseif @rsc == 1 ;- z = fn4(z) - fn3(a-@speed1) elseif @rsc == 2 ;* z = fn4(z) - fn3(a*@speed1) elseif @rsc == 3 ;/ z = fn4(z) - fn3(a/@speed1) elseif @rsc == 4 ;^ z = fn4(z) - fn3(a^@speed1) endif endif if @shl == 0 elseif @shl == 1 if @rl2 == 0 ;+ if @rsc1 == 0 ;+ z = fn4(z) + fn3(a+@speed2) elseif @rsc1 == 1 ;- z = fn4(z) + fn3(a-@speed2) elseif @rsc1 == 2 ;* z = fn4(z) + fn3(a*@speed2) elseif @rsc1 == 3 ;/ z = fn4(z) + fn3(a/@speed2) elseif @rsc1 == 4 ;^ z = fn4(z) + fn3(a^@speed2) endif elseif @rl2 == 1 ;- if @rsc1 == 0 ;+ z = fn4(z) - fn3(a+@speed2) elseif @rsc1 == 1 ;- z = fn4(z) - fn3(a-@speed2) elseif @rsc1 == 2 ;* z = fn4(z) - fn3(a*@speed2) elseif @rsc1 == 3 ;/ z = fn4(z) - fn3(a/@speed2) elseif @rsc1 == 4 ;^ z = fn4(z) - fn3(a^@speed2) endif endif elseif @shl == 2 if @rl2 == 0 ;+ if @rsc1 == 0 ;+ b = fn4(z) + fn3(a+@speed2) elseif @rsc1 == 1 ;- b = fn4(z) + fn3(a-@speed2) elseif @rsc1 == 2 ;* b = fn4(z) + fn3(a*@speed2) elseif @rsc1 == 3 ;/ b = fn4(z) + fn3(a/@speed2) elseif @rsc1 == 4 ;^ b = fn4(z) + fn3(a^@speed2) endif elseif @rl2 == 1 ;- if @rsc1 == 0 ;+ b = fn4(z) - fn3(a+@speed2) elseif @rsc1 == 1 ;- b = fn4(z) - fn3(a-@speed2) elseif @rsc1 == 2 ;* b = fn4(z) - fn3(a*@speed2) elseif @rsc1 == 3 ;/ b = fn4(z) - fn3(a/@speed2) elseif @rsc1 == 4 ;^ b = fn4(z) - fn3(a^@speed2) endif endif if @rl3 == 0 ;+ if @rsc2 == 0 ;+ z = fn4(z) + fn3(b+@speed3) elseif @rsc2 == 1 ;- z = fn4(z) + fn3(b-@speed3) elseif @rsc2 == 2 ;* z = fn4(z) + fn3(b*@speed3) elseif @rsc2 == 3 ;/ z = fn4(z) + fn3(b/@speed3) elseif @rsc2 == 4 ;^ z = fn4(z) + fn3(b^@speed3) endif elseif @rl3 == 1 ;- if @rsc2 == 0 ;+ z = fn4(z) - fn3(b+@speed3) elseif @rsc2 == 1 ;- z = fn4(z) - fn3(b-@speed3) elseif @rsc2 == 2 ;* z = fn4(z) - fn3(b*@speed3) elseif @rsc2 == 3 ;/ z = fn4(z) - fn3(b/@speed3) elseif @rsc2 == 4 ;^ z = fn4(z) - fn3(b^@speed3) endif endif endif bailout: |z| <= @fn5(@bailout) default: title = "Relative" helpfile = "Uf*.chm" param ins caption = "Init seed" enum = "+" "-" "*" "/" "^" default = 1 endparam param shl caption = "Level Count" enum = "0" "1" "2" default = 0 endparam param power caption = "Power" default = (2,0) endparam param seed caption = "Julia seed" default = (-1.25, 0) endparam heading caption = "Level 1" endheading param rl1 caption = "Relative Speed 1" enum = "Higher" "Lower" default = 0 endparam param rsc caption = "Realtive Speed Control" enum = "Add" "Subtract" "Multiply" "Divide" "Powered" default = 3 endparam param speed1 caption = "Relative Speed 1" default = (-1.31793,0.95971) endparam heading caption = "Level 2" visible = @shl >= 1 endheading param rl2 caption = "Relative Speed 2" enum = "Higher" "Lower" default = 0 visible = @shl >= 1 endparam param rsc1 caption = "Realtive Speed Control" enum = "Add" "Subtract" "Multiply" "Divide" "Powered" default = 3 visible = @shl >= 1 endparam param speed2 caption = "Relative Speed 2" default = (-1.31793,0.95971) visible = @shl >= 1 endparam heading caption = "Level 3" visible = @shl >= 2 endheading param rl3 caption = "Relative Speed 3" enum = "Higher" "Lower" default = 0 visible = @shl >= 2 endparam param rsc2 caption = "Realtive Speed Control" enum = "Add" "Subtract" "Multiply" "Divide" "Powered" default = 3 visible = @shl >= 2 endparam param speed3 caption = "Relative Speed 3" default = (-1.31793,0.95971) visible = @shl >= 2 endparam heading caption = "bailout" endheading param bailout caption = "Bailout value" default = 4.0 min = 1.0 $IFDEF VER40 exponential = true $ENDIF endparam heading caption = "Functions" endheading func fn1 caption="Function 1" default= ident() endfunc func fn2 caption="Function 2" default= ident() endfunc func fn3 caption="Function 3" default= ident() endfunc func fn4 caption="Function 4" default= ident() endfunc func fn5 caption="Function 5" default= ident() endfunc switch: type = "Mandelbrot" power = power bailout = bailout } LambdaJulia2 { global: import "common.ulb" import "Standard.ulb" int numformulas=3; Formula f[3]; f[0]=new @formulaClass1(0) f[1]=new @formulaClass2(0) f[2]=new @formulaClass2(0) init: z = #pixel int count=0; #z = f[count%numformulas].Init(#pixel) f[1].Init(#pixel); f[2].Init(#pixel); complex oz = z complex c = @distcenter IF (@centermove) c = #center ENDIF complex r = (0,1) ^ (@angle / 90.0) complex r2 = (0,1) ^ (@anglestep / 90.0) complex r3 = (0,1) ^ (@distangle / 90.0) float fiter = @noisestart BOOL noise = false complex z = pixel zc = fn3(sqr(z/2)*2) z = fn4(2*(z - zc)/2) loop: ;---------------Plugins----------------- if @ask_Startplugins_1 == true #z = f[0].Iterate(#z) endif ;---------------Plugins----------------- ;---------------Plugins----------------- if @ask_Startplugins_2 == true #z = f[1].Iterate(#z) endif ;---------------Plugins----------------- IF (@noiseskip != 0); we are skipping some iterations fiter = fiter - 1; one less to go before we add noise WHILE (fiter < 0.0); iterations all used up IF (noise); we are currently adding noise noise = false; so stop fiter = fiter + @noiseskip; skip this many iterations ELSE; we aren't currently adding noise noise = true; so start fiter = fiter + @noiseiter; do this many iterations ENDIF ENDWHILE ENDIF IF (@coloronly); only using fBm on coloring z = oz; restore z from un-fBm'ed copy ENDIF if @splits == true if real(z) > (@bas + .5) akl = (@fn6(@power) - fn1(@lv2))/@cha elseif imag(z) < (@bas -.5) akl = (@fn6(@power) - fn1(@lv2))+(@cha) elseif real(z) > (@bas +.3) akl = (@fn6(@power) - fn1(@lv2))/(@cha/2) elseif imag(z) < (@bas -.3) akl = (@fn6(@power) - fn1(@lv2))+(@cha/2) elseif real(z) > (@bas +.1) akl = (@fn6(@power) - fn1(@lv2))*(-1) elseif imag(z) < (@bas -.1) akl = (@fn6(@power) - fn1(@lv2))*(-1) elseif real(z) > (@bas -.1) akl = (@fn6(@power) - fn1(@lv2))*(-1) elseif imag(z) < (@bas +.1) akl = (@fn6(@power) - fn1(@lv2))*(-1) elseif real(z) > (@bas -.3) akl = (@fn6(@power) - fn1(@lv2))*(@cha/2) elseif imag(z) < (@bas +.3) akl = (@fn6(@power) - fn1(@lv2))-(@cha/2) elseif real(z) > (@bas -.5) akl = (@fn6(@power) - fn1(@lv2))*@cha elseif imag(z) < (@bas +.5) akl = (@fn6(@power) - fn1(@lv2))-@cha else akl = @fn6(@power) - fn1(@lv2) endif else akl = @fn6(@power) - fn1(@lv2) endif bkl = fn2(@lv1) - #z ;---------------Plugins----------------- if @ask_Midplugins_1 == true #z = f[0].Iterate(#z) endif ;---------------Plugins----------------- ;---------------Plugins----------------- if @ask_midplugins_2 == true #z = f[1].Iterate(#z) endif ;---------------Plugins----------------- ckl = fn3(@seed) * #z dkl = @fn5(bkl) ^ fn4(akl) z = ckl*dkl IF (@coloronly); only using fBm on coloring oz = z ENDIF IF (@noiseskip == 0.0 || noise); adding noise this iteration complex p = z * @scale * r + @offset float sum = 0.0 float freq = 1.0 complex v = (0,0) int i = @octaves WHILE (i > 0) ; determine integer coordinate for corners of square ; surrounding p float bx0 = floor(real(p)) % 256 float by0 = floor(imag(p)) % 256 IF (bx0 < 0) bx0 = bx0 + 256 ENDIF IF (by0 < 0) by0 = by0 + 256 ENDIF float bx1 = (bx0 + 1) % 256 float by1 = (by0 + 1) % 256 float rx0 = real(p) - floor(real(p)) float ry0 = imag(p) - floor(imag(p)) float rx1 = rx0 - 1 float ry1 = ry0 - 1 ; create a "random" index for each corner ; (this is where Intel's version differs from Perlin's; ; I used Intel's version because it doesn't require a ; pre-computed random table, which is difficult to manage ; in UF.) float b00 = (bx0^@npower % 65536 + by0)^@npower % 65536 float b10 = (bx1^@npower % 65536 + by0)^@npower % 65536 float b01 = (bx0^@npower % 65536 + by1)^@npower % 65536 float b11 = (bx1^@npower % 65536 + by1)^@npower % 65536 ; produce a "random" vector for each corner float g_b00_0 = (b00)^@npower*0.25 % 512 - 256 float g_b10_0 = (b10)^@npower*0.25 % 512 - 256 float g_b01_0 = (b01)^@npower*0.25 % 512 - 256 float g_b11_0 = (b11)^@npower*0.25 % 512 - 256 float g_b00_1 = (b00+1)^@npower*0.25 % 512 - 256 float g_b10_1 = (b10+1)^@npower*0.25 % 512 - 256 float g_b01_1 = (b01+1)^@npower*0.25 % 512 - 256 float g_b11_1 = (b11+1)^@npower*0.25 % 512 - 256 ; normalize each vector float d = 0.0; d = 1 / sqrt(sqr(g_b00_0) + sqr(g_b00_1)) g_b00_0 = g_b00_0 * d g_b00_1 = g_b00_1 * d d = 1 / sqrt(sqr(g_b10_0) + sqr(g_b10_1)) g_b10_0 = g_b10_0 * d g_b10_1 = g_b10_1 * d d = 1 / sqrt(sqr(g_b01_0) + sqr(g_b01_1)) g_b01_0 = g_b01_0 * d g_b01_1 = g_b01_1 * d d = 1 / sqrt(sqr(g_b11_0) + sqr(g_b11_1)) g_b11_0 = g_b11_0 * d g_b11_1 = g_b11_1 * d ; produce colors for each corner float u1 = rx0 * g_b00_0 + ry0 * g_b00_1 float v1 = rx1 * g_b10_0 + ry0 * g_b10_1 float u2 = rx0 * g_b01_0 + ry1 * g_b01_1 float v2 = rx1 * g_b11_0 + ry1 * g_b11_1 ; interpolate between corners using ; bilinear filtering float sx = sqr(rx0) * (3 - rx0*2) float sy = sqr(ry0) * (3 - ry0*2) float a = u1 + sx*(v1-u1) float b = u2 + sx*(v2-u2) sum = sum + (a + sy*(b-a))*freq freq = freq * @step p = p * r2 / @step i = i - 1 ENDWHILE IF (@style == 0); radial distortion v = (z-c)/cabs(z-c) * r3; use vector based on angle to distortion center ELSEIF (@style == 1); linear distortion v = r3; just use rotation vector ENDIF z = z + v * sum*0.5*@distortion ENDIF IF (@coloronly == false); not just using fBm on coloring oz = z; value for bailout is fBm'ed z ENDIF ;---------------Plugins----------------- if @ask_Endplugins_1 == true #z = f[0].Iterate(#z) endif ;---------------Plugins----------------- ;---------------Plugins----------------- if @ask_Endplugins_2 == true #z = f[1].Iterate(#z) endif ;---------------Plugins----------------- bailout: |z| < @bailout default: title = "Lambda (Julia) +" helpfile = "Uf*.chm" helptopic = "Html\formulas\standard\lambda.html" center = (0.5, 0) heading caption = "Reality Controls" endheading bool param splits caption = "Chaos?" default = false endparam param cha caption = "Chaos" default = (1.0,1.0) visible = @splits == true endparam param bas caption = "Bands" default = 1.0 visible = @splits == true endparam heading caption = "Formula Controls" endheading param seed caption = "Julia Seed" default = (1,0) endparam param power caption = "Exponent" default = (2,0) endparam param lv1 caption = "Level 1" default = (1.0,0.0) endparam param lv2 caption = "Level 1" default = (1.0,0.0) endparam param bailout caption = "Bailout" default = 1.0e20 $IFDEF VER40 exponential = true $ENDIF endparam heading caption = "Functions" endheading func fn1 caption="Function 1" default= ident() endfunc func fn2 caption="Function 2" default= ident() endfunc func fn3 caption="Function 3" default= ident() endfunc func fn4 caption="Function 4" default= ident() endfunc func fn5 caption="Function 5" default= ident() endfunc func fn6 caption="Function 6" default= ident() endfunc Heading caption = "Distortion" endheading param distortion caption = "Distortion Strength" default = .5 hint = "This is the amount the noise distorts the image." endparam param style caption = "Distortion Style" default = 0 enum = "radial" "linear" hint = "This selects whether the distortion will be focused \ around a single point, or directed along a line." endparam param distangle caption = "Distortion Angle" default = 0.0 hint = "This is the angle to rotate the distortion." endparam param distcenter caption = "Distortion Center" default = (0,0) hint = "Sets the center of distortion. If Use Screen \ Center is set, this item is ignored." endparam param centermove caption = "Use Screen Center" default = FALSE hint = "If set, distortion will be around the center of \ the window, regardless of the Distortion Center \ setting." endparam param offset caption = "Noise Offset" default = (0,0) hint = "This is the offset of the pattern. You can use this to shift \ the pattern around on the complex plane." endparam param scale caption = "Noise Scale" default = 1.0 hint = "This is the overall scale of the noise." endparam param angle caption = "Noise Rotation" default = 0.0 hint = "This is the angle, in degrees, of the noise." endparam param step caption = "Noise Scale Step" default = 0.5 hint = "This is the step in scale between noise iterations." endparam param anglestep caption = "Noise Rotation Step" default = 37.0 hint = "This is the angle, in degrees, to rotate between noise \ iterations." endparam param octaves caption = "Noise Octaves" default = 7 min = 1 hint = "This is the number of iterations of the noise formula." endparam param npower caption = "Noise Exponent" default = 2.0 hint = "This is the exponent used to scramble numbers." endparam param noisestart caption = "Start Iteration" default = 0.0 hint = "This is the iteration at which to start adding noise." endparam param noiseiter caption = "Noise Iterations" default = 1e20 hint = "This is the number of iterations to add noise to." endparam param noiseskip caption = "Skip Iterations" default = 0.0 hint = "This is the number of iterations to skip adding noise \ before starting again." endparam param coloronly caption = "Coloring Only" default = false hint = "If set, noise will only apply to pixel values passed \ to the coloring algorithm; it will not be included in \ the fractal calculation between iterations." endparam heading caption = "Plugins" endheading Formula param formulaClass1 caption = "Formula #1" default = Standard_Pixel endparam bool param @ask_endplugins_1 caption = "ending plugins" default = false endparam bool param @ask_midplugins_1 caption = "Middle Plugins" default = false endparam bool param @ask_Startplugins_1 caption = "Starting Plugins" default = true endparam Formula param formulaClass2 caption = "Formula #2" default = Standard_Pixel endparam bool param @ask_endplugins_2 caption = "ending plugins" default = false endparam bool param @ask_midplugins_2 caption = "Middle Plugins" default = false endparam bool param @ask_Startplugins_2 caption = "Starting Plugins" default = true endparam switch: type = "LambdaMandelbrot" power = @power bailout = @bailout } Mountains2 { ; Written by KPK January 2000 ; Edited by DPB 2015 init: complex z = fn4(#pixel) complex p = @parameter zc = fn3(z/@sizesq)*@sizesq z = @strength*(z - zc)/@power loop: IF (imag(z)>@splits5) z = @strength*real(z) + @fn5(@strength*imag(z)-@loss) ELSEIF (real(z)>@splits5) z = @strength*real(z)-@loss + @fn5(@strength*imag(z)) ELSEIF (real(z)>@splits1) z = p1*fn1(sin(@loss/(z+p1))) ELSEIF (imag(z)<(-1 * @splits1)) z = @strength*imag(z)+@loss + @fn5(@strength*real(z)) ELSE z = fn2(((z^@pow2+p+@loss)/(@speed*z+p-@loss))^@pow2) + #pixel/@pixdiv ENDIF z = @fn6(z/@detailer) z = z * @detailer1 bailout: (@test == 0 && |z| <= @bailout) || \ (@test == 1 && sqr(real(z)) <= @bailout) || \ (@test == 2 && sqr(imag(z)) <= @bailout) || \ (@test == 3 && (sqr(real(z)) <= @bailout && sqr(imag(z)) < @bailout)) || \ (@test == 4 && (sqr(real(z)) <= @bailout || sqr(imag(z)) < @bailout)) || \ (@test == 5 && (sqr(abs(real(z)) + abs(imag(z))) <= @bailout)) || \ (@test == 6 && (sqr(real(z) + imag(z)) <= @bailout)) default: title = "Mountains 2" center = (2.10728126618,1.40988816185) magn = 1.1146505 angle = 6.2175 maxiter = 500 heading caption = "Singles" endheading param speed caption = "Shell Light" default = 3.0 endparam param strength caption = "Strength" default = 2.0 endparam param pow2 caption = "Small Moves" default = 2.0 endparam param loss caption = "Big Moves" default = 1.0 endparam param pixdiv caption = "Pixel Divided" default = 0.3 endparam param splits5 caption = "Splits .5" default = 0.5 endparam param splits1 caption = "Splits .1" default = 0.1 endparam param sizesq caption = "Magnification" default = 0.7 endparam param bailout caption = "Bailout" default = 1e20 endparam heading caption = "Doubles" endheading param power caption = "Power" default = (3.80952,-1.30953) endparam param p1 caption = "Paramater 1" default=(4.20239,-1.14286) endparam param parameter caption = "Federal Parameter" default = (0.41428,-0.31191) endparam param detailer caption = "Detailer /" default = (1.0,0.0) endparam param detailer1 caption = "Detailer *" default = (1.0,0.0) endparam heading caption = "Functions" endheading param test caption = "Shape Modifier" default = 6 enum = "mod" "real" "imag" "or" "and" "manh" "manr" endparam func fn1 caption = "Function 1" default = atanh() endfunc func fn2 caption = "Function 2" default = log() endfunc func fn3 caption = "Function 3" default = cotanh() endfunc func fn4 caption = "Function 4" default = ident() endfunc func fn5 caption = "Function 5" default = flip() endfunc func fn6 caption = "Function 6" default = ident() endfunc } Mini-Mandelbrot { ; ; Generic Mandelbrot set. ; init: z = @start loop: if @rc == true if real(z) > (@creal +.5) z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) elseif imag(z) < (@cimag - .5) z = fn4(fn2(fn1(z)^@power)/@s - fn3(#pixel)) elseif real(z) > (@creal +.1) z = fn4(fn2(fn1(z)^@power)/@s - fn3(#pixel)) elseif imag(z) < (@cimag -.1) z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) elseif real(z) > (@creal -.1) z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) elseif imag(z) < (@cimag +.1) z = fn4(fn2(fn1(z)^@power)/@s - fn3(#pixel)) elseif real(z) > (@creal -.5) z = fn4(fn2(fn1(z)^@power)/@s - fn3(#pixel)) elseif imag(z) < (@cimag +.5) z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) else z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) endif else z = fn4(fn2(fn1(z)^@power)/@s + fn3(#pixel)) endif bailout: |z| <= @bailout default: title = "RC Mandelbrot " center = (-0.5, 0) helpfile = "Uf*.chm" helptopic = "Html\formulas\standard\mandelbrot.html" $IFDEF VER50 rating = recommended $ENDIF heading caption = "Reality Controls" endheading bool param rc caption = "Reality Controls?" default = false endparam param creal caption = "Real" default = 0.0 visible = @rc == true endparam param cimag caption = "Imagery" default = 0.0 visible = @rc == true endparam heading caption = "Standard Controls" endheading param start caption = "Starting point" default = (0,0) endparam param power caption = "Power" default = (2,0) endparam param s caption = "Smalls" default = (1.0,0.0) endparam heading caption = "Functions" endheading func fn1 caption = "Function 1" default = ident() endfunc func fn2 caption = "Function 2" default = ident() endfunc func fn3 caption = "Function 3" default = ident() endfunc func fn4 caption = "Function 4" default = ident() endfunc float param bailout caption = "Bailout value" default = 4.0 min = 1.0 $IFDEF VER40 exponential = true $ENDIF endparam switch: type = "Julia" seed = #pixel power = power bailout = bailout } x/yJul{ ;By Samuel Monnier, 1999 ;The Julia Set with an additional term. init: z = #pixel + @start loop: x = real(z) y = imag(z) if @ask_explode == true if x >= .5 yx = fn3(y/x) xy = x/y elseif y >= -.5 yx = fn3(x/y) xy = y/x elseif x >= 0 yx = fn3(y*x) xy = x*y elseif y >= 0 yx = fn3(y*x) xy = x*y elseif x >= -.5 yx = fn3(y/x) xy = x/y elseif y >= .5 yx = fn3(x/y) xy = y/x endif else yx = fn3(y/x) xy = x/y endif zz = yx + (@seedz) * xy if @z1_ins == 0 zl = (z^fn4(@power) + zz^fn2(@powerxy))/yx elseif @z1_ins == 1 zl = (z^fn4(@power) - zz^fn2(@powerxy))/yx elseif @z1_ins == 1 zl = (z^fn4(@power) * zz^fn2(@powerxy))/yx elseif @z1_ins == 1 zl = (z^fn4(@power) / zz^fn2(@powerxy))/yx endif if @z2_ins == 0 z = zl + fn1(@seed/yx) elseif @z2_ins == 1 z = zl - fn1(@seed/yx) elseif @z2_ins == 1 z = zl * fn1(@seed/yx) elseif @z2_ins == 1 z = zl / fn1(@seed/yx) endif bailout: |z| <= @bailout default: title = "x/y Julia" center = (0.001, 0.001) magn = 1.0000001 param z1_ins caption = "Left Z" default = 0 enum = "+" "-" "*" "/" endparam param z2_ins caption = "Seed of Z" default = 1 enum = "+" "-" "*" "/" endparam bool param @ask_explode caption = "Explode!" default = false endparam param start caption = "Starting point" default = (0,0) endparam param power caption = "Power of z" default = (2,4) endparam param powerxy caption = "Power of the x/y term" default = (0,0) endparam param seed caption = "Seed Control" default = (-1.47,0) endparam param seedz caption = "Z Seed" default = (0,1) endparam heading caption = "Functions" endheading func fn1 caption = "Function 1" default = ident() endfunc func fn2 caption = "Function 2" default = ident() endfunc func fn3 caption = "Function 3" default = ident() endfunc func fn4 caption = "Function 4" default = acos() endfunc param bailout caption = "Bailout value" default = 1e50 endparam switch: type = "x/y" start = #pixel bailout = bailout power = power powerxy = powerxy } General-tent-julia-Sp { ; Based On Kerry Mitchell 05oct2000 init: if @prefun == false c=@julparam z=pixel float r=0.0 if(@rotunit==1) ; radians r=@rotamount else ; degrees r=@rotamount*#pi/180 endif rot0=cos(r)+fn1(flip(sin(r))) rot=rot0 temp=(0,0) else c=@julparam z=pixel float r=0.0 if(@rotunit==1) ; radians r=@rotamount else ; degrees r=@rotamount*#pi/180 endif rot0=@pfn1(r)+@pfn2(@pfn3(r)) rot=rot0 temp=(0,0) endif ;-----Gnarl------- if @gnarl == true p = #pixel / @s complex x = real(p) complex y = imag(p) complex xx = 0 int iter = 0 endif loop: ; ; rotate the map ; if(@rottype==1) ; constant rotation temp=@fn5(rot0)*(z) elseif(@rottype==2) ; progressive rotation rot=fn3(rot)*fn1(rot0) temp=fn3(rot)*(z) elseif(@rottype==3) ; oscillating rotation rot=@fn5(rot0)/fn3(rot) temp=fn3(rot)*(z) else ; no rotation temp=(z) endif ; ; choose the map variable ; if(@rtype==1) ; real part r=real(fn2(@fn6(temp))) elseif(@rtype==2) ; imag part r=imag(fn2(@fn6(temp))) elseif(@rtype==3) ; real*imag r=imag(fn2(@fn6(temp)))*real(fn2(@fn6(temp))) elseif(@rtype==4) ; imag/real r=imag(fn2(@fn6(temp)))/real(fn2(@fn6(temp))) else ; magnitude r=cabs(fn2(@fn6(temp))) endif ; ; execute tent map ; if(r<=1.0) z=fn4(c)*(temp) else z=fn4(c)*(2-temp) endif if @reazs == false tip=@rsf tap=@rpf else tip=@rs tap=@rp endif if @reality == 1 if real(z) > .5 z = z - ((z/tip)*tap) elseif imag(z) < -.5 z = z + ((z/tip)*tap) elseif real(z) >.1 z = z - (z/tip) elseif imag(z) < -.1 z = z + (z/tip) elseif real(z) > -.1 z = z - (z/tip) elseif imag(z) < .1 z = z + (z/tip) elseif real(z) > -.5 z = z - ((z/tip)/tap) elseif imag(z) < .5 z = z + ((z/tip)/tap) else z = z - (z/tip) endif elseif @reality == 2 if real(z) > .5 z = z - ((c/tip)*tap) elseif imag(z) < -.5 z = z + ((c/tip)*tap) elseif real(z) >.1 z = z - (c/tip) elseif imag(z) < -.1 z = z + (c/tip) elseif real(z) > -.1 z = z - (c/tip) elseif imag(z) < .1 z = z + (c/tip) elseif real(z) > -.5 z = z - ((c/tip)/tap) elseif imag(z) < .5 z = z + ((c/tip)/tap) else z = z - (c/tip) endif elseif @reality == 3 if real(z) > .5 z = c - ((z/tip)*tap) elseif imag(z) < -.5 z = c + ((z/tip)*tap) elseif real(z) >.1 z = c - (z/tip) elseif imag(z) < -.1 z = c + (z/tip) elseif real(z) > -.1 z = c - (z/tip) elseif imag(z) < .1 z = c + (z/tip) elseif real(z) > -.5 z = c - ((z/tip)/tap) elseif imag(z) < .5 z = c + ((z/tip)/tap) else z = c - (z/tip) endif elseif @reality == 4 if real(z) > .5 z = z - ((r/tip)*tap) elseif imag(z) < -.5 z = z + ((r/tip)*tap) elseif real(z) >.1 z = z - (r/tip) elseif imag(z) < -.1 z = z + (r/tip) elseif real(z) > -.1 z = z - (r/tip) elseif imag(z) < .1 z = z + (r/tip) elseif real(z) > -.5 z = z - ((r/tip)/tap) elseif imag(z) < .5 z = z + ((r/tip)/tap) else z = z - (r/tip) endif elseif @reality == 5 if real(z) > .5 z = z - (((r-c)/tip)*tap) elseif imag(z) < -.5 z = z + (((r-c)/tip)*tap) elseif real(z) >.1 z = z - ((r-c)/tip) elseif imag(z) < -.1 z = z + ((r-c)/tip) elseif real(z) > -.1 z = z - ((r-c)/tip) elseif imag(z) < .1 z = z + ((r-c)/tip) elseif real(z) > -.5 z = z - (((r-c)/tip)/tap) elseif imag(z) < .5 z = z + (((r-c)/tip)/tap) else z = z - ((r-c)/tip) endif elseif @reality == 6 if real(z) > .5 z = z*r - ((c/tip)*tap) elseif imag(z) < -.5 z = z*r + ((c/tip)*tap) elseif real(z) >.1 z = z*r - (c/tip) elseif imag(z) < -.1 z = z*r + (c/tip) elseif real(z) > -.1 z = z*r - (c/tip) elseif imag(z) < .1 z = z*r + (c/tip) elseif real(z) > -.5 z = z*r - ((c/tip)/tap) elseif imag(z) < .5 z = z*r + ((c/tip)/tap) else z = z*r - (c/tip) endif elseif @reality == 7 if real(z) > .5 z = z + ((z/tip)*tap) elseif imag(z) < -.5 z = z - ((z/tip)*tap) elseif real(z) >.1 z = z + (z/tip) elseif imag(z) < -.1 z = z - (z/tip) elseif real(z) > -.1 z = z + (z/tip) elseif imag(z) < .1 z = z - (z/tip) elseif real(z) > -.5 z = z + ((z/tip)/tap) elseif imag(z) < .5 z = z - ((z/tip)/tap) else z = z + (c/tip) endif elseif @reality == 8 if real(z) > .5 z = z - (z/tip) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - ((z/tip)*tap) elseif imag(z) < -.1 z = z + ((z/tip)*tap) elseif real(z) > -.1 z = z - ((z/tip)*tap) elseif imag(z) < .1 z = z + ((z/tip)*tap) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + (z/tip) else z = z - (c/tip) endif elseif @reality == 9 if real(z) > .5 z = z/tip - z/tap elseif imag(z) < -.5 z = z/tip + z/tap elseif real(z) >.1 z = z/tip - z/tap elseif imag(z) < -.1 z = z/tip + z/tap elseif real(z) > -.1 z = z/tip - z/tap elseif imag(z) < .1 z = z/tip + z/tap elseif real(z) > -.5 z = z/tip - z/tap elseif imag(z) < .5 z = z/tip + z/tap else z = z/tip - z/tap endif elseif @reality == 10 if real(z) > .5 z = z - ((c/tip)*tap) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - ((c/tip)*tap) elseif imag(z) < -.1 z = z + (z/tip) elseif real(z) > -.1 z = z - (z/tip) elseif imag(z) < .1 z = z + ((c/tip)*tap) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + ((c/tip)*tap) else z = z - (c/tip) endif elseif @reality == 11 if real(z) > .5 z = z - ((z/tap)*tip) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - (z/tip) elseif imag(z) < -.1 z = z + ((z/tip)*tap) elseif real(z) > -.1 z = z - ((z/tip)*tap) elseif imag(z) < .1 z = z + (z/tip) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + ((z/tip)*tip) else z = z - (z/tip) endif elseif @reality == 12 if real(z) > .5 z = c/tip - temp/tap + z elseif imag(z) < -.5 z = c/tip + temp/tap - z elseif real(z) >.1 z = c/tip - temp/tap + z elseif imag(z) < -.1 z = c/tip + temp/tap - z elseif real(z) > -.1 z = c/tip - temp/tap + z elseif imag(z) < .1 z = c/tip + temp/tap - z elseif real(z) > -.5 z = c/tip - temp/tap + z elseif imag(z) < .5 z = c/tip + temp/tap - z else z = c/tip - temp/tap + z endif endif ca = z*c if @MoreReal == true if real(z)<@bs z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.1)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.2)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.3)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.4)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.5)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.6)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.7)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.8)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.9)) z = fn1(z - 1) elseif real(z)<=0 z = fn1(z + 1) elseif real(z)<((@bs*.9)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.8)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.7)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.6)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.5)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.4)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.3)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.2)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.1)-@bs) z = fn1(z + 1) elseif real(z)<(@bs*(-1)) z = fn1(z + 1) else z = fn1(z - 1) endif if imag(z)<@bs z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.1)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.2)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.3)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.4)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.5)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.6)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.7)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.8)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.9)) z = fn1(z - 1) elseif imag(z)<=0 z = fn1(z + 1) elseif imag(z)<((@bs*.9)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.8)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.7)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.6)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.5)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.4)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.3)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.2)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.1)-@bs) z = fn1(z + 1) elseif imag(z)<(@bs*(-1)) z = fn1(z + 1) else z = fn1(z - 1) endif endif if @juliaplus == 1 if @jpp1_ins == 0 z = z^@jpp1 + @jps1 elseif @jpp1_ins == 1 z = z^@jpp1 - @jps1 elseif @jpp1_ins == 2 z = z^@jpp1 * @jps1 elseif @jpp1_ins == 3 z = z^@jpp1 / @jps1 elseif @jpp1_ins == 4 z = (z^@jpp1)^@jps1 endif elseif @juliaplus == 2 if @jpp1_ins == 0 z = z^@jpp1 + @jps1 elseif @jpp1_ins == 1 z = z^@jpp1 - @jps1 elseif @jpp1_ins == 2 z = z^@jpp1 * @jps1 elseif @jpp1_ins == 3 z = z^@jpp1 / @jps1 elseif @jpp1_ins == 4 z = (z^@jpp1)^@jps1 endif if @jpp2_ins == 0 z = z^@jpp2 + @jps2 elseif @jpp2_ins == 1 z = z^@jpp2 - @jps2 elseif @jpp2_ins == 2 z = z^@jpp2 * @jps2 elseif @jpp2_ins == 3 z = z^@jpp2 / @jps2 elseif @jpp2_ins == 4 z = (z^@jpp2)^@jps2 endif endif if @gnarl == true iter = iter + 1 xx = x x = x - @h * real(fn1(y + fn2(@a * (y + fn3(@b * y-z)))))*(z) y = y + @h * real(fn1(xx + fn2(@a * (xx + fn3(@b * xx/z)))))*abs(#z) z = x + flip(y) endif bailout: |z|<@bailout default: title="General Tent Julia - SP" maxiter=1000 periodicity=0 center=(-1.5,-1.1) magn=.45 angle=0 Heading caption = "Gnarls Controls" endheading bool param gnarl caption = "Gnarl?" default = false endparam param a caption = "Alpha" default = (2.7,0.0) visible = @gnarl == true endparam param b caption = "Beta" default = (2.7,0.0) visible = @gnarl == true endparam param c caption = "Cappa" default = (0.0,0.0) visible = @gnarl == true endparam param h caption = "Step size" default = (0.1,0.0) visible = @gnarl == true endparam param s caption = "Scale" default = (1.0,0.0) visible = @gnarl == true endparam heading caption = "Julia Controls" endheading param julparam caption="Julia parameter" default=(0.40942,0.99996) endparam param bailout caption="bailout" default=1000.0 endparam heading caption = "Rotation Controls" endheading param rtype caption="Start type" default=0 enum="magnitude" "real part" "imag part" "real*imag" "imag/real" hint="Determines the r value used in the tent map." endparam param rottype caption="rotation type" default=2 enum="none" "constant" "progressive" "oscillating" hint="In 'constant' mode, the same angle is used every iteration. \ In 'progressive' mode, the angle is increased by the amount every \ iteration. In 'oscillating' mode, the map is rotated forward, then \ back, then forward, etc." endparam param rotamount caption="rotation amount" default=1 hint="How much the map is rotated." endparam param rotunit caption="rotation units" default= 1 enum="degrees" "radians" hint="Units in which the rotation is expressed." endparam heading caption = "Reality Controls" endheading param reality caption = "Reality play" enum = "none" "Option 1" "Option 2" "Option 3" "Option 4" "Option 5" "Option 6" "Option 7" "Option 8" "Option 9" "Option 10" "Option 11" "Option 12" default = 10 endparam param reazs caption = "Real/Imag" default = false visible = @reality >= 1 endparam param rsf caption = "Reality Seeds" default = 3.46667 visible = @reazs == false && @reality >= 1 endparam param rpf caption = "Reality Power" default = 4.62222 visible = @reazs == false && @reality >= 1 endparam param rs caption = "Reality Seeds" default = (0.6,0.1) visible = @reazs == true endparam param rp caption = "Reality Power" default = (1.0,0.1) visible = @reazs == true endparam bool param MoreReal caption = "Even More Real" default = true endparam param bs caption = "Bind Size" default = (-.05556,0.0) visible = @MoreReal == true endparam heading caption = "Function Controls" endheading func fn1 caption="Function 1" default= ident() endfunc func fn2 caption="Function 2" default= ident() endfunc func fn3 caption="Function 3" default= ident() endfunc func fn4 caption="Function 4" default= ident() endfunc func fn5 caption="Function 5" default= ident() endfunc func fn6 caption="Function 6" default= ident() endfunc bool param prefun caption = "Pre Functions?" default = false endparam func pfn1 caption="Pre-Function 1" default= cos() visible = @prefun == true endfunc func pfn2 caption="Pre-Function 2" default= flip() visible = @prefun == true endfunc func pfn3 caption="Pre-Function 3" default= sin() visible = @prefun == true endfunc param juliaplus caption = "Add Julia" enum = "No" "1" "2" default = 2 endparam param jpp1_ins caption = "Julia Plus INS" enum = "+" "-" "*" "/" "^" default = 0 visible = @juliaplus == 1 || @juliaplus == 2 endparam param jpp1 caption = "Julia Power 1" default = (1.0,0.0) visible = @juliaplus == 1 || @juliaplus == 2 endparam param jps1 caption = "Julia Seed 1" default = (-1.47,0.0) visible = @juliaplus == 1 || @juliaplus == 2 endparam param jpp2_ins caption = "Julia Plus 2 INS" enum = "+" "-" "*" "/" "^" default = 1 visible = @juliaplus == 2 endparam param jpp2 caption = "Julia Power 2" default = (1.0,0.0) visible = @juliaplus == 2 endparam param jps2 caption = "Julia Seed 2" default = (-1.47,0.0) visible = @juliaplus == 2 endparam switch: type="general-tent-mandelbrot" bailout=bailout rtype=rtype rottype=rottype rotamount=rotamount rotunit=rotunit } general-tent-julia-kp { ; Kerry Mitchell 05oct2000 init: ;-----MainFormula----- if @prefun == false c=@julparam z=pixel float r=0.0 if(@rotunit==1) ; radians r=@rotamount else ; degrees r=@rotamount*#pi/180 endif rot0=cos(r)+flip(sin(r)) rot=rot0 temp=(0,0) else c=@julparam z=pixel float r=0.0 if(@rotunit==1) ; radians r=@rotamount else ; degrees r=@rotamount*#pi/180 endif rot0=@pfn1(r)+@pfn2(@pfn3(r)) rot=rot0 temp=(0,0) endif ;-----Gnarl------- if @gnarl == true p = #pixel / @s complex x = real(p) complex y = imag(p) complex xx = 0 int iter = 0 endif loop: ; ; rotate the map ; if @juliaplus == 1 if @jpp1_ins == 0 z = z^@jpp1 + @julparam elseif @jpp1_ins == 1 z = z^@jpp1 - @julparam elseif @jpp1_ins == 2 z = z^@jpp1 * @julparam elseif @jpp1_ins == 3 z = z^@jpp1 / @julparam elseif @jpp1_ins == 4 z = (z^@jpp1)^@julparam endif elseif @juliaplus == 2 if @jpp1_ins == 0 z = z^@jpp1 + @julparam elseif @jpp1_ins == 1 z = z^@jpp1 - @julparam elseif @jpp1_ins == 2 z = z^@jpp1 * @julparam elseif @jpp1_ins == 3 z = z^@jpp1 / @julparam elseif @jpp1_ins == 4 z = (z^@jpp1)^@julparam endif if @jpp2_ins == 0 z = z^@jpp2 + @julparam elseif @jpp2_ins == 1 z = z^@jpp2 - @julparam elseif @jpp2_ins == 2 z = z^@jpp2 * @julparam elseif @jpp2_ins == 3 z = z^@jpp2 / @julparam elseif @jpp2_ins == 4 z = (z^@jpp2)^@julparam endif endif if(@rottype==1) ; constant rotation temp=@fn5(rot0)*(z) elseif(@rottype==2) ; progressive rotation rot=fn3(rot)*fn1(rot0) temp=fn3(rot)*(z) elseif(@rottype==3) ; oscillating rotation rot=@fn5(rot0)/fn3(rot) temp=fn3(rot)*(z) else ; no rotation temp=(z) endif ; ; choose the map variable ; if(@rtype==1) ; real part r=real(fn2(@fn6(temp))) elseif(@rtype==2) ; imag part r=imag(fn2(@fn6(temp))) elseif(@rtype==3) ; real*imag r=imag(fn2(@fn6(temp)))*real(fn2(@fn6(temp))) elseif(@rtype==4) ; imag/real r=imag(fn2(@fn6(temp)))/real(fn2(@fn6(temp))) else ; magnitude r=cabs(fn2(@fn6(temp))) endif ; ; execute tent map ; if(r<=1.0) z=fn4(c)*(temp) else z=fn4(c)*(2-temp) endif if @reazs == false tip=@rsf tap=@rpf else tip=@rs tap=@rp endif if @reality == 1 if real(z) > .5 z = z - ((z/tip)*tap) elseif imag(z) < -.5 z = z + ((z/tip)*tap) elseif real(z) >.1 z = z - (z/tip) elseif imag(z) < -.1 z = z + (z/tip) elseif real(z) > -.1 z = z - (z/tip) elseif imag(z) < .1 z = z + (z/tip) elseif real(z) > -.5 z = z - ((z/tip)/tap) elseif imag(z) < .5 z = z + ((z/tip)/tap) else z = z - (z/tip) endif elseif @reality == 2 if real(z) > .5 z = z - ((c/tip)*tap) elseif imag(z) < -.5 z = z + ((c/tip)*tap) elseif real(z) >.1 z = z - (c/tip) elseif imag(z) < -.1 z = z + (c/tip) elseif real(z) > -.1 z = z - (c/tip) elseif imag(z) < .1 z = z + (c/tip) elseif real(z) > -.5 z = z - ((c/tip)/tap) elseif imag(z) < .5 z = z + ((c/tip)/tap) else z = z - (c/tip) endif elseif @reality == 3 if real(z) > .5 z = c - ((z/tip)*tap) elseif imag(z) < -.5 z = c + ((z/tip)*tap) elseif real(z) >.1 z = c - (z/tip) elseif imag(z) < -.1 z = c + (z/tip) elseif real(z) > -.1 z = c - (z/tip) elseif imag(z) < .1 z = c + (z/tip) elseif real(z) > -.5 z = c - ((z/tip)/tap) elseif imag(z) < .5 z = c + ((z/tip)/tap) else z = c - (z/tip) endif elseif @reality == 4 if real(z) > .5 z = z - ((r/tip)*tap) elseif imag(z) < -.5 z = z + ((r/tip)*tap) elseif real(z) >.1 z = z - (r/tip) elseif imag(z) < -.1 z = z + (r/tip) elseif real(z) > -.1 z = z - (r/tip) elseif imag(z) < .1 z = z + (r/tip) elseif real(z) > -.5 z = z - ((r/tip)/tap) elseif imag(z) < .5 z = z + ((r/tip)/tap) else z = z - (r/tip) endif elseif @reality == 5 if real(z) > .5 z = z - (((r-c)/tip)*tap) elseif imag(z) < -.5 z = z + (((r-c)/tip)*tap) elseif real(z) >.1 z = z - ((r-c)/tip) elseif imag(z) < -.1 z = z + ((r-c)/tip) elseif real(z) > -.1 z = z - ((r-c)/tip) elseif imag(z) < .1 z = z + ((r-c)/tip) elseif real(z) > -.5 z = z - (((r-c)/tip)/tap) elseif imag(z) < .5 z = z + (((r-c)/tip)/tap) else z = z - ((r-c)/tip) endif elseif @reality == 6 if real(z) > .5 z = z*r - ((c/tip)*tap) elseif imag(z) < -.5 z = z*r + ((c/tip)*tap) elseif real(z) >.1 z = z*r - (c/tip) elseif imag(z) < -.1 z = z*r + (c/tip) elseif real(z) > -.1 z = z*r - (c/tip) elseif imag(z) < .1 z = z*r + (c/tip) elseif real(z) > -.5 z = z*r - ((c/tip)/tap) elseif imag(z) < .5 z = z*r + ((c/tip)/tap) else z = z*r - (c/tip) endif elseif @reality == 7 if real(z) > .5 z = z + ((z/tip)*tap) elseif imag(z) < -.5 z = z - ((z/tip)*tap) elseif real(z) >.1 z = z + (z/tip) elseif imag(z) < -.1 z = z - (z/tip) elseif real(z) > -.1 z = z + (z/tip) elseif imag(z) < .1 z = z - (z/tip) elseif real(z) > -.5 z = z + ((z/tip)/tap) elseif imag(z) < .5 z = z - ((z/tip)/tap) else z = z + (c/tip) endif elseif @reality == 8 if real(z) > .5 z = z - (z/tip) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - ((z/tip)*tap) elseif imag(z) < -.1 z = z + ((z/tip)*tap) elseif real(z) > -.1 z = z - ((z/tip)*tap) elseif imag(z) < .1 z = z + ((z/tip)*tap) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + (z/tip) else z = z - (c/tip) endif elseif @reality == 9 if real(z) > .5 z = z/tip - z/tap elseif imag(z) < -.5 z = z/tip + z/tap elseif real(z) >.1 z = z/tip - z/tap elseif imag(z) < -.1 z = z/tip + z/tap elseif real(z) > -.1 z = z/tip - z/tap elseif imag(z) < .1 z = z/tip + z/tap elseif real(z) > -.5 z = z/tip - z/tap elseif imag(z) < .5 z = z/tip + z/tap else z = z/tip - z/tap endif elseif @reality == 10 if real(z) > .5 z = z - ((c/tip)*tap) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - ((c/tip)*tap) elseif imag(z) < -.1 z = z + (z/tip) elseif real(z) > -.1 z = z - (z/tip) elseif imag(z) < .1 z = z + ((c/tip)*tap) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + ((c/tip)*tap) else z = z - (c/tip) endif elseif @reality == 11 if real(z) > .5 z = z - ((z/tap)*tip) elseif imag(z) < -.5 z = z + (z/tip) elseif real(z) >.1 z = z - (z/tip) elseif imag(z) < -.1 z = z + ((z/tip)*tap) elseif real(z) > -.1 z = z - ((z/tip)*tap) elseif imag(z) < .1 z = z + (z/tip) elseif real(z) > -.5 z = z - (z/tip) elseif imag(z) < .5 z = z + ((z/tip)*tip) else z = z - (z/tip) endif elseif @reality == 12 if real(z) > .5 z = c/tip - temp/tap + z elseif imag(z) < -.5 z = c/tip + temp/tap - z elseif real(z) >.1 z = c/tip - temp/tap + z elseif imag(z) < -.1 z = c/tip + temp/tap - z elseif real(z) > -.1 z = c/tip - temp/tap + z elseif imag(z) < .1 z = c/tip + temp/tap - z elseif real(z) > -.5 z = c/tip - temp/tap + z elseif imag(z) < .5 z = c/tip + temp/tap - z else z = c/tip - temp/tap + z endif endif ca = z*c if @MoreReal == true if real(z)<@bs z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.1)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.2)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.3)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.4)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.5)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.6)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.7)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.8)) z = fn1(z - 1) elseif real(z)<(@bs-(@bs*.9)) z = fn1(z - 1) elseif real(z)<=0 z = fn1(z + 1) elseif real(z)<((@bs*.9)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.8)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.7)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.6)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.5)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.4)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.3)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.2)-@bs) z = fn1(z + 1) elseif real(z)<((@bs*.1)-@bs) z = fn1(z + 1) elseif real(z)<(@bs*(-1)) z = fn1(z + 1) else z = fn1(z - 1) endif if imag(z)<@bs z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.1)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.2)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.3)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.4)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.5)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.6)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.7)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.8)) z = fn1(z - 1) elseif imag(z)<(@bs-(@bs*.9)) z = fn1(z - 1) elseif imag(z)<=0 z = fn1(z + 1) elseif imag(z)<((@bs*.9)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.8)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.7)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.6)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.5)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.4)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.3)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.2)-@bs) z = fn1(z + 1) elseif imag(z)<((@bs*.1)-@bs) z = fn1(z + 1) elseif imag(z)<(@bs*(-1)) z = fn1(z + 1) else z = fn1(z - 1) endif endif if @gnarl == true iter = iter + 1 xx = x x = x - @h * real(fn1(y + fn2(@a * (y + fn3(@b * y-z)))))*(z) y = y + @h * real(fn1(xx + fn2(@a * (xx + fn3(@b * xx/z)))))*abs(#z) z = x + flip(y) endif bailout: |z|<@bailout default: title="General Tent Julia - kp" helpfile="lkm-help\lkm-tent.html" maxiter=100 periodicity=0 center=(-1.5,-1.1) magn=.45 angle=0 bool param gnarl caption = "Gnarl?" default = false endparam param a caption = "Alpha" default = (2.7,0.0) visible = @gnarl == true endparam param b caption = "Beta" default = (2.7,0.0) visible = @gnarl == true endparam param c caption = "Cappa" default = (0.0,0.0) visible = @gnarl == true endparam param h caption = "Step size" default = (0.1,0.0) visible = @gnarl == true endparam param s caption = "Scale" default = (1.0,0.0) visible = @gnarl == true endparam param julparam caption="Julia parameter" default=(0.755952,1.011905) endparam param bailout caption="bailout" default=1000. endparam param rtype caption="r type" default=0 enum="magnitude" "real part" "imag part" "real*imag" "imag/real" hint="Determines the r value used in the tent map." endparam param rottype caption="rotation type" default=2 enum="none" "constant" "progressive" "oscillating" hint="In 'constant' mode, the same angle is used every iteration. \ In 'progressive' mode, the angle is increased by the amount every \ iteration. In 'oscillating' mode, the map is rotated forward, then \ back, then forward, etc." endparam param rotamount caption="rotation amount" default=60.0 hint="How much the map is rotated." endparam param rotunit caption="rotation units" default=0 enum="degrees" "radians" hint="Units in which the rotation is expressed." endparam param reality caption = "Reality play" enum = "none" "Option 1" "Option 2" "Option 3" "Option 4" "Option 5" "Option 6" "Option 7" "Option 8" "Option 9" "Option 10" "Option 11" "Option 12" default = 0 endparam param reazs caption = "Real/Imag" default = false visible = @reality >= 1 endparam param rsf caption = "Reality Seeds" default = 0.6 visible = @reazs == false && @reality >= 1 endparam param rpf caption = "Reality Power" default = 1.0 visible = @reazs == false && @reality >= 1 endparam param rs caption = "Reality Seeds" default = (0.6,0.1) visible = @reazs == true endparam param rp caption = "Reality Power" default = (1.0,0.1) visible = @reazs == true endparam bool param MoreReal caption = "Even More Real" default = false endparam param bs caption = "Bind Size" default = (-.05556,0.0) visible = @MoreReal == true endparam func fn1 caption="Function 1" default= ident() endfunc func fn2 caption="Function 2" default= ident() endfunc func fn3 caption="Function 3" default= ident() endfunc func fn4 caption="Function 4" default= ident() endfunc func fn5 caption="Function 5" default= ident() endfunc func fn6 caption="Function 6" default= ident() endfunc bool param prefun caption = "Pre Functions?" default = false endparam func pfn1 caption="Pre-Function 1" default= cos() visible = @prefun == true endfunc func pfn2 caption="Pre-Function 2" default= flip() visible = @prefun == true endfunc func pfn3 caption="Pre-Function 3" default= sin() visible = @prefun == true endfunc param juliaplus caption = "Add Julia" enum = "No" "1" "2" default = 2 endparam param jpp1_ins caption = "Julia Plus INS" enum = "+" "-" "*" "/" "^" default = 0 visible = @juliaplus == 1 || @juliaplus == 2 endparam param jpp1 caption = "Julia Power 1" default = (1.0,0.0) visible = @juliaplus == 1 || @juliaplus == 2 endparam param jpp2_ins caption = "Julia Plus 2 INS" enum = "+" "-" "*" "/" "^" default = 1 visible = @juliaplus == 2 endparam param jpp2 caption = "Julia Power 2" default = (1.0,0.0) visible = @juliaplus == 2 endparam switch: type="general-tent-mandelbrot" bailout=bailout rtype=rtype rottype=rottype rotamount=rotamount rotunit=rotunit } SpaceTime { init: z = #pixel loop: ;----------A---------- a1 = fn1(z^@power) a2 = @seed^@power2 a3 = fn2(@time^@power3) a4 = a2 * a3 a = (a1 - a4)/@r ;---------B----------- b1 = @time^@power3 b2 = fn3(z^@power) b3 = @seed^@power2 b4 = b2/b3 b = fn4(b1 - b4)/@r ;----------z---------- z = (@fn6(a) + @j * @fn5(b))/@r bailout: |z| <= @bailout default: title = "SpaceTime" heading caption = "Paramaters" endheading param r caption = "Relations" default = (1.0, 0.0) endparam param j caption = "Other Relations" default = (.760952,-.161357) endparam param seed caption = "Seed" default = (-1.25,0) endparam param time caption = "Time" default = (1.239048,.719119) endparam heading caption = "Powers" endheading param power caption = "Power" default = (2,0) endparam param power2 caption = "Power" default = (2,0) endparam param power3 caption = "Power" default = (2,0) endparam heading caption = "Functions" endheading func fn1 caption="Function 1" default= sinh() endfunc func fn2 caption="Function 2" default= sinh() endfunc func fn3 caption="Function 3" default= cosh() endfunc func fn4 caption="Function 4" default= sqrt() endfunc func fn5 caption="Function 5" default= sinh() endfunc func fn6 caption="Function 6" default= cosh() endfunc heading caption = "bailout" endheading param bailout caption = "Bailout value" default = 4.0 min = 1.0 endparam switch: type = "Mandelbrot" power = power bailout = bailout } Jokie { init: ;-----Gnarl------- p = #pixel / @s complex x = real(p) complex y = imag(p) complex xx = 0 complex iter = 0 loop: if @ins_1 == 0 ;+-*/^ z = (z^@power-@seed)/@detail elseif @ins_1 == 1 z = (z^@power+@seed)/@detail elseif @ins_1 == 2 z = (z^@power*@seed)/@detail elseif @ins_1 == 3 z = (z^@power/@seed)/@detail elseif @ins_1 == 4 z = (z^@power^@seed)/@detail endif k = @a/@seed k1 = @b/@seed iter = iter + 1 xx = x x = x - @h * real(fn1(y + fn2(@a * (y + fn3(k * y-#z)))))*(#z) y = y + @h * real(fn1(xx + fn2(@a * (xx + fn3(@b * xx/#z)))))*abs(#z) if @ins_3 == 0 ;+-*/^ z = x + fn4(y) elseif @ins_3 == 1 z = x - fn4(y) elseif @ins_3 == 2 z = x * fn4(y) elseif @ins_3 == 3 z = x / fn4(y) elseif @ins_3 == 4 z = x ^ fn4(y) endif if @ins_2 == 0 ;+-*/^ z = (z^@power-@seed)/@detail elseif @ins_2 == 1 z = (z^@power+@seed)/@detail elseif @ins_2 == 2 z = (z^@power*@seed)/@detail elseif @ins_2 == 3 z = (z^@power/@seed)/@detail elseif @ins_2 == 4 z = (z^@power^@seed)/@detail endif bailout: |z| <= @bailout default: title = "Jokies" Heading caption = "Gnarl" endheading param ins_3 caption = "Final INS" enum = "+" "-" "*" "/" "^" default = 2 endparam param a caption = "Alpha" default = (2.7,0.0) endparam param b caption = "Beta" default = (2.7,0.0) endparam param c caption = "Cappa" default = (0.0,0.0) endparam param h caption = "Step size" default = (0.1,0.0) endparam param s caption = "Scale" default = (1.0,0.0) endparam heading caption = "Paramaters" endheading param ins_1 caption = "Julia 1" enum = "+" "-" "*" "/" "^" default = 0 endparam param ins_2 caption = "Julia 2" enum = "+" "-" "*" "/" "^" default = 1 endparam param power caption = "Power" default = (2.0, 0.0) endparam param seed caption = "Seed" default = (-1.25,0) endparam param detail caption = "Details" default = (1.0,0.0) endparam heading caption = "Functions" endheading func fn1 caption="Function 1" default= sin() endfunc func fn2 caption="Function 2" default= sin() endfunc func fn3 caption="Function 3" default= sin() endfunc func fn4 caption="Function 4" default= ident() endfunc heading caption = "bailout" endheading param bailout caption = "Bailout value" default = 4.0 min = 1.0 endparam switch: type = "Mandelbrot" power = power bailout = bailout } WooJulia { init: z = #pixel loop: if @ains == 0 ;+ a = fn1(z^(@power/@in)) + fn2(@seed/@in) elseif @ains == 1 ;- a = fn1(z^(@power/@in)) - fn2(@seed/@in) elseif @ains == 2 ;* a = fn1(z^(@power/@in)) * fn2(@seed/@in) elseif @ains == 3 ;/ a = fn1(z^(@power/@in)) / fn2(@seed/@in) elseif @ains == 4 ;^ a = fn1(z^(@power/@in)) ^ fn2(@seed/@in) endif if @bins == 0 ;+ b = fn3(z^(@power2/@in)) + fn4(@seed2/@in) elseif @bins == 1 ;- b = fn3(z^(@power2/@in)) - fn4(@seed2/@in) elseif @bins == 2 ;* b = fn3(z^(@power2/@in)) * fn4(@seed2/@in) elseif @bins == 3 ;/ b = fn3(z^(@power2/@in)) / fn4(@seed2/@in) elseif @bins == 4 ;^ b = fn3(z^(@power2/@in)) ^ fn4(@seed2/@in) endif if @insflip == false if @zins == 0 ;+ z = (a/@i) + (b/@i) elseif @zins == 1 ;- z = (a/@i) - (b/@i) elseif @zins == 2 ;* z = (a/@i) * (b/@i) elseif @zins == 3 ;/ z = (a/@i) / (b/@i) elseif @zins == 4 ;^ z = (a/@i)^(b/@i) endif else if @zins == 0 ;+ z = (b/@i) + (a/@i) elseif @zins == 1 ;- z = (b/@i) - (a/@i) elseif @zins == 2 ;* z = (b/@i) * (a/@i) elseif @zins == 3 ;/ z = (b/@i) / (a/@i) elseif @zins == 4 ;^ z = (b/@i) ^ (a/@i) endif endif z = z/@detail bailout: |z| <= @bailout default: title = "Wooo Julia" $IFDEF VER50 rating = recommended $ENDIF heading caption = "Choices" endheading Param ains caption = "A +-*/^" default = 3 enum = "+" "-" "*" "/" "^" endparam Param bins caption = "b +-*/^" default = 0 enum = "+" "-" "*" "/" "^" endparam Param zins caption = "Z +-*/^" default = 1 enum = "+" "-" "*" "/" "^" endparam bool param insflip caption = "Flip A & B" default = true endparam heading Caption = "A" endheading func fn1 caption="A Power" default= ident() endfunc Param Power caption = "A Power" default = (2.0,0.0) endparam func fn2 caption="A Seed" default= tanh() endfunc Param Seed caption = "A Seed" default = (-0.01181,0.54981) endparam heading caption = "B" endheading func fn3 caption="B Power" default= ident() endfunc Param Power2 caption = "B Power" default = (-0.10362,-0.33466) endparam func fn4 caption="B Seed" default= ident() endfunc Param Seed2 caption = "B Seed" default = (-1.27876,0.35857) endparam heading caption = "Other Values" endheading Param in caption = "Small Details" default = (1.131476,-0.116536) endparam Param i caption = "Internal Details" default = (1.791843,-1.338667) endparam Param detail caption = "External Details" default = (0.931273,0.059766) endparam param bailout caption = "Bailout" default = 3.0 min = 1.0 endparam switch: type = "Mandelbrot" power = power bailout = bailout } WooJulia2 { init: z = #pixel loop: if @ains == 0 ;+ a = fn1(z^(@power/@ainp)) + fn2(@seed/@ainse) elseif @ains == 1 ;- a = fn1(z^(@power/@ainp)) - fn2(@seed/@ainse) elseif @ains == 2 ;* a = fn1(z^(@power/@ainp)) * fn2(@seed/@ainse) elseif @ains == 3 ;/ a = fn1(z^(@power/@ainp)) / fn2(@seed/@ainse) elseif @ains == 4 ;^ a = fn1(z^(@power/@ainp)) ^ fn2(@seed/@ainse) endif if @bins == 0 ;+ b = fn3(z^(@power2/@binp)) + fn4(@seed2/@binse) elseif @bins == 1 ;- b = fn3(z^(@power2/@binp)) - fn4(@seed2/@binse) elseif @bins == 2 ;* b = fn3(z^(@power2/@binp)) * fn4(@seed2/@binse) elseif @bins == 3 ;/ b = fn3(z^(@power2/@binp)) / fn4(@seed2/@binse) elseif @bins == 4 ;^ b = fn3(z^(@power2/@binp)) ^ fn4(@seed2/@binse) endif if @insflip == false if @zins == 0 ;+ z = (a/@ia) + (b/@ib) elseif @zins == 1 ;- z = (a/@ia) - (b/@ib) elseif @zins == 2 ;* z = (a/@ia) * (b/@ib) elseif @zins == 3 ;/ z = (a/@ia) / (b/@ib) elseif @zins == 4 ;^ z = (a/@ia)^(b/@ib) endif else if @zins == 0 ;+ z = (b/@ib) + (a/@ia) elseif @zins == 1 ;- z = (b/@ib) - (a/@ia) elseif @zins == 2 ;* z = (b/@ib) * (a/@ia) elseif @zins == 3 ;/ z = (b/@ib) / (a/@ia) elseif @zins == 4 ;^ z = (b/@ib) ^ (a/@ia) endif endif z = z/@detail bailout: |z| <= @bailout default: title = "Extra Wooo Julia " $IFDEF VER50 rating = recommended $ENDIF heading caption = "Choices" endheading Param ains caption = "A +-*/^" default = 3 enum = "+" "-" "*" "/" "^" endparam Param bins caption = "b +-*/^" default = 0 enum = "+" "-" "*" "/" "^" endparam Param zins caption = "Z +-*/^" default = 1 enum = "+" "-" "*" "/" "^" endparam bool param insflip caption = "Flip A & B" default = true endparam heading Caption = "A" endheading func fn1 caption="A Power" default= ident() endfunc Param Power caption = "A Power" default = (2.0,0.0) endparam func fn2 caption="A Seed" default= tanh() endfunc Param Seed caption = "A Seed" default = (-0.01181,0.54981) endparam heading caption = "A Details" endheading Param ainp caption = "A Power Details" default = (1.0,0.0) endparam Param ainse caption = "A Seed Details" default = (1.0,0.0) endparam Param ia caption = "A Internal Details" default = (1.791843,-1.338667) endparam heading caption = "B" endheading func fn3 caption="B Power" default= ident() endfunc Param Power2 caption = "B Power" default = (-0.10362,-0.33466) endparam func fn4 caption="B Seed" default= ident() endfunc Param Seed2 caption = "B Seed" default = (-1.27876,0.35857) endparam heading caption = "B Details" endheading Param binp caption = "B Power Details" default = (1.0,0.0) endparam Param binse caption = "B Seed Details" default = (1.0,0.0) endparam Param ib caption = "B Internal Details" default = (1.791843,-1.338667) endparam heading caption = "Final Values" endheading Param detail caption = "External Details" default = (0.931273,0.059766) endparam param bailout caption = "Bailout" default = 3.0 min = 1.0 endparam switch: type = "Mandelbrot" power = power bailout = bailout }