1 #ifdef ATHENA_ENABLE_PHYSFS 2 #ifndef PHYSFSSTREAM_HPP 3 #define PHYSFSSTREAM_HPP 5 #include "athena/Stream.hpp" 12 class PHYSFSFileReader :
public Stream
15 PHYSFSFileReader(
const std::string& path);
17 void setEndian(Endian);
18 Endian endian()
const;
19 bool isBigEndian()
const;
20 bool isLittleEndian()
const;
23 atUint64 length()
const;
25 atUint64 position()
const;
29 void seek(atInt64 position, SeekOrigin origin);
32 atUint8* readUBytes(atUint64 length);
33 atInt8* readBytes(atUint64 length);
34 atUint16 readUint16();
36 atUint32 readUint32();
38 atUint64 readUint64();
51 PHYSFS_File* m_handle;
56 #ifndef PHYSFSFILEREADER_BASE 57 #define PHYSFSFILEREADER_BASE() \ 58 typedef athena::io::PHYSFSFileReader base 60 #endif // PHYSFSSTREAM_HPP 61 #endif // ATHENA_ENABLE_PHYSFS