add ITextureProvider.GetFromFile(FileInfo)

This commit is contained in:
goat 2024-06-29 18:02:11 +02:00
parent df5c1bfead
commit a3a7acc45e
3 changed files with 29 additions and 3 deletions

View file

@ -212,6 +212,15 @@ public interface ITextureProvider
/// <para>Caching the returned object is not recommended. Performance benefit will be minimal.</para>
/// </remarks>
ISharedImmediateTexture GetFromFile(string path);
/// <summary>Gets a shared texture corresponding to the given file on the filesystem.</summary>
/// <param name="file">The file on the filesystem to load.</param>
/// <returns>The shared texture that you may use to obtain the loaded texture wrap and load states.</returns>
/// <remarks>
/// <para>This function does not throw exceptions.</para>
/// <para>Caching the returned object is not recommended. Performance benefit will be minimal.</para>
/// </remarks>
ISharedImmediateTexture GetFromFile(FileInfo file);
/// <summary>Gets a shared texture corresponding to the given file of the assembly manifest resources.</summary>
/// <param name="assembly">The assembly containing manifest resources.</param>