mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-21 15:21:15 +00:00
* Following feedback from @stravant and @itsmattkc, reverted back to using `MMIOINFO` struct as the class member instead of adding its values directly. (We actually gained a little on accuracy with this change.) * The memset to zero out the values in the constructor now acts on `m_info` instead of `this`. Strictly speaking we don't need the size assert any more but I decided to keep it in case we change the members later for some reason. * Casting the `hmmio` member to `HFILE` (int) or `HMMIO` (WORD) typedefs where needed. * Squelch a signed/unsigned type comparison warning
30 lines
605 B
C++
30 lines
605 B
C++
#ifndef MXIOINFO_H
|
|
#define MXIOINFO_H
|
|
|
|
#include <windows.h>
|
|
#include <mmsystem.h>
|
|
|
|
#include "mxtypes.h"
|
|
|
|
class MXIOINFO
|
|
{
|
|
public:
|
|
MXIOINFO();
|
|
__declspec(dllexport) ~MXIOINFO();
|
|
|
|
MxU16 Open(const char *, MxULong);
|
|
MxU16 Close(MxLong);
|
|
MxLong Read(void *, MxLong);
|
|
MxLong Seek(MxLong, int);
|
|
MxU16 SetBuffer(char *, MxLong, MxLong);
|
|
MxU16 Flush(MxU16);
|
|
MxU16 Advance(MxU16);
|
|
MxU16 Descend(MMCKINFO *, const MMCKINFO *, MxU16);
|
|
|
|
// NOTE: In MXIOINFO, the `hmmio` member of MMIOINFO is used like
|
|
// an HFILE (int) instead of an HMMIO (WORD).
|
|
MMIOINFO m_info;
|
|
};
|
|
|
|
#endif // MXIOINFO_H
|