mirror of
https://github.com/zeldaret/tp
synced 2026-06-01 01:39:43 -04:00
221f40e609
* add "global.h" to files that use it * add MSL_C includes to files that use them * remove dolphin includes from headers that don't need them * remove JSupport includes from headers that don't need them * remove JKernel includes from headers that don't need them * remove JUtility includes from headers that don't need them * remove J3D includes from headers that don't need them * remove J2D includes from headers that don't need them * remove JAudio2 includes from headers that don't need them * remove Z2AudioLib includes from headers that don't need them * remove JMessage includes from headers that don't need them * remove JParticle includes from headers that don't need them * remove SComponent includes from headers that don't need them * remove dol includes from headers that don't need them * sort includes
61 lines
2.1 KiB
C++
61 lines
2.1 KiB
C++
#ifndef JKRDVDRIPPER_H
|
|
#define JKRDVDRIPPER_H
|
|
|
|
#include "JSystem/JKernel/JKRCompression.h"
|
|
#include "dolphin/types.h"
|
|
|
|
enum JKRExpandSwitch {
|
|
EXPAND_SWITCH_UNKNOWN0 = 0,
|
|
EXPAND_SWITCH_UNKNOWN1 = 1,
|
|
EXPAND_SWITCH_UNKNOWN2 = 2,
|
|
};
|
|
|
|
struct SYaz0Header {
|
|
u32 signature;
|
|
u32 length;
|
|
};
|
|
|
|
class JKRHeap;
|
|
class JKRDvdFile;
|
|
class JKRDvdRipper {
|
|
public:
|
|
// TODO: fix type
|
|
static u8 sDvdAsyncList[12];
|
|
static u32 sSZSBufferSize;
|
|
|
|
enum EAllocDirection {
|
|
UNKNOWN_EALLOC_DIRECTION = 0,
|
|
ALLOC_DIRECTION_FORWARD = 1,
|
|
ALLOC_DIRECTION_BACKWARD = 2,
|
|
};
|
|
|
|
static void setSZSBufferSize(u32 size) { sSZSBufferSize = size; }
|
|
|
|
static void* loadToMainRAM(char const*, u8*, JKRExpandSwitch, u32, JKRHeap*, EAllocDirection,
|
|
u32, JKRCompression*, u32*);
|
|
static void* loadToMainRAM(long, u8*, JKRExpandSwitch, u32, JKRHeap*, EAllocDirection, u32,
|
|
JKRCompression*, u32*);
|
|
static void* loadToMainRAM(JKRDvdFile*, u8*, JKRExpandSwitch, u32, JKRHeap*, EAllocDirection,
|
|
u32, JKRCompression*, u32*);
|
|
|
|
static u8 isErrorRetry(void);
|
|
};
|
|
|
|
// void JKRDecompressFromDVD(JKRDvdFile*, void*, u32, u32, u32, u32, u32*);
|
|
|
|
inline void* JKRDvdToMainRam(s32 entryNum, u8* dst, JKRExpandSwitch expandSwitch, u32 dstLength,
|
|
JKRHeap* heap, JKRDvdRipper::EAllocDirection allocDirection,
|
|
u32 offset, JKRCompression* compression, u32* returnSize) {
|
|
return JKRDvdRipper::loadToMainRAM(entryNum, dst, expandSwitch, dstLength, heap, allocDirection,
|
|
offset, compression, returnSize);
|
|
}
|
|
|
|
inline void* JKRDvdToMainRam(const char* name, u8* dst, JKRExpandSwitch expandSwitch, u32 dstLength,
|
|
JKRHeap* heap, JKRDvdRipper::EAllocDirection allocDirection,
|
|
u32 offset, JKRCompression* compression, u32* returnSize) {
|
|
return JKRDvdRipper::loadToMainRAM(name, dst, expandSwitch, dstLength, heap, allocDirection,
|
|
offset, compression, returnSize);
|
|
}
|
|
|
|
#endif /* JKRDVDRIPPER_H */
|