usbloadergx/source/usbloader/wbfs.h
e.bovendeur e8f5ab07bd * Changed WBFS stuff to C++ classes
* Fixed bug in http.c (where realloc *might* choose another address, thanks Dr. Clipper)
* Added support to /wbfs/Game Title [GAMEID].wbfs files (thanks oggzee)
* Fixed bug in cfg_cleanup when switching partitions
* Added BGM class again (for playing background music, requested by dimok)
* Added settings for background music again
* Fixed bug in MEM2 class (returning an invalid handle when no memory could be allocated, thanks to dimok)
* Updated DIP module to OpenDIP (report bugs with this one if you've found them, but report them here: http://github.com/spacemanspiff/odip-plugin)
* Added initial code for cios 222 rev5 (THIS DOES NOT WORK YET! DON'T FILE BUGS ON THIS ONE!)
* Added fatffs module by Hermes and Waninkoko (THIS DOES NOT WORK YET! DON'T FILE BUGS ON THIS ONE!)
* Fixed bug in Settings, which resulted in a crash when the partition was changed.
* Added caching for gamelist entries, so switching between different screens/sort options/display modes should be faster
* Changed defines in ehc_module, in order to prevent clashes with new defines in rev5
2010-02-14 23:22:52 +00:00

65 lines
1.6 KiB
C

#ifndef _WBFS_H_
#define _WBFS_H_
#include "libwbfs/libwbfs.h"
#include "usbloader/disc.h"
#ifdef __cplusplus
extern "C" {
#endif
#define PART_FS_WBFS 0
#define PART_FS_FAT 1
#define PART_FS_NTFS 2
/* Macros */
#define WBFS_MIN_DEVICE 1
#define WBFS_MAX_DEVICE 2
extern s32 wbfsDev;
extern int wbfs_part_fs;
extern u32 wbfs_part_idx;
extern u32 wbfs_part_lba;
extern char wbfs_fs_drive[16];
/* Prototypes */
void GetProgressValue(s32 * d, s32 * m);
s32 WBFS_Init(u32);
s32 WBFS_Open(void);
s32 WBFS_Format(u32, u32);
s32 WBFS_GetCount(u32 *);
s32 WBFS_GetHeaders(struct discHdr *, u32, u32);
// s32 __WBFS_ReadDVD(void *fp, u32 lba, u32 len, void *iobuf);
wbfs_t *GetHddInfo(void);
s32 WBFS_CheckGame(u8 *);
s32 WBFS_AddGame(void);
s32 WBFS_RemoveGame(u8 *);
s32 WBFS_GameSize(u8 *, f32 *);
bool WBFS_ShowFreeSpace(void);
s32 WBFS_DiskSpace(f32 *, f32 *);
s32 WBFS_RenameGame(u8 *, const void *);
s32 WBFS_ReIDGame(u8 *discid, const void *newID);
f32 WBFS_EstimeGameSize(void);
int WBFS_GetFragList(u8 *id);
/*
s32 __WBFS_ReadUSB(void *fp, u32 lba, u32 count, void *iobuf);
s32 __WBFS_WriteUSB(void *fp, u32 lba, u32 count, void *iobuf);
*/
s32 WBFS_OpenPart(u32 part_fat, u32 part_idx, u32 part_lba, u32 part_size, char *partition);
s32 WBFS_OpenNamed(char *partition);
s32 WBFS_OpenLBA(u32 lba, u32 size);
wbfs_disc_t* WBFS_OpenDisc(u8 *discid);
void WBFS_CloseDisc(wbfs_disc_t *disc);
bool WBFS_Close();
bool WBFS_Mounted();
bool WBFS_Selected();
#ifdef __cplusplus
}
#endif
#endif