public static void AddTextureReader(TextureReader tex, string msg) { // Trace.WriteLine("Adding Texture Reader: " + tex.GetHashCode().ToString(), "TextureUse"); lock (Global.AllocatedTextureReaders) { if(Global.AllocatedTextureReaders.ContainsKey(tex.GetHashCode()) == false) Global.AllocatedTextureReaders.Add(tex.GetHashCode(), msg); } _TexturesLoading = true; }
public static void RemoveTextureReader(TextureReader tex) { // Trace.WriteLine("Removing Texture Reader: " + tex.GetHashCode().ToString(), "TextureUse"); lock (Global.AllocatedTextureReaders) { Global.AllocatedTextureReaders.Remove(tex.GetHashCode()); } }