updated tiled squares and split interest, added arcsech to ulstrip & wtf

master
Crystalize 2 years ago
parent 4f23e47905
commit b4552dc5df
  1. 19
      linkA_split_interest.xml
  2. 8
      linkB_ultra_strip.xml
  3. 21
      linkX_tiled_squares.xml
  4. 8
      linkX_what_the_fill.xml

@ -5,19 +5,23 @@
<real name="split_interest" minval="0.0">1</real>
<real name="split_interest_split">0</real>
<real name="split_interest_spread">0</real>
<real name="split_interest_symmetry_type" minval="0.0" maxval="0.05">0</real>
<real name="split_interest_interest_type" minval="0.0" maxval="0.05">0</real>
</node>
<node name="internal_params">
<real name="weight" />
<real name="split" />
<real name="spread" />
<real name="syty" />
<real name="inty" />
</node>
<int name="num_unit_randoms">2</int>
<string name="winter_init_function">
<![CDATA[
linkA_split_interest_init_result(split_interest, split_interest_split, split_interest * (split_interest_spread + 2))
linkA_split_interest_init_result(split_interest, split_interest_split, split_interest * (split_interest_spread + 2), split_interest_symmetry_type, split_interest_interest_type)
]]>
</string>
@ -31,12 +35,19 @@
a = (atan2(p_in.y, x_less_weight) - atan2(p_in.y, x_plus_weight)) * 0.5
r = spread * sqrt(sqrt(num / den))
fluxa = vec2(cos(a), sin(a)) * r
fluxb = vec2(-cos(a), sin(a)) * r
fluxb = vec2(-cos(a), if syty == 0.0 then -sin(a) else sin(a)) * r
rflux = lerp(fluxa, fluxb, if unit_rnd_0 >= 0.5 then 1.0 else 0.0)
x_offset = if rflux.x >= 0 then split else -split
d = dot(p_in,p_in)
r_avg = weight * sqrt(1 + 4 * p_in.x / (d - 2 * p_in.x + 1))
a_avg = 0.5 * atan2(2 * p_in.y, (d - 1))
deltaa = vec2(cos(a_avg), sin(a_avg)) * r_avg
deltab = vec2(-cos(a_avg), if syty == 0.0 then -sin(a_avg) else sin(a_avg)) * r_avg
rdelta = lerp(deltaa, deltab, if unit_rnd_0 >= 0.5 then 1.0 else 0.0)
x_offset = if (if inty == 0.0 then rflux.x else rdelta.x) >= 0 then split else -split
in
rflux + vec2(x_offset, 0.0)
(if inty == 0.0 then rflux else rdelta) + vec2(x_offset, 0.0)
]]>
</string>
</transform_def>

