mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 17:01:28 +00:00
21b4862460
* music system improvements * Zip64 support * fixes for menu scaling on ultrawide screens * Mac default paths fixed * lightmap code (not active yet)
49 lines
No EOL
1 KiB
C++
49 lines
No EOL
1 KiB
C++
#ifndef __FILE_ZIP_H
|
|
#define __FILE_ZIP_H
|
|
|
|
#include "resourcefile.h"
|
|
|
|
//==========================================================================
|
|
//
|
|
// Zip Lump
|
|
//
|
|
//==========================================================================
|
|
|
|
struct FZipLump : public FResourceLump
|
|
{
|
|
uint16_t GPFlags;
|
|
uint8_t Method;
|
|
bool NeedFileStart;
|
|
int CompressedSize;
|
|
int64_t Position;
|
|
unsigned CRC32;
|
|
|
|
virtual FileReader *GetReader();
|
|
virtual int FillCache();
|
|
|
|
private:
|
|
void SetLumpAddress();
|
|
virtual int GetFileOffset();
|
|
FCompressedBuffer GetRawData();
|
|
};
|
|
|
|
|
|
//==========================================================================
|
|
//
|
|
// Zip file
|
|
//
|
|
//==========================================================================
|
|
|
|
class FZipFile : public FResourceFile
|
|
{
|
|
FZipLump *Lumps;
|
|
|
|
public:
|
|
FZipFile(const char * filename, FileReader &file);
|
|
virtual ~FZipFile();
|
|
bool Open(bool quiet, LumpFilterInfo* filter);
|
|
virtual FResourceLump *GetLump(int no) { return ((unsigned)no < NumLumps)? &Lumps[no] : NULL; }
|
|
};
|
|
|
|
|
|
#endif |