返回列表 回复 发帖

UF分形的画板实现5(obsolete.ufm系列)

未命名.JPG

MandelPaper.gsp (14.77 KB)

代码如下:
MandelPaper {
; Ron Barnett, December 1998
; To use this as a tiler, use the aspect ratio transformation
; Set the aspect ratio to 1.0
; This is based on an old fractint tiler of Ray Girvan's
init:
   #z=(@fn1(@fn2(real(#pixel)))+flip(@fn1(@fn2(imag(#pixel)))))/@p2
loop:
   #z = #z*#z + @p3
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 = "Mandel Paper"
  maxiter = 1000
  center = (0, 0)
  periodicity = 0
  magn = 0.477465

  param test
    caption = "Bailout Test"
    default = 0
    enum = "mod" "real" "imag" "or" "and" "manh" "manr"
  endparam
  param p2
     caption = "Zoom"
     default = 2.0
  endparam
  param p3
     caption = "Seed"
     default = (-0.7625, 0.3)
  endparam
  param bailout
    caption = "Bailout value"
    default = 4.0
  endparam
  func fn1
     caption = "First Function"
     default = tan()
  endfunc
  func fn2
     caption = "Second Function"
     default = sin()
  endfunc
}
改变逃逸参数,再扫一图:
未命名2.JPG
MandelPaper(2).gsp (15.76 KB)
不错,几何画板的效果图比UF更好看。
再扫二图:
未命名a.JPG
未命名1.JPG
我还是比较喜欢有小宝贝的REB004H:

捕获512.JPG (65.54 KB)

捕获512.JPG

柳老师的这组分形用于布料上,搞成碎花儿水印效果,一定很时尚。
7# xiaongxp
说得不错。
IckyPaper {
; Ron Barnett, December 1998
; To use this as a tiler, use the aspect ratio transformation
; Set the aspect ratio to 1.0
; This is based on an old fractint tiler of Ray Girvan's
init:
   #z=(@fn1(@fn2(real(#pixel)))+flip(@fn1(@fn2(imag(#pixel)))))/@p2
loop:
   #z = #z*#z*#z + (@p3-1)*#z - @p3
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 = "Icky Paper"
  maxiter = 1000
  center = (0, 0)
  periodicity = 0
  magn = 0.477465

  param test
    caption = "Bailout Test"
    default = 0
    enum = "mod" "real" "imag" "or" "and" "manh" "manr"
  endparam
  param p2
     caption = "Zoom"
     default = 10.0
  endparam
  param p3
     caption = "Seed"
     default = (0.025, 0.275)
  endparam
  param bailout
    caption = "Bailout value"
    default = 4.0
  endparam
  func fn1
     caption = "First Function"
     default = tan()
  endfunc
  func fn2
     caption = "Second Function"
     default = sin()
  endfunc
}

未命名.JPG
IckyPaper.gsp (18.96 KB)
TiledNewton {
; Ron Barnett, December 1998
; To use this as a tiler, use the aspect ratio transformation
; Set the aspect ratio to 1.0
; This is based on an old fractint tiler of Ray Girvan's
init:
   complex pwr = @p1 - 1.0
   complex npwr = -@p1
   complex rpwr = pwr/@p1
   complex rrt = @p2/@p1
   float pwrtest = 10^(100/cabs(@p1))
   bool bTest = false
   float isnear = @p3*cabs(@p2)^cabs(@p1)
   #z=(@fn1(@fn2(real(#pixel)))+flip(@fn1(@fn2(imag(#pixel)))))/@p4
   complex oldz = 0
loop:
  oldz = #z
  z1 = rrt*#z^npwr
  z = #z*(rpwr + z1)
  btest = (cabs(oldz-#z) < isnear)
bailout:
  !btest && (cabs(z) < pwrtest)
default:
  title = "Tiled Newton"
  center = (0.0, 0.0)
  maxiter = 1000
  periodicity = 0
  magn = 0.477465

  param p1
    caption = "Power"
    default = (3,0)
  endparam

  param p2
    caption = "Root"
    default = (1,0)
  endparam

  param p3
    caption = "Bailout value"
    default = 1e-12
    max = 0.1
  endparam
  param p4
     caption = "Zoom"
     default = 2.0
  endparam
  func fn1
     caption = "First Function"
     default = tan()
  endfunc
  func fn2
     caption = "Second Function"
     default = sin()
  endfunc
}
未命名1.JPG
TiledNewton.gsp (21.61 KB)
返回列表