Lightning
Created Lightning Gun effect (Uses LineRenderer, very slow) Created GPU Lightning renderer (very fast, still needs integration)
This commit is contained in:
parent
3a9ee2ccf7
commit
bb297bf84c
100 changed files with 7105 additions and 13 deletions
|
|
@ -0,0 +1,38 @@
|
|||
using UnityEngine;
|
||||
using System.Runtime.InteropServices;
|
||||
using System;
|
||||
|
||||
public class GPUTrailIndirectSample : GPUTrailIndirect
|
||||
{
|
||||
public GPUTrailIndirectSampleParticle _particle;
|
||||
|
||||
protected override int TrailNumMax
|
||||
{
|
||||
get
|
||||
{
|
||||
return _particle._particleNum;
|
||||
}
|
||||
}
|
||||
|
||||
protected override void Awake()
|
||||
{
|
||||
base.Awake();
|
||||
|
||||
_particle.Init();
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected override bool UpdateInputBuffer()
|
||||
{
|
||||
_particle.UpdateInputBuffer(_inputBuffer);
|
||||
return true;
|
||||
}
|
||||
|
||||
protected override void ReleaseBuffer()
|
||||
{
|
||||
base.ReleaseBuffer();
|
||||
|
||||
_particle.ReleaseBuffer();
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue