如果将PerspectiveMode的设置为1,则会传递zNear和Zfar,在fixDepth()中,
而将perspectiveMode = 0,则大大简化fixDepth()
"float fixDepth(float depth)"
"{ "
" return clamp(1.0 - depth, 0.0, 1.0); "
"}
效果也没有影响

当PerspectiveMode设为1时,fixDepth函数会考虑zNear和Zfar参数,进行深度处理;而当设置为0时,fixDepth被简化为对深度值的直接clamping操作,不影响返回值。这种变化不影响最终效果。
如果将PerspectiveMode的设置为1,则会传递zNear和Zfar,在fixDepth()中,
而将perspectiveMode = 0,则大大简化fixDepth()
"float fixDepth(float depth)"
"{ "
" return clamp(1.0 - depth, 0.0, 1.0); "
"}
效果也没有影响

161
1274
1000
970

被折叠的 条评论
为什么被折叠?
