Exemplo n.º 1
0
int PHYSFS_readSBE32(PHYSFS_File *file, PHYSFS_sint32 *val)
{
    PHYSFS_sint32 in;
    BAIL_IF_MACRO(val == NULL, ERR_INVALID_ARGUMENT, 0);
    BAIL_IF_MACRO(PHYSFS_read(file, &in, sizeof (in), 1) != 1, NULL, 0);
    *val = PHYSFS_swapSBE32(in);
    return(1);
} /* PHYSFS_readSBE32 */
Exemplo n.º 2
0
int PHYSFS_writeSBE32(PHYSFS_File *file, PHYSFS_sint32 val)
{
    PHYSFS_sint32 out = PHYSFS_swapSBE32(val);
    BAIL_IF_MACRO(PHYSFS_write(file, &out, sizeof (out), 1) != 1, NULL, 0);
    return(1);
} /* PHYSFS_writeSBE32 */
Exemplo n.º 3
0
sint32 Util::swapSBE32(sint32 value) {
	return PHYSFS_swapSBE32(value);
}