Added .nps extension [Venus & Braves PS2]

This commit is contained in:
bnnm 2017-01-07 14:33:10 +01:00
parent 1b9dcac1c6
commit 2557074ceb
2 changed files with 7 additions and 3 deletions

View File

@ -164,6 +164,7 @@ static const char* extension_list[] = {
"ndp", "ndp",
"ngca", "ngca",
"nps",
"npsf", "npsf",
"nus3bank", //todo not existing? "nus3bank", //todo not existing?
"nwa", "nwa",

View File

@ -1,8 +1,9 @@
#include "meta.h" #include "meta.h"
#include "../util.h" #include "../util.h"
/* Sony .ADS with SShd & SSbd Headers */ /* NPFS - found in Namco PS2/PSP games:
* Tekken 5, Ace Combat 5, Yumeria, Venus & Braves (.nps), Ridge Racer PSP, etc
*/
VGMSTREAM * init_vgmstream_ps2_npsf(STREAMFILE *streamFile) { VGMSTREAM * init_vgmstream_ps2_npsf(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL; VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT]; char filename[PATH_LIMIT];
@ -14,7 +15,9 @@ VGMSTREAM * init_vgmstream_ps2_npsf(STREAMFILE *streamFile) {
/* check extension, case insensitive */ /* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename)); streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("npsf",filename_extension(filename))) goto fail; if (strcasecmp("npsf",filename_extension(filename)) &&
strcasecmp("nps",filename_extension(filename)))
goto fail;
/* check NPSF Header */ /* check NPSF Header */
if (read_32bitBE(0x00,streamFile) != 0x4E505346) if (read_32bitBE(0x00,streamFile) != 0x4E505346)