public MaterialParameter(EffectParameter parameter) { if (parameter == null) { throw new ArgumentNullException("parameter"); } if (string.IsNullOrEmpty(parameter.Semantic)) { throw new ArgumentException("Material parameters must have a semantic"); } this.Parameter = parameter; this.setter = CreateSetter(parameter); }
public MaterialParameter(EffectParameter parameter) { if (parameter == null) throw new ArgumentNullException("parameter"); if (string.IsNullOrEmpty(parameter.Semantic)) throw new ArgumentException("Material parameters must have a semantic"); _parameter = parameter; _setter = CreateSetter(parameter); }