mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-11-22 17:19:15 +01:00
fix windows build, don't use crossplatform
This commit is contained in:
parent
b0414c84b9
commit
40c09d28f7
@ -858,19 +858,37 @@ RpHAnimHierarchy *RpSkinAtomicGetHAnimHierarchy( const RpAtomic *atomic ) { retu
|
||||
RwImage *
|
||||
RtBMPImageWrite(RwImage *image, const RwChar *imageName)
|
||||
{
|
||||
char *r = (char *)alloca(strlen((char *)imageName) + 2);
|
||||
// Use default path(and pass error handling to librw) if we can't find any match
|
||||
if(!casepath((char *)imageName, r)) r = (char *)imageName;
|
||||
#ifndef _WIN32
|
||||
char *r = nil;
|
||||
FILE *valid = fopen((char *)imageName, "r");
|
||||
if(!valid) {
|
||||
char *r = (char *)alloca(strlen((char *)imageName) + 2);
|
||||
// Use default path(and pass error handling to librw) if we can't find any match
|
||||
if(!casepath((char *)imageName, r)) r = (char *)imageName;
|
||||
} else
|
||||
fclose(valid);
|
||||
rw::writeBMP(image, r);
|
||||
#else
|
||||
rw::writeBMP(image, imageName);
|
||||
#endif
|
||||
return image;
|
||||
}
|
||||
RwImage *
|
||||
RtBMPImageRead(const RwChar *imageName)
|
||||
{
|
||||
char *r = (char *)alloca(strlen((char *)imageName) + 2);
|
||||
// Use default path(and pass error handling to librw) if we can't find any match
|
||||
if(!casepath((char *)imageName, r)) r = (char *)imageName;
|
||||
#ifndef _WIN32
|
||||
char *r = nil;
|
||||
FILE *valid = fopen((char *)imageName, "r");
|
||||
if(!valid) {
|
||||
r = (char *)alloca(strlen((char *)imageName) + 2);
|
||||
// Use default path(and pass error handling to librw) if we can't find any match
|
||||
if(!casepath((char *)imageName, r)) r = (char *)imageName;
|
||||
} else
|
||||
fclose(valid);
|
||||
return rw::readBMP(r);
|
||||
#else
|
||||
return rw::readBMP(imageName);
|
||||
#endif
|
||||
}
|
||||
|
||||
#include "rtquat.h"
|
||||
|
Loading…
Reference in New Issue
Block a user