Jump to content

Tenchu San Audio Bank (PSP) (PPHD8)


Go to solution Solved by ikskoks,

Recommended Posts

Posted

In short, I'm trying to edit the main characters' audio from Japanese to English.

The structure is simple: .vag audio files joined together using a program that creates audio banks. I've already obtained the program and learned how it works. In short, they're .bin files with audio banks. Each character has a "bank",three in total, joined into a single .bin file (SE_PLAYER.bin).

[Each bank starts with the signature PPHD8 and has a repeating size/range of 0xE000. PPHD8 signatures appear at offsets 0x00000, 0x0E000, and 0x1C000.]

[PPPG\ — likely start of sample data or a table of pointers to phoneme blocks.]

I'm trying to repeat the process using the PS2 character audio. I export it to .wav and convert it to .vag. I do everything, but the size and offsets differ. The audio files have the same duration, kbps, and hz (11025). I've tried compressing them as much as possible, but nothing seems to work.

(The PS2 version's audio files aren't in .vag format, but rather in Sony's APDCM format.)

If anyone knows of a game that also uses this type of database, or has any ideas on how to help, I'd appreciate it.

SE_PLAYER.rar NEW_SE_PLAYER(TEST).rar

  • Moderators
  • Solution
Posted

This BIN file seems to be a container for multiple PHD and PBD files
https://rewiki.miraheze.org/wiki/PSP_Audio_PHD_PBD_PEF

You can try to deal with it this way:
 1. Extract data from BIN and save it as proper PHD/PBD files (with quickbms script or something like that)
 2. Generate VAG files using MFAudio 
 3. Strip header from VAG files https://rewiki.miraheze.org/wiki/PlayStation_VAG_Audio
 4. Compare sizes and import waveform data to PBD if new size is smaller than original

This can be simplified even more if you can calculate correct waveform data offsets and sizes from PPVA chunk.
Then you just need to write a proper quickbms script or program to handle all the logic.

Posted
On 10/9/2025 at 12:53 PM, ikskoks said:

This BIN file seems to be a container for multiple PHD and PBD files
https://rewiki.miraheze.org/wiki/PSP_Audio_PHD_PBD_PEF

You can try to deal with it this way:
 1. Extract data from BIN and save it as proper PHD/PBD files (with quickbms script or something like that)
 2. Generate VAG files using MFAudio 
 3. Strip header from VAG files https://rewiki.miraheze.org/wiki/PlayStation_VAG_Audio
 4. Compare sizes and import waveform data to PBD if new size is smaller than original

This can be simplified even more if you can calculate correct waveform data offsets and sizes from PPVA chunk.
Then you just need to write a proper quickbms script or program to handle all the logic.

The problem is the size. The audio files have the same duration, even with the same kbps. But when I convert from WAV to VAG using any program, the size changes, and that messes everything up because the offsets will change and the game won't recognize them. I've already compressed them as much as possible, but it doesn't seem to help. I think the solution will be to mess with the game's memory to change the offsets it reads, unfortunately (more work).

  • Moderators
Posted

Maybe you should adjust quality of the input WAV file?

See this example:
obraz.png.49d3462ee744a7076a93a869dc4d632e.png


After converting audio with original quality I got VAG file with size = 715 KB.
But when saved low quality WAV in Audacity and converted to VAG I got file with size = 165 KB.

Did you try this method?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...