Based on file size, I suspect BUFFER.XXX, VIEW.DAT, or VPTMENU1.DA may contains soundtrack, but VPTMENU1.DA was the common RIFF format audio which is used in the opening movie and BUFFER.XXX was also a RIFF format but its just 3 minutes of noise. I thought VIEW.DAT looked similar to the GameMaker archive because of the words FORM and SPRT found in the file, but I could not extract it with yoyogames.bms(As I expected! PS1 Viewpoint was released before the foundation of YoYo Games.)
qxzq wrote:Hi I am looking for a way to extract the Playstation version of Viewpoint soundtrack from the game. The game disc has the following structure:
Based on file size, I suspect BUFFER.XXX, VIEW.DAT, or VPTMENU1.DA may contains soundtrack, but VPTMENU1.DA was the common RIFF format audio which is used in the opening movie and BUFFER.XXX was also a RIFF format but its just 3 minutes of noise. I thought VIEW.DAT looked similar to the GameMaker archive because of the words FORM and SPRT found in the file, but I could not extract it with yoyogames.bms(As I expected! PS1 Viewpoint was released before the foundation of YoYo Games.)
Just to add to the above, it looks like each 'file' begins with "FORM", then the size in Big Endian (although this size doesn't always work for every FORM segment, so it must signify something else).
Within each FORM segment is a bunch of chunks, same as RIFF files, with each having a chunk name followed by chunk size in Big Endian. Some of the chunks are SPRT, there is also KNCH, VCML and many others. Some of the chunks are sound, some are images.
DKDave wrote:Just to add to the above, it looks like each 'file' begins with "FORM", then the size in Big Endian (although this size doesn't always work for every FORM segment, so it must signify something else).
Within each FORM segment is a bunch of chunks, same as RIFF files, with each having a chunk name followed by chunk size in Big Endian. Some of the chunks are SPRT, there is also KNCH, VCML and many others. Some of the chunks are sound, some are images.
It seems, each form founded in the file, is like a "pak inside pak"
Example.
Form with SPR will have a pack with a lot of SPR.
Well.
Maybe an palliative way to extract the files should be make a findloc into form, until someone can make a real good script for it.
findloc OFFSET string "FORM" do goto OFFSET get DUMMY long findloc NEXT_OFFSET string "FORM" 0 "" if NEXT_OFFSET == "" get SIZE asize else math SIZE = NEXT_OFFSET endif math SIZE -= OFFSET string NAME p "%08x.dat" offset log NAME OFFSET SIZE math OFFSET = NEXT_OFFSET while NEXT_OFFSET != ""
I threw VIEW.DAT into rabatini's latest script and I got 977 files. I opened them in hex editor but I couldn't understand what these files mean. By the way, I scanned the split file with PSound and found some sound effects. So I put the entire VIEW.DAT into PSound and it still detected sound effects. However, no soundtrack data.
For finding clues, I opened the program(SLUS_000.33) in hex editor and I find some filenames at 0x000019E0. I don't know how these are tied to DAT, but they might be useful.
I threw VIEW.DAT into rabatini's latest script and I got 977 files. I opened them in hex editor but I couldn't understand what these files mean. By the way, I scanned the split file with PSound and found some sound effects. So I put the entire VIEW.DAT into PSound and it still detected sound effects. However, no soundtrack data.
For finding clues, I opened the program(SLUS_000.33) in hex editor and I find some filenames at 0x000019E0. I don't know how these are tied to DAT, but they might be useful.
In the header of VIEW.DIR, there is a string "VCSVCFBINTXTVH�VB�STRST1ST2ST3". These are file extensions. VH and VB are common format for PS1 soundtrack. In the program, I found another string "runtime\\vabs\\level1.vab". So I thought soundtrack is stored as VH+VB combo or VAB format. PSound supports opening VB and VAB format files, I expected that I can extract soundtrack's samples.
I threw VIEW.DAT into rabatini's latest script and I got 977 files. I opened them in hex editor but I couldn't understand what these files mean. By the way, I scanned the split file with PSound and found some sound effects. So I put the entire VIEW.DAT into PSound and it still detected sound effects. However, no soundtrack data.
For finding clues, I opened the program(SLUS_000.33) in hex editor and I find some filenames at 0x000019E0. I don't know how these are tied to DAT, but they might be useful.
findloc OFFSET string "FORM" do goto OFFSET get DUMMY long findloc NEXT_OFFSET string "FORM" 0 "" if NEXT_OFFSET == "" get SIZE asize else math SIZE = NEXT_OFFSET endif math SIZE -= OFFSET
log "" OFFSET SIZE math OFFSET = NEXT_OFFSET while NEXT_OFFSET != ""
endian big idstring "FORM" get SIZE long getdstring DUMMY 4 get IFF_SIZE asize savepos OFFSET for OFFSET = OFFSET != IFF_SIZE getdstring TYPE 4 get SIZE long savepos OFFSET string TYPE + / log TYPE OFFSET SIZE math OFFSET + SIZE goto OFFSET next
the program called ripper6 extract the view.dat in a different way creating a lot of iff files. you can also try it.
just drop the VIEW.DAT in the executable, waiting for extraction then use the second script. to extract folders/files.
in resume, you can try both ways my script + form/iff script or ripper6 + form/iff script
Just to let you know OP that the game's BGM was actually were inside the FORM/IFF files, on the VGML/VGMR chunks (Not all FORM files has that chunk though). I've made a BMS script to extract those chunks into a separate left/right channel VCM files
append for i = 0 FindLoc VCML long 0x56434d4c "" if VCML == "" break endif goto VCML get ID long get ID_SIZE long math ID_SIZE + 8 log MEMORY_FILE VCML ID_SIZE FindLoc VCMR long 0x56434d52 "" goto VCMR get ID long get ID_SIZE long math ID_SIZE + 8 log MEMORY_FILE2 VCMR ID_SIZE next i append
string NAME_L p "%s_L.VCM" NAME string NAME_R p "%s_R.VCM" NAME
get VCM_SZ_L asize MEMORY_FILE get VCM_SZ_R asize MEMORY_FILE2 log NAME_L 0 VCM_SZ_L MEMORY_FILE log NAME_R 0 VCM_SZ_R MEMORY_FILE2
You'll also need this .txth script to play the files with vgmstream
Save the text above as ".VCM.txth" then put it on the same directory as the VCM files. Don't forget to enable unknown exts in vgmstream preference if you're using foobar2000.Then, Just drag either one of the vcm files as the vgmstream will automatically play the both L and R files as one stereo audio.
BloodRaynare wrote:Just to let you know OP that the game's BGM was actually were inside the FORM/IFF files, on the VGML/VGMR chunks (Not all FORM files has that chunk though). I've made a BMS script to extract those chunks into a separate left/right channel VCM files
append for i = 0 FindLoc VCML long 0x56434d4c "" if VCML == "" break endif goto VCML get ID long get ID_SIZE long math ID_SIZE + 8 log MEMORY_FILE VCML ID_SIZE FindLoc VCMR long 0x56434d52 "" goto VCMR get ID long get ID_SIZE long math ID_SIZE + 8 log MEMORY_FILE2 VCMR ID_SIZE next i append
string NAME_L p "%s_L.VCM" NAME string NAME_R p "%s_R.VCM" NAME
get VCM_SZ_L asize MEMORY_FILE get VCM_SZ_R asize MEMORY_FILE2 log NAME_L 0 VCM_SZ_L MEMORY_FILE log NAME_R 0 VCM_SZ_R MEMORY_FILE2
Wow, this script worked! However, some files cannot be separated. I inputted iff files which was generated by Ripper6. QuickBMS says:
- select input archives/files, type * for the whole folder and subfolders - select output folder where extracting files - open input file <hidden>\Desktop\VIEW\0122.iff - open script <hidden>\quickbms\view.bms - set output folder <hidden>\Desktop\VIEW\VCM
Error: incomplete input file 0: <hidden>\Desktop\VIEW\0122.iff Can't read 3308 bytes from offset 01524e6c. Anyway don't worry, it's possible that the BMS script has been written to exit in this way if it's reached the end of the archive so check it or contact its author or verify that all the files have been extracted. Please check the following coverage information to know if it's ok.
- select input archives/files, type * for the whole folder and subfolders - select output folder where extracting files - open input file <hidden>\Desktop\VIEW\0122.iff - open script <hidden>\quickbms\view.bms - set output folder <hidden>\Desktop\VIEW\VCM
Error: incomplete input file 0: <hidden>\Desktop\VIEW\0122.iff Can't read 3308 bytes from offset 01524e6c. Anyway don't worry, it's possible that the BMS script has been written to exit in this way if it's reached the end of the archive so check it or contact its author or verify that all the files have been extracted. Please check the following coverage information to know if it's ok.
These files gave this error: 0055.iff 0056.iff 0122.iff
Can you make a fix?
I think it was the iff ripper that should be fixed because apparently some iff files were extracted incompletely. The error happens because the actual VGML/VGMR chunk sizes was smaller than the chunk header expects.
BloodRaynare wrote:I think it was the iff ripper that should be fixed because apparently some iff files were extracted incompletely. The error happens because the actual VGML/VGMR chunk sizes was smaller than the chunk header expects.
Oh. Fortunately, unconvertable soundtrack is released as single music, so I don't have to rip them from the game. It was credited in end credits. I should have checked it first.
Anyway, I got all soundtrack used in Viewpoint. Thanks everyone!