soundvision/UnityProject/Assets/Scripts/PdConnection/PdArraySelector.cs
max b44743ba07 Max Shader Graph Advance
- Gradients of Depth Camera to different Colors
- Base Color becomes transparent on boolean true
2019-10-16 12:24:21 +02:00

28 lines
No EOL
614 B
C#

namespace cylvester
{
public interface IPdArraySelector
{
int Selection { set; }
float[] SelectedArray { get; }
}
public class PdArraySelector : IPdArraySelector
{
private int selection_;
private readonly IPdArrayContainer arrayContainer_;
public PdArraySelector(IPdArrayContainer arrayContainer)
{
arrayContainer_ = arrayContainer;
}
public int Selection
{
set => selection_ = value;
}
public float[] SelectedArray => arrayContainer_[selection_].Data;
}
}