From ac3aa264201511c13212e81d9ddea01e1aa3f426 Mon Sep 17 00:00:00 2001 From: bnnm Date: Fri, 30 Mar 2018 00:39:21 +0200 Subject: [PATCH] Add .sng extension for EA 1SNh as foobar doesn't like .asf --- README.md | 3 ++- src/meta/ea_1snh.c | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 613fab39..e5df35be 100644 --- a/README.md +++ b/README.md @@ -122,11 +122,12 @@ like foobar or Winamp don't react well to that, they may be renamed for vgmstream (mainly to get looping in some cases). - .ac3 to .lac3 - .aac to .laac +- .asf to .sng (EA formats) - .mp4 to .lmp4 - .ogg to .logg - .opus to .lopus - .stm to .lstm -- .wav to .lwav (or .xwav in rare original Xbox cases) +- .wav to .lwav Command line tools don't have this restriction and will accept the original filename. diff --git a/src/meta/ea_1snh.c b/src/meta/ea_1snh.c index d4b7317c..6c5ace30 100644 --- a/src/meta/ea_1snh.c +++ b/src/meta/ea_1snh.c @@ -35,11 +35,11 @@ VGMSTREAM * init_vgmstream_ea_1snh(STREAMFILE *streamFile) { ea_header ea = {0}; - /* check extension (.asf/as4: common, cnk: some PS games) */ - if (!check_extensions(streamFile,"asf,as4,cnk")) + /* checks */ + /* .asf/as4: common, cnk: some PS games, .sng: fake for plugins (to mimic EA SCHl's common extension) */ + if (!check_extensions(streamFile,"asf,as4,cnk,sng")) goto fail; - /* check header (first block) */ if (read_32bitBE(0x00,streamFile) != 0x31534E68 && /* "1SNh" */ read_32bitBE(0x00,streamFile) != 0x53454144) /* "SEAD" */ goto fail;