public void Init(SaberSalient ss, bool opaque) { this.ss = ss; if (opaque) { material = ss.ab.LoadAsset <Material>("Hidden_SaberOpaque"); if (material == null) { throw new NullReferenceException("SaberSalientCamera - No material!"); } material.SetTexture("_ColorTex", ColorTex); } else { material = ss.ab.LoadAsset <Material>("Hidden_SaberSalient"); if (material == null) { throw new NullReferenceException("SaberSalientCamera - No material!"); } material.SetTexture("_ColorTex", ColorTex); material.SetTexture("_DepthTex", DepthTex); } enabled = true; }
public SaberSalientComponent() { ss = SaberSalient.Singleton; enabled = true; }