pattern touch ups
This commit is contained in:
parent
1f01d02473
commit
e6cb5793e9
1 changed files with 2 additions and 14 deletions
|
@ -1,21 +1,17 @@
|
||||||
# 2019.03.14 -> 2022.10.06 ->
|
# 2019.03.14 -> 2022.10.06 ->
|
||||||
|
|
||||||
# deprecated format
|
# deprecated format
|
||||||
# // spatial culling shader code
|
# // signed distance field compositing
|
||||||
#
|
# // *spatial culling shader code
|
||||||
# _matrix = Matrix.TR(oriel.pos, oriel.rot)
|
# _matrix = Matrix.TR(oriel.pos, oriel.rot)
|
||||||
# _dim = oriel.dimensions
|
# _dim = oriel.dimensions
|
||||||
# MAX_STEPS = 256±
|
# MAX_STEPS = 256±
|
||||||
# MAX_DIST = 100±
|
# MAX_DIST = 100±
|
||||||
#
|
|
||||||
# BoxSD(pos, dim):
|
# BoxSD(pos, dim):
|
||||||
# q = abs(pos) - dim
|
# q = abs(pos) - dim
|
||||||
# step = length(max(q, 0.0))
|
# step = length(max(q, 0.0))
|
||||||
# step += min(max(q.x, max(q.y, q.z)), 0.0)
|
# step += min(max(q.x, max(q.y, q.z)), 0.0)
|
||||||
#
|
|
||||||
# return step
|
# return step
|
||||||
#
|
|
||||||
#
|
|
||||||
# Raymarch(origin, dir):
|
# Raymarch(origin, dir):
|
||||||
# origin = mul(origin, _matrix)
|
# origin = mul(origin, _matrix)
|
||||||
# dir = mul(dir, _matrix)
|
# dir = mul(dir, _matrix)
|
||||||
|
@ -26,25 +22,17 @@
|
||||||
# if (step < 0.0001 or dist > MAX_DIST):
|
# if (step < 0.0001 or dist > MAX_DIST):
|
||||||
# then break loop
|
# then break loop
|
||||||
# dist += step
|
# dist += step
|
||||||
#
|
|
||||||
# return dist
|
# return dist
|
||||||
#
|
|
||||||
#
|
|
||||||
# YourPixelShader():
|
# YourPixelShader():
|
||||||
# pos = pixel.worldposition
|
# pos = pixel.worldposition
|
||||||
# dir = normalize(pos - cam)
|
# dir = normalize(pos - cam)
|
||||||
#
|
|
||||||
# // cull around
|
# // cull around
|
||||||
# dist = Raymarch(cam, dir)
|
# dist = Raymarch(cam, dir)
|
||||||
# clip(100 - (dist + 1))
|
# clip(100 - (dist + 1))
|
||||||
#
|
|
||||||
# // cull between
|
# // cull between
|
||||||
# oriel = cam + dist * dir
|
# oriel = cam + dist * dir
|
||||||
# clip(dist(cam, pos) - dist(cam, oriel))
|
# clip(dist(cam, pos) - dist(cam, oriel))
|
||||||
#
|
|
||||||
# ...
|
# ...
|
||||||
#
|
|
||||||
#
|
|
||||||
|
|
||||||
# new format *TODO
|
# new format *TODO
|
||||||
input
|
input
|
||||||
|
|
Loading…
Add table
Reference in a new issue