Hi everyone
Jurgen (Chief of Jomox) recommends loading samples in RAW format. I’m not exactly sure why, but RAW files are definitely a bit smaller.
Therefore, I’ve created a script for SoX that converts samples to the appropriate size.
This version works well enough, so I’m releasing it now. Future versions will be more flexible.
Unfortunately, I’m not very comfortable with PowerShell. The automatic output of function values and the conversion of data types are giving me trouble.
I’ll probably need some time to get the hang of it.
Usage:
First, SoX needs to be downloaded, installed, and added to the environment variables as described in the following thread.
After that, the script can be used. The .bat files are provided for this purpose and can be configured as follows:
-
Default: Configuration file, source folder, and destination folder must be selected in dialog boxes:
powershell -ExecutionPolicy ByPass -File Core\SimpleSoXAudioBatchConverter.ps1 -
This loads a configuration file; you only need to select the source and destination folders in the dialog boxes:
powershell -ExecutionPolicy ByPass -File Core\SimpleSoXAudioBatchConverter.ps1 -configuration "C:\Path to configuration file ...\x.ssabcc" -
This loads the configuration file, source folder, and destination folder, and the conversion can be started directly; no dialog boxes appear.
If “-recursive” is set to “True”, subfolders in the source folder are also included:
powershell -ExecutionPolicy ByPass -File Core\SimpleSoXAudioBatchConverter.ps1 -source "C:\Source folder" -recursive True -destination "C:\Destination folder" -configuration "C:\Path to configuration file ...\x.ssabcc"
Configuration files:
The configuration file “.ssabcc” contains the settings for the conversion. “AlphaBase.ssabcc” is pre-configured for the Alpha Base.
If you don’t want to normalize and trim, you can simply delete the entries. Basically, only the settings that are entered will be executed.
Ensure the values are correct, as file validation is not yet implemented.
To test the trimming values, you can first convert to WAV files and listen to see if the result is satisfactory, and then convert to RAW.
If “Normalize” is enabled, “NoDither” should also be enabled; otherwise, clipping may occur.
Simple SoX Audio Batch Converter (0.3 beta).zip (9.2 KB)
Have fun with it! I would appreciate any feedback or suggestions for improvement.