Author Topic: [PC] Sound Effects dumper/encoder - sfxEdit (0.3)  (Read 28912 times)

luksy

  • *
  • Posts: 375
    • View Profile
Fiddling about with cosmo to change some of the new sound effects was a little tedious after a while, so I made this to dump and process an entire folder into audio.fmt + audio.dat

Check the readme for details, the looping details are a guess on my part, if anybody has more info I'd be grateful!


sfxEdit
« Last Edit: 2018-04-24 18:27:24 by Covarr »

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [WIP] sfxEdit 0.1 --- sound effects dumper / encoder
« Reply #1 on: 2012-01-20 15:49:23 »
Small oversight I think but encode on mine just makes the effects game files 0KB.  :)

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [WIP] sfxEdit 0.1 --- sound effects dumper / encoder
« Reply #2 on: 2012-01-22 17:11:56 »
That one has been fixed, but I now get effects in wrong places...  as we discussed this does not seem to happen to everyone.

luksy

  • *
  • Posts: 375
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #3 on: 2012-01-23 00:54:45 »
Right I've stopped assuming windows will magically order the files for me, the only possible downside is that it won't accept more than 750 fx in case any need to be added (unlikely, there are loads of empties anyway).

LeonhartGR

  • *
  • Posts: 2577
  • ~Whatever...~ Enjoy life!
    • View Profile
    • LeonhartGR Productions
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #4 on: 2012-02-12 17:43:05 »
My audio .dat file is 0kb! I can't find it anywhere. I forgot to back it up. When I type e do i need to type the path of the folder where the program recovers the wav files? When I just type e the program exits. The folder needs to have only the wav files? Please help! I can't hear any sounds now
« Last Edit: 2012-02-12 17:51:55 by Leonhart7413 »

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #5 on: 2012-02-12 18:02:28 »
You need the original audio.dat file from disc and place in the correct folder. Always back up.

LeonhartGR

  • *
  • Posts: 2577
  • ~Whatever...~ Enjoy life!
    • View Profile
    • LeonhartGR Productions
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #6 on: 2012-02-12 21:29:43 »
I did but I have the old sounds now. At least I can listen to them...

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #7 on: 2012-04-17 16:32:44 »
There is nothing wrong with this program, it seems you didn't use it properly.  You have to make sure the files are in the folder it created and then encode once you have swapped them for your own making sure all files exist and correctly named.  You didn't do that which is why there was an issue.
« Last Edit: 2012-04-17 18:41:12 by DLPB »

LeonhartGR

  • *
  • Posts: 2577
  • ~Whatever...~ Enjoy life!
    • View Profile
    • LeonhartGR Productions
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #8 on: 2012-04-18 01:34:21 »
There is nothing wrong with this program, it seems you didn't use it properly.  You have to make sure the files are in the folder it created and then encode once you have swapped them for your own making sure all files exist and correctly named.  You didn't do that which is why there was an issue.

That's an old post. I already solved it... Thanks anyway! :)

earth

  • Guest
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #9 on: 2012-08-15 18:32:44 »
Tried using this with the new FFVII PC re-release. Found an issue.

I placed sfxEdit in the same folder with audio.dat and audio.fmt, and I get error "Fatal error: cannot open registry". I also tried placing sfxEdit separate from this folder, and still the same error. Please fix.

You'll need to release some sort of config file so we can set the path of the folder for the two files, that should fix the issue.
« Last Edit: 2012-08-15 18:40:31 by earth »

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #10 on: 2012-08-15 18:33:53 »
Yeah, it can do without the "please fix" message at the end, it comes across as rude.  At least it does to me.  He will fix it when he has the time. He is busy at the moment, so you may be waiting a while.

orugari

  • *
  • Posts: 4
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #11 on: 2014-02-09 16:06:06 »
Somehow I changed source for make it works with the re-release... Maybe?
Cause I have no clue about how to compile the source code... I am a web developer... And only that.

getFFPath() would be useless now, the soft may work if you put sfxEdit.exe in the same folder as audio.dat / audio.fmt

So if someone can compile it and give it a try?
http://www.webdellarte.com/update/ff7/sfxEdit.exe.cpp
« Last Edit: 2014-02-10 23:16:10 by orugari »

luksy

  • *
  • Posts: 375
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #12 on: 2014-02-10 00:34:15 »
I can have a look at rewriting it, it's not a very big app as I'm sure you noticed. I'll just make it accept a direct path instead of reading the registry, the reg hooks can be called by a batch script instead if necessary.

orugari

  • *
  • Posts: 4
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #13 on: 2014-02-10 04:35:24 »
Yeah, I just have no idea how to make it as an exe, but i'd love to do it by myself ^^'
I am using windows, is there a software available to do that? :o

