UE5.1_Niagara高級(jí)3.7_ Plexus
3.7 Plexus【網(wǎng)狀結(jié)構(gòu)】
Spatial Particle Sort GPU【空間粒子排序GPU】模組
需要取消Library Only才能看到。因?yàn)槟=M用到粒子ID,所以要勾選Requires Persistent IDs【需要永久ID】
1:查詢27個(gè)相鄰網(wǎng)格單元格里的相鄰粒子,并進(jìn)行重疊模糊因子判斷。
2:計(jì)算angleAlignment【角度對(duì)齊】=粒子自身指向相鄰粒子的單位向量點(diǎn)乘SearchVector
3:計(jì)算angleFit【角度匹配】=(angleAlignment+AngleForgiveness)/(1+ AngleForgiveness)
4:計(jì)算overlapFit【重疊匹配】=(重疊距離+重疊模糊因子的絕對(duì)值)/重疊模糊因子的絕對(duì)值
5:限制overlapFit【重疊匹配】取值范圍=0到1
6:計(jì)算BestFitScore【最匹配得分】=angleFit*AngleWeight+overlapFit*ProximityWeight。
7:根據(jù)BestFitScore【最匹配得分】排序,按順序保存得分最高的3個(gè)相鄰粒子的ID,為空時(shí)保存自身ID
8:輸出保存的這三個(gè)粒子ID,和對(duì)應(yīng)ID is Valid【原本是否為空】的布爾值,以及Number Of Valid Results【原本不為空的ID的個(gè)數(shù)】
CollisionRadius【碰撞半徑】:主要影響【重疊匹配】,兩粒子重疊時(shí)【重疊匹配】=1
NeighborGrid【相鄰網(wǎng)格3D變量】
ParticleAttributeReader【粒子屬性讀取器】
Position【粒子位置】
SimulationToUnit【模擬到單位】
AngleForgiveness【角度偏差】:角度偏差越大,角度影響越小
AngleWeight【角度權(quán)重】:數(shù)值比【近距權(quán)重】越大,角度影響越大
OverlapFudgeFactor【重疊模糊因子】:重疊距離>重疊模糊因子時(shí),才會(huì)進(jìn)一步計(jì)算該相鄰粒子。重疊距離=兩粒子碰撞半徑之和-兩粒子間的距離??梢岳斫鉃椴檎揖嚯x最大值,一般設(shè)置為負(fù)值,數(shù)值越小,查找距離越大。此數(shù)值還會(huì)影響OverlapFit【重疊匹配】,靠近查找距離最大值的相鄰粒子的重疊匹配越靠近0。
ProximityWeight【近距權(quán)重】:數(shù)值比【角度權(quán)重】越大,距離影響越大
SearchVector【搜索向量】:相鄰粒子在角度上越靠近搜索方向,相鄰粒子的匹配度越高。搜索向量的模越大,角度影響越大,一般要把搜索向量設(shè)置為單位向量。
Particle Color Params【粒子顏色參數(shù)】模組
需要取消Library Only才能看到。重載粒子顏色的指定通道的數(shù)值。
Red Channel Value【R通道數(shù)值】
Green Channel Value【G通道數(shù)值】
Blur Channel Value【B通道數(shù)值】
Alpha Channel Value【A通道數(shù)值】
Sprite Based Line【基于圖片的線條】模組
Color【顏色】:設(shè)置Particles.SpriteBasedLine.Color的數(shù)值
Point A【點(diǎn)A】
Point B【點(diǎn)B】
SpriteWidth【圖片寬度】
Parameter Writes【參數(shù)寫入】
Particles.SpriteBasedLine.Color
Particles.SpriteBasedLine.Position:=點(diǎn)A與點(diǎn)B的中點(diǎn)
Particles.SpriteBasedLine.SpriteAlignment:由B指向A的向量
Particles.SpriteBasedLine.SpriteSize:X=SpriteWidth,Y=點(diǎn)A到點(diǎn)B的距離
Set up An Attribute Read Pointing toward this emitter so each particle can reference its neighbors.
【設(shè)置一個(gè)讀取自身的粒子屬性讀取器,使得每個(gè)粒子能查詢它的鄰居】
"Unyielding" is used by PBD and must be initialized. An unyeilding particle does not move if a yeilding particle bumps into it.
【不屈用于PBD模組且必須被初始化。一個(gè)不屈粒子被一個(gè)會(huì)屈粒子碰撞時(shí)不會(huì)移動(dòng)】
Each particles "Collision Radius" var must be separately updated as it's scale changes over time.
【每個(gè)粒子的碰撞半徑變量必須分開更新,因?yàn)樗目s放隨時(shí)間改變】
This collision module will bounce particles off of the world
【此碰撞模組會(huì)把粒子從世界中彈回來(lái)】
Feed the particles into the neighbor grid
【把粒子傳入相鄰網(wǎng)格】
Bounce the particles off of each other using position based dynamics
【使用基于位置的物理模擬使粒子間相互彈開】
"Spatial Particle Sort GPU" Finds the 3 closest particles
【空間粒子排序GPU模組找出3個(gè)最靠近的粒子】
Smooth out the number of instantaneous connections over time
【隨時(shí)間平滑瞬時(shí)連接的數(shù)量】
Feed that value into particle alpha
【把該數(shù)值傳入粒子Alpha】
Create position, scale and alignment variables for the sprite based lines
【為基于圖片的線條創(chuàng)建位置,縮放,對(duì)齊變量】