public void Load(string filename) { FileInfo = new FileInfo(filename); if (FileInfo.Exists) { _jtex = new JTEX(FileInfo.OpenRead()); _bitmaps = _jtex.bmps.Select(o => new BitmapInfo { Bitmap = o }).ToList(); } }
public void Load(string filename) { FileInfo = new FileInfo(filename); if (FileInfo.Exists) { _jtex = new JTEX(FileInfo.OpenRead()); var _bmpList = _jtex.bmps.Select(o => new JTEXBitmapInfo { Bitmap = o, Format = _jtex.settings.Format.FormatName }).ToList(); _bitmaps = new List <BitmapInfo>(); _bitmaps.AddRange(_bmpList); } }
public LoadResult Load(string filename) { LoadResult result = LoadResult.Success; _fileInfo = new FileInfo(filename); if (_fileInfo.Exists) { if (raw) { _rawjtex = new RawJTEX(new FileStream(_fileInfo.FullName, FileMode.Open, FileAccess.Read)); } else { _jtex = new JTEX(new FileStream(_fileInfo.FullName, FileMode.Open, FileAccess.Read)); } } else { result = LoadResult.FileNotFound; } return(result); }