/// <summary>Gets a shader set by name.</summary> public static ShaderSet Get(string name) { ShaderSet result = null; if (GlobalCache == null) { // Create the global cache: GlobalCache = new Dictionary <string, ShaderSet>(); } else { // Load from cache: GlobalCache.TryGetValue(name, out result); } if (result == null) { // Create and add: result = new ShaderSet(name); // Push it in: GlobalCache[name] = result; } return(result); }
/// <summary>A material with just the single frame on it.</summary> public Material GetImageMaterial(ShaderSet shaders) { return(Contents.GetImageMaterial(shaders.Isolated)); }
//--------------------------------------