public static RomInfo GetRomInfo(string filename = "", Int32 archiveFileIndex = -1) { InteropRomInfo romInfo = new InteropRomInfo(); InteropEmu.GetRomInfoWrapper(ref romInfo, filename, archiveFileIndex); return(new RomInfo(romInfo)); }
public RomInfo(InteropRomInfo romInfo) { RomPath = (ResourcePath)Utf8Marshaler.GetStringFromIntPtr(romInfo.RomPath); PatchPath = (ResourcePath)Utf8Marshaler.GetStringFromIntPtr(romInfo.PatchPath); Header = romInfo.Header; CoprocessorType = romInfo.CoprocessorType; }
[DllImport(DllPath, EntryPoint = "GetRomInfo")] private static extern void GetRomInfoWrapper(out InteropRomInfo romInfo);
public RomInfo(InteropRomInfo romInfo) { this.RomName = UTF8Marshaler.GetStringFromIntPtr(romInfo.RomNamePointer); this.Crc32 = romInfo.Crc32; this.PrgCrc32 = romInfo.PrgCrc32; }
[DllImport(DLLPath, EntryPoint = "GetRomInfo")] private static extern UInt32 GetRomInfoWrapper(ref InteropRomInfo romInfo, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof(UTF8Marshaler))] string filename = "", Int32 archiveFileIndex = -1);