mirror of
https://github.com/crskycode/GARbro.git
synced 2024-12-24 03:44:13 +08:00
(ImageFormatDecoder.Create): new static method.
This commit is contained in:
parent
3c023d1b6b
commit
7f5d2c9b24
@ -87,6 +87,23 @@ namespace GameRes
|
|||||||
Info = info;
|
Info = info;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Create instance of ImageFormatDecoder from input binary stream.
|
||||||
|
/// In case of error input stream is disposed.
|
||||||
|
/// </summary>
|
||||||
|
public static ImageFormatDecoder Create (IBinaryStream input)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return new ImageFormatDecoder (input);
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
input.Dispose();
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
bool m_disposed = false;
|
bool m_disposed = false;
|
||||||
public void Dispose ()
|
public void Dispose ()
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user