-
-
Notifications
You must be signed in to change notification settings - Fork 39
Split chapter MP3 audio chapter file into verse files
If you have a MP3 audio chapter file of the Bible and want to split it into verse files, follow the below instructions.
- Install ffmpeg
-
Create a data directory in the UBA folder
-
Put verse info file in the data folder and optionally put the chapter mp3 file in the data directory
-
If your mp3 chapter file already exists under the audio/bibles folder, you do not need to put it into the data folder.
-
The verse info file must be in the data folder and should contain lines with the following format:
{ label: "1", start: 6, end: 10.99 },
The label is the verse number and start is where the verse starts. The end is required, but not used.
The file can contain other lines (such as html or javascript code), so you can include an entire html file that has the above info in a javascript block.
- In the UBA folder, run:
If your mp3 file is under the audio/bibles folder:
- python -m tools.SplitMp3File audio/bibles/[Bible]/default/[Book number]/your_mp3_file data/your_data_file [Bible] [Book number] [Chapter number]
If your mp3 file is in the data folder:
- python -m tools.SplitMp3File data/your_mp3_file data/your_data_file [Bible] [Book number] [Chapter number]
Examples:
- python -m tools.SplitMp3File audio/bibles/MOV/default/41/41_Mark001.mp3 data/mal-41-MRK-001.html MOV 41 1
- python -m tools.SplitMp3File data/40_Matthew001.mp3 data/40_1.data KJV 40 1
The verse files will then be created under the /audio/bibles/[Bible]/default directory