最美情侣中文字幕电影,在线麻豆精品传媒,在线网站高清黄,久久黄色视频

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

SuperDetail: SDF Terrain,optimize

2022-06-04 09:43 作者:DeadCyber  | 我要投稿

Result:

Tech Detail

In my old article,we explored the possibility of make terrain out of SDF trace:

It's time to add detail to the terrain.I use i.q.'s fbm?3d noise tech.I've wrote about that in my CSDN blog,so I won't go into any further detail about fbm? 3d noise itself.

H(x%2Cy)%2B%3Dk*FBM3DNoise%20

My CSDN article:?

https://blog.csdn.net/qq_41524721/article/details/122428279?spm=1001.2014.3001.5501

? ? Here,the detail I want to show you is the problem and resolution of combine fbm 3d noise to SDF Terrain.Like my last article?《Fix SDF Instance Issue》,i.q.'s methods are great but have flaws when you have a dynamic view and flexible combination of SDF Objects.

Problem

????First,we have to realize that?when fbm 3d noise don't work too well with SDF's terrain formula:

i.q.'s%20TerrainSDFstep%3Ad%20%3D%200.5*abs(H(x%2Cy)-p)? ??

It gives us strange shapes when we add fbm 3d noise with a big k in formula 1?to the basic terrain formula:

Notice the strange circle and strange transfer area in the pic above.They come from the error when we calculate the SDF of the fbm 3d noise.The mathematical reason for?the error is similar to the problem when Displacement Map has?a high displacement value.

? ? Again,we can increase our trace acurracy to solve the problem,but as?k increase in formula 1,we need more traces to solve the issue,finally the computational complexity is gonna blow.

????"If you can't deal with it, drop it."

????However,fbm?3d noise with small k apply to SDF terrain is acceptable,? just like normal map or displacement map, but with actual shape, this allows SuperDetail for terrain shape and SDF shadow quality.Since we don't need big k for terrain detail, problem ?solved.

Optimize: SDF LOD

????The cost is still heavy,because we have so many other things beside terrain to render.The main reason for the cost is the essential behavior of SDF Trace.For every step we trace,we have to calculate the object's SDF formula;for near,small?object,it's ok.But for something big,and many pixel so far away from camera,the steps of SDF Trace is very big,but necessary if we want a 'perfect' accurate render.

????


? ? Since we can't resuce the steps of SDF Trace,we can reduce the chances we calculate the fbm 3d noise.

????We add the terrain detail to the terrrain only when the trace point is very close to the terrain surface:

????

????This reduces a lot fbm 3d calculations! What's more import, it doesn't affect the accuracy at all! Because our detail k is so small, it doesn't affect the Terrain's SDF at long distance, so we don't get wrong SDF result.

????This kind of 'SDF LOD' is so great.It doesn't change accuracy,it doesn't give a discontinous feeling when you get too far or too close.It gives you the super detail even when the pixel is very far, you can feel it in img 1,img?2.

????This 'LOD' works at all situations.Think about the situation when we hit 'near range' twice:


The small 'rock' in the middle distance is actually blocking the result from far distance.This is totally correct.

SuperDetail: SDF Terrain,optimize的評(píng)論 (共 條)

分享到微博請(qǐng)遵守國(guó)家法律
龙海市| 保亭| 常熟市| 密云县| 三门峡市| 普宁市| 全州县| 横山县| 朝阳市| 桦川县| 治县。| 贞丰县| 云南省| 永昌县| 元谋县| 武陟县| 德清县| 五大连池市| 灌云县| 河东区| 五家渠市| 洪江市| 烟台市| 沧源| 阳山县| 高密市| 阳江市| 双辽市| 大丰市| 环江| 永兴县| 普兰店市| 象州县| 四平市| 时尚| 阿拉尔市| 福贡县| 界首市| 正安县| 海兴县| 湘潭县|