@ -8,7 +8,7 @@
<real name="ultra_strip_cyl_blur_strength">1</real>
<real name="ultra_strip_inside_rotate">2</real>
<real name="ultra_strip_inside_size">1</real>
<real name="ultra_strip_inside_switch" minval="0.0" maxval="0.05">0</real>
<real name="ultra_strip_inside_switch" minval="0.0" maxval="1.0">0</real>
<real name="ultra_strip_inside_strength" minval="0.5">1</real>
<real name="ultra_strip_inner_weight" minval="0.0" maxval="1.0">0.99</real>
</node>
@ -25,7 +25,7 @@
<real name="iw2" />
</node>
<int name="num_unit_randoms">6</int>
<int name="num_unit_randoms">7</int>
<int name="num_gauss_randoms">1</int>
<string name="winter_init_function">
@ -45,10 +45,12 @@
sin(atr), cos(atr))
atin = rotm * p_in
z = complex(atin.x * size, atin.y * size)
z1 = 1.0 / z
resulta = halfinvpi() * log((z + 1.0) / (-z + 1.0))
resultb = invpi() * log(z + sqrt(z * z + 1.0))
resultc = halfinvpi() * log(z1 + sqrt(z1 + 1.0) * sqrt(z1 - 1.0))
result = if iswitch == 0.0 then resulta else resultb
at_out = vec2(result.im, result.re)
at_out = if iswitch == 1.0 then lerp(vec2(resultc.im, resultc.re), vec2(-resultc.im, -resultc.re), if unit_rnd_6 <= 0.5 then 0.0 else 1.0) else vec2(result.im, result.re)
catx = clamp(at_out.x, -0.5, 0.5)
caty = clamp(at_out.y, -0.5, 0.5)
log_out = vec2(caty, catx + floor(log(unit_rnd_0) * (if unit_rnd_1 < 0.5

@ -4,9 +4,9 @@
<node name="input_params">
<real name="tiled_squares">1</real>
<real name="tiled_squares_inside_rotate">0</real>
<real name="tiled_squares_inside_size">0</real>
<real name="tiled_squares_inside_switch" minval="0" maxval="0.05">0</real>
<real name="tiled_squares_tile_strength" minval="0.5">0</real>
<real name="tiled_squares_inside_size">1</real>
<real name="tiled_squares_inside_switch" minval="0" maxval="1">0</real>
<real name="tiled_squares_tile_strength" minval="0.5">0.5</real>
</node>
<node name="internal_params">
@ -28,15 +28,16 @@
<string name="winter_eval_function">
<![CDATA[
let
rotm = mat2x2(
cos(atr), -sin(atr),
sin(atr), cos(atr))
atin = rotm * p_in
z = complex(atin.x * size, atin.y * size)
rotm = mat2x2(cos(atr), -sin(atr),
sin(atr), cos(atr))
atin = rotm * (p_in * size)
z = complex(atin.x, atin.y)
result = (halfinvpi()) * log((z + 1.0) / (-z + 1.0))
at_out = vec2(result.im, result.re)
catx = clamp(if iswitch == 0 then p_in.y else at_out.x, -0.5, 0.5)
caty = clamp(if iswitch == 0 then p_in.x else at_out.y, -0.5, 0.5)
result2 = (invpi()) * log(z + sqrt(z * z + 1.0))
as_out = vec2(result2.im, result2.re)
catx = clamp(if iswitch == 0 then atin.x else if iswitch == 1.0 then as_out.x else at_out.x, -0.5, 0.5)
caty = clamp(if iswitch == 0 then atin.y else if iswitch == 1.0 then as_out.y else at_out.y, -0.5, 0.5)
log_out1 = vec2(caty, catx + floor(log(unit_rnd_0) * (if unit_rnd_1 < 0.5
then strength
else -strength) + 0.5))

@ -8,7 +8,7 @@
<real name="what_the_fill_cyl_blur_strength">1</real>
<real name="what_the_fill_inside_rotate">2</real>
<real name="what_the_fill_inside_size">1</real>
<real name="what_the_fill_inside_switch" minval="0.0" maxval="0.05">0</real>
<real name="what_the_fill_inside_switch" minval="0.0" maxval="1.0">0</real>
<real name="what_the_fill_inside_strength" minval="0.5">1</real>
<real name="what_the_fill_outside_switch" minval="0.0" maxval="0.005">0</real>
<real name="what_the_fill_inner_weight1" minval="0.0" maxval="1.0">0.9</real>
@ -29,7 +29,7 @@
<real name="iw2" />
</node>
<int name="num_unit_randoms">6</int>
<int name="num_unit_randoms">7</int>
<int name="num_gauss_randoms">1</int>
<string name="winter_init_function">
@ -50,10 +50,12 @@
sin(atr), cos(atr))
atin = rotm * p_in
z = complex(atin.x * size, atin.y * size)
z1 = 1.0 / z
resulta = halfinvpi() * log((z + 1.0) / (-z + 1.0))
resultb = invpi() * log(z + sqrt(z * z + 1.0))
resultc = halfinvpi() * log(z1 + sqrt(z1 + 1.0) * sqrt(z1 - 1.0))
result = if iswitch == 0.0 then resulta else resultb
at_out = vec2(result.im, result.re)
at_out = if iswitch == 1.0 then lerp(vec2(resultc.im, resultc.re), vec2(-resultc.im, -resultc.re), if unit_rnd_6 <= 0.5 then 0.0 else 1.0) else vec2(result.im, result.re)
catx = clamp(at_out.x, -0.5, 0.5)
caty = clamp(at_out.y, -0.5, 0.5)
log_out = vec2(caty, catx + floor(log(unit_rnd_0) * (if unit_rnd_1 < 0.5

Loading…
Cancel
Save