mirror of
https://github.com/crskycode/GARbro.git
synced 2024-11-23 21:55:34 +08:00
(Ail): detect audio and video files.
This commit is contained in:
parent
787cc68192
commit
e09d5ae5df
@ -116,7 +116,7 @@ namespace GameRes.Formats.Ail
|
|||||||
entry.IsPacked = true;
|
entry.IsPacked = true;
|
||||||
entry.UnpackedSize = file.View.ReadUInt32 (entry.Offset+2);
|
entry.UnpackedSize = file.View.ReadUInt32 (entry.Offset+2);
|
||||||
}
|
}
|
||||||
else if (0 == signature)
|
else if (0 == signature || file.View.AsciiEqual (entry.Offset+4, "OggS"))
|
||||||
{
|
{
|
||||||
extra = 4;
|
extra = 4;
|
||||||
}
|
}
|
||||||
@ -141,11 +141,19 @@ namespace GameRes.Formats.Ail
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void SetEntryType (Entry entry, uint signature)
|
static void SetEntryType (Entry entry, uint signature)
|
||||||
|
{
|
||||||
|
if (0xBA010000 == signature)
|
||||||
|
{
|
||||||
|
entry.Type = "video";
|
||||||
|
entry.Name = Path.ChangeExtension (entry.Name, "mpg");
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
var res = AutoEntry.DetectFileType (signature);
|
var res = AutoEntry.DetectFileType (signature);
|
||||||
if (null != res)
|
if (null != res)
|
||||||
entry.ChangeType (res);
|
entry.ChangeType (res);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Custom LZSS decompression with frame pre-initialization and reveresed control bits meaning.
|
/// Custom LZSS decompression with frame pre-initialization and reveresed control bits meaning.
|
||||||
|
Loading…
Reference in New Issue
Block a user