Ejemplo n.º 1
0
        public void InsertSubshader(int index, SubshaderType subshaderType)
        {
            switch (subshaderType)
            {
            case SubshaderType.Surface:
                _subshaders.Insert(index, CreateInstance <SurfaceShader>());
                break;

            case SubshaderType.Custom:
                throw new InvalidEnumArgumentException();
#pragma warning disable 0162
                break;

#pragma warning restore 0162
            default:
                throw new ArgumentOutOfRangeException("subshaderType");
            }
        }
Ejemplo n.º 2
0
 public void AddSubshader(SubshaderType subshaderType)
 {
     InsertSubshader(_subshaders.Count, subshaderType);
 }