// DIE's signature file
// Author: LinXP
// doc-ref: http://www.libpng.org/pub/mng/spec/

init("image","Multiple-image Network Graphics (.MNG)");

function detect(bShowType,bShowVersion,bShowOptions)
{
    if(Binary.getSize()>=0x40)
    {
        if(Binary.compare("8A'MNG\r\n'1A0A........'MHDR'"))
        {
            bDetected=true;
            if(Binary.isVerbose())
            {
                sOption(Binary.read_uint32(0x10,_BE)+"x"+Binary.read_uint32(0x14,_BE));
                sOption("frames:"+Binary.read_uint32(0x18,_BE));
            }
        }
    }

    return result(bShowType,bShowVersion,bShowOptions);
}