본문 바로가기
programming | development/unity

Strip Particle System

by foooo828 2022. 2. 23.

1. Context

Initialize Particle Strip

Strip Capacity

스트립 용량 

Particle Per Strip Capacity

스트립당 파티클 수

2. Block

Increment Strip Index On Start

 Spawn 컨텍스트의 start 이벤트 트리거될때마다 Strip Index 가 올라간다.

stripIndex 는 stop 이벤트가 트리거 되거나  stripIndex 가 Max Strip Count에 도달하면 0을 반환한다. (첫번째 스트립 그룹 인덱스로 돌아감)

 

https://docs.unity3d.com/Packages/com.unity.visualeffectgraph@10.5/manual/Block-IncrementStripInde

xOnStart.html#block-compatibility

 

Increment Strip Index On Start | Visual Effect Graph | 10.5.1

Increment Strip Index On Start Menu Path: Spawn > Custom > Increment Strip Index On Start The Increment Strip Index On Start Block helps to manage the initialization of Particle Strips. A Particle Strip comprises of linked groups of particles and the numbe

docs.unity3d.com

지렁이
vfx graph

** Increment Strip Index On Start 사용시 첫 생성 되는 스트립 인덱스는 1인거 같다.

Strip Index 마다  0 부터 3까지 색 (노빨초파)을 지정. 생성 위치도 인덱스 오름차순으로 좌측부터 우측으로 증가하도록 설정

맨 처음 생성된 파티클 스트립의 인덱스가 1(빨간색)인것을 볼 수 있다.

Spawn 할때마다 스트립 인덱스가 증가

인덱스 0(노란색)이 맨 마지막으로 나오는것을 볼 수 있다. ( Max Strip Count 에 도달하면 인덱스 0 반환)

 

** Initialize 컨텍스트의 Strip Capacity 가 Increment Strip Index On Start 블록의  Strip Max Count 가 다를때?

Strip Capacity가 Strip Max Count보다 작으면 Strip Capacity -1 만큼만 생성된다.

3. Attribute

Get Attribute: particle​Index​In​Strip

파티클 스트링 링 버퍼 내의 시뮬레이션 된 입자의 인덱스를 출력 

 

Get Attribute: stripIndex

파티클이 속한 파티클 스트립 인덱스를 출력

 

댓글