Difference between revisions of "How to generate voice files by batch"

From the CreationKit Wiki
Jump to navigation Jump to search
imported>Jog
imported>RandyConstan
m (removed extra line break)
 
(2 intermediate revisions by the same user not shown)
Line 8: Line 8:
This will load the specified ESM and generate LIPs for every dialogue line for which there is a loose WAV file under
This will load the specified ESM and generate LIPs for every dialogue line for which there is a loose WAV file under
'''Data/Sound/Voice/YourMod.ESM/'''
'''Data/Sound/Voice/YourMod.ESM/'''
You can also generate a single .LIP file for an existing WAV using this command:
CreationKit32.exe -GenerateSingleLip:"Data\Sound\YourCustomVoice.wav" "Another settlement needs your help."
Note: the '''Data/Sound/Voice/Processing/FonixData.cdf''' file must exist to successfully generate lip files. This file is created when the Creation Kit is installed.


==XWM Files==
==XWM Files==

Latest revision as of 18:43, 31 May 2019

For a mod with a lot of dialogue it can be a pain to manually create all files in the CK. It may be easier to batch-generate some or all of the required files. Skyrim uses the FUZ format which combines the actual audio recording in XWM format and the LIP file. To generate these files by batch, a couple of tools are required:

LIP Files[edit | edit source]

LIP files contain the lipsync data and can be generated using the Creation Kit itself.

CreationKit.exe -GenerateLips:YourMod.esm

This will load the specified ESM and generate LIPs for every dialogue line for which there is a loose WAV file under Data/Sound/Voice/YourMod.ESM/

You can also generate a single .LIP file for an existing WAV using this command:

CreationKit32.exe -GenerateSingleLip:"Data\Sound\YourCustomVoice.wav" "Another settlement needs your help."

Note: the Data/Sound/Voice/Processing/FonixData.cdf file must exist to successfully generate lip files. This file is created when the Creation Kit is installed.

XWM Files[edit | edit source]

XWM is an audio format that can be generated from WAVs using Microsoft's xWMAEncode from the Direct X SDK (The download is a SFX ZIP-file, xWMAEncode.EXE can be found under Utilities/Bin/x86) http://www.microsoft.com/download/en/confirmation.aspx?id=6812

xwmaencode "my_voice_file.wav" "my voice file.xwm"

This will convert the WAV file into a XWM file.

To create XWM files outside a batch file you can use this tool instead: http://skyrim.nexusmods.com/downloads/file.php?id=3159

FUZ Files[edit | edit source]

FUZ is a container format that combines XWM and LIP it can be created using Agnahim's Voice File extractor. http://skyrim.nexusmods.com/downloads/file.php?id=950

fuz_extractor -c "my_voice_file.fuz" "my_voice_file.xwm" "my_voice_file.lip"

Will convert the XWM File and the WAV file into FUZ file as used by Skyrim,


Batch generation[edit | edit source]

With all tools available, all that is left is creating a batch file that will automatically generate all the FUZ files required by your mod.

Save all your WAV files into a sub-folder of Data/Sound/voice that is named like your mod. (e.g. Data/Sound/Voice/YourMod.ESM/)

Copy xwmaencode.exe and fuz_extractor.exe to that folder (or add them to a folder that is in your commandline-path).

Finally create a new text file in that folder, copy/paste in the following code and rename it to "voice-tool.bat"

for /f "delims=\" %%a in ("%cd%") do set mod=%%~nxa
Start /WAIT ..\..\..\..\CreationKit.exe -GenerateLips:%mod%
FOR /R %%a IN (*.wav) DO xwmaencode "%%a" "%%~pa%%~na.xwm"
FOR /R %%a IN (*.xwm) DO fuz_extractor -c "%%~pa%%~na.fuz" "%%a" "%%~pa%%~na.lip"

When you start the batch file, it will first follow the directory structure to find the name of the topmost folder (which is equal to your mod's name) then it uses the Creation Kit to generate the lip files. The next step is to convert every WAV file in the folder to XWM, and finally all LIPs and XWMs in the folder are combined to FUZs.