Kranmer

  • *
  • Posts: 766
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #14 on: 2014-02-10 21:25:49 »
If you want to compile the source on windows into a EXE, first download Mingw (i recommend "mingw-get-inst-20120426.exe" you can google it)
Install that with options ticked for C, C++, objC, Msys (you can ignore the rest)
Run Mingw Shell from your start menu once. Then close it.
Now go to (by default or change this to where you installed it)
C:\MinGW\msys\1.0\home
and there should be a folder with your windows username, open that folder so you are in
C:\MinGW\msys\1.0\home\Username
now copy all the source files from SfxEdit to that folder (common.h, Makefile, sfxEdit.exe.cpp, sfxEdit.exe.h)
Now open Mingw Shell again from your start menu and type
make
press ENTER
Then it will compile the source into a windows EXE (this works fine with the original source, i recommend trying this with the original source first to make sure it works for you then trying it with your personal edits)

orugari

  • *
  • Posts: 4
    • View Profile
Re: [WIP] sfxEdit 0.2 --- sound effects dumper / encoder
« Reply #15 on: 2014-02-10 23:15:30 »
Oh, Thank you so much !
And here we go, it is working with sfxEdit.exe in the same folder as audio.dat / audio.fmt!
I get the "files" folder with all the wav files :)

Again, thank you luksy for this soft, thank you Kranmer for your explanation!
http://www.webdellarte.com/update/ff7/sfxEdit.exe

Edit: the encode method give me an error: incomplete character in file
I don't really have a clue about what is it :(
« Last Edit: 2014-02-11 00:12:11 by orugari »

luksy

  • *
  • Posts: 375
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #16 on: 2014-02-13 05:23:53 »
New version here, the tool is split into two separate exes for dumping and packing, and all files must be specified on the commandline, i.e.:

sfxdump.exe foo/bar/audio.fmt foo/bar/audio.dat wavdir

Note that the dir (wavdir above) must be created beforehand, because I'm lazy.

Dr. Zaius

  • *
  • Posts: 12
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #17 on: 2014-02-18 08:26:31 »
Could someone explain this to me in lamens terms. I have no idea what I'm doing and all I want to do is install the "new sound fx" files to my "audio.dat". I tries to use the sfx edit programs but the close as soon as I open them and nothing happens. Someone please just explain to me how to do it, and please keep it simple, I'm new to modding ff7.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #18 on: 2014-02-18 11:54:20 »
Look at the readme, and then go and look up how to use the command line.

luksy

  • *
  • Posts: 375
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #19 on: 2014-02-18 12:37:12 »
What he said :D I might make a GUI if I can be bothered.

Dr. Zaius

  • *
  • Posts: 12
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #20 on: 2014-02-18 16:36:17 »
I'm not trying to be rude, but I already read the readme and it doesn't do a very good job of explaining it so a noob like me can understand. I wouldn't ask if I didn't need the help.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #21 on: 2014-02-18 16:44:55 »
You need to learn how to use the command line.  There are tons of easy tutorials online.  Without knowing the command line you are always going to be at a disadvantage with certain programs.

Dr. Zaius

  • *
  • Posts: 12
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #22 on: 2014-02-18 17:21:52 »
OK, I'll have to look into that. For now I'm just going to do the files 1 by 1 using cosmo.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #23 on: 2014-02-18 17:23:36 »
Unless someone here wants to create you a batch file(anyone?).  Which would do the command line stuff for you.

luksy

  • *
  • Posts: 375
    • View Profile
Re: sfxEdit 0.3 --- sound effects dumper / encoder
« Reply #24 on: 2014-02-19 03:32:48 »
Code: [Select]
@echo off
SETLOCAL EnableDelayedExpansion

set key="HKLM\SOFTWARE\Square Soft, Inc.\Final Fantasy VII"
set value=AppPath
set fmt=audio.fmt
set dat=audio.dat
set target=sfx

REG QUERY %key% /v %value% > nul 2>&1

if not ERRORLEVEL 1 for /f "skip=2 tokens=3" %%s in ('REG QUERY %key% /v %value%') do (
set fmt=%%s\data\sound\!fmt!
set dat=%%s\data\sound\!dat!
) else echo Using files in local folder

md %target% > nul 2>&1

choice /c dp /n /m "[d]ump or [p]ack?"

if ERRORLEVEL 2 sfxpack %fmt% %dat% %target%
if ERRORLEVEL 1 sfxdump %fmt% %dat% %target%

Does Steam store the path in the registry as well? I suppose it must store a base path to Steam itself, I can search there too.
« Last Edit: 2014-02-19 03:40:56 by luksy »