VOGONS

Common searches


Best way to create ISO+OGG images?

Topic actions

Reply 20 of 30, by Stiletto

User metadata
Rank l33t
Rank
l33t
Neville wrote:

Sorry about that. I thought that being a freeware program all would be OK. Is it OK if I provide a link to another website carrying the program instead?

If it really/truly doesn't have any viruses, and was freeware, it's fine to link.

"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto

Reply 23 of 30, by pantercat

User metadata
Rank Newbie
Rank
Newbie

I've written a small bash script that extracts the data track to iso, the audio tracks to wav, converts the wav files to ogg files and generates the cue file. It should work on any linux distro with bchunk and vorbis-tools packages installed.

#!/bin/bash
# isoogg.sh v0.3
# Usage: ./isoogg.sh file.bin file.cue

die() {
echo -e "$@"
exit 1
}

which /usr/bin/bchunk &>/dev/null || die "\nbchunk not found. Try: (as root) apt-get install bchunk\n"
which /usr/bin/oggenc &>/dev/null || die "\noggenc not found. Try: (as root) apt-get install vorbis-tools\n"

SELF=$(basename $0)

[ "$#" -ne 2 ] && die "\nUsage: $SELF [BIN_file] [CUE_file]\n"

BIN_FILE="$1"
CUE_FILE="$2"
NO_EXT="$(echo "$1" |sed 's/\.[^\.]*$//')"

[ ! -f "$BIN_FILE" ] && die "\n$BIN_FILE not found."
[ ! -f "$CUE_FILE" ] && die "\n$CUE_FILE not found."

grep "2 AUDIO" "$CUE_FILE" &>/dev/null || die "\n$BIN_FILE do not have audio tracks."
egrep -ie "FILE .* MP3|OGG|OPUS|FLAC" "$CUE_FILE" &>/dev/null && die "\n$CUE_FILE already have compressed audio tracks."

[ -f "$NO_EXT".iso ] && die "\n$NO_EXT.iso already exists"

/usr/bin/bchunk -w "$BIN_FILE" "$CUE_FILE" "$NO_EXT"

/usr/bin/file "$BIN_FILE" |grep "ISO 9660"

if [ "$?" -eq 0 ]; then
echo -e "\nWarning: File $BIN_FILE is really an ISO-9660."
mv "$NO_EXT"01.ugh "$NO_EXT".iso
else
mv "$NO_EXT"01.iso "$NO_EXT".iso
fi

[ ! -f "$CUE_FILE".bak ] && mv "$CUE_FILE" "$CUE_FILE".bak

echo "FILE \""$NO_EXT".iso\" BINARY" >"$CUE_FILE"
echo " TRACK 01 MODE1/2048" >>"$CUE_FILE"
echo " INDEX 01 00:00:00" >>"$CUE_FILE"

for FN in *.wav; do
/usr/bin/oggenc "$FN" -q 6 -o "${FN%.wav}.ogg"
rm "$FN"
done

i=2
for FN in *.ogg; do
echo "FILE \"$FN\" MP3" >>"$CUE_FILE"
(("$i" < 10)) && echo " TRACK 0$i AUDIO" >>"$CUE_FILE" || echo " TRACK $i AUDIO" >>"$CUE_FILE"
echo "$FN" |grep "02.ogg$" &>/dev/null && echo " PREGAP 00:02:00" >>"$CUE_FILE"
echo " INDEX 01 00:00:00" >>"$CUE_FILE"
((i++))
done

echo "The $BIN_FILE and $CUE_FILE.bak files are no longer needed. You can delete them."
Show last 4 lines
echo "Copy the files $NO_EXT.iso $CUE_FILE and *.ogg to the game directory and mount $CUE_FILE"

#rm "$BIN_FILE"
#rm "$CUE_FILE".bak
Last edited by pantercat on 2020-10-18, 12:02. Edited 8 times in total.

Reply 25 of 30, by pantercat

User metadata
Rank Newbie
Rank
Newbie

Yes. Well, this is not optimal, it would be advisable to do something similar in powershell (or a GUI) but it can be done and it works. I have made some small changes to the script to work in windows with win-bash.

Download and extract.
Copy the BIN and CUE files to the same folder where isoogg_win.7z has been extracted
Double click on start_shell.bat
Should open a window with a bash shell
Now type:
./isoogg.sh file.bin file.cue
or
./isoogg.sh "file with spaces.bin" "with spaces.cue"

Wait ~ 1 minute and if the bin file has audio tracks we will have in the same folder file.iso, file.cue and *.ogg

I've tested it on Windows 7 Pro SP1 x64

-----
Alternatively you can copy only isoogg.sh from download above and get the rest of the files from the original sources. You'll need these files:

https://ftp.osuosl.org/pub/xiph/releases/vorb … ls-win32-bin.7z
*.dll
oggenc.exe

https://github.com/extramaster/bchunk/release … 2.1_repub.1.zip
bchunk.exe

https://sourceforge.net/projects/win-bash/fil … latest/download
*.dll
bash.exe
echo.exe
grep.exe
ls.exe
mv.exe
rm.exe
sed.exe
start_shell.bat

Last edited by pantercat on 2018-09-08, 07:41. Edited 1 time in total.

Reply 26 of 30, by collector

User metadata
Rank l33t
Rank
l33t

A few years back I started writing a tool that was a frontend for CDRTools that could could rip/compress CDA tracks and make ISOs of CDs, and generate/edit CUE sheets for DOSBox. It was also a simple frontend for DOSBox. I gave it up since there was not much interest in it.

DOSBoxCDUtilities.png
Filename
DOSBoxCDUtilities.png
File size
102.87 KiB
Views
587 views
File license
Fair use/fair dealing exception
Rip.png
Filename
Rip.png
File size
40.76 KiB
Views
587 views
File license
Fair use/fair dealing exception
Image.png
Filename
Image.png
File size
36.52 KiB
Views
587 views
File license
Fair use/fair dealing exception

The Sierra Help Pages -- New Sierra Game Installers -- Sierra Game Patches -- New Non-Sierra Game Installers

Reply 27 of 30, by olddos25

User metadata
Rank Member
Rank
Member

Well, you should continue it in some form or another. It has the potential to be pretty useful!

Currently mod on several Discord servs and a forum, so you can trust me if you want a DOSBox mod here!
Other places to find me:
DraStic: http://drastic-ds.com (as dsattorney)
EPForums: http://www.epforums.org (as emulationfan)

Reply 28 of 30, by MKSheppard

User metadata
Rank Newbie
Rank
Newbie
pantercat wrote on 2018-09-07, 11:18:
Yes. Well, this is not optimal, it would be advisable to do something similar in powershell (or a GUI) but it can be done and it […]
Show full quote

Yes. Well, this is not optimal, it would be advisable to do something similar in powershell (or a GUI) but it can be done and it works. I have made some small changes to the script to work in windows with win-bash.

Download and extract.
Copy the BIN and CUE files to the same folder where isoogg_win.7z has been extracted
Double click on start_shell.bat
Should open a window with a bash shell
Now type:
./isoogg.sh file.bin file.cue
or
./isoogg.sh "file with spaces.bin" "with spaces.cue"

Wait ~ 1 minute and if the bin file has audio tracks we will have in the same folder file.iso, file.cue and *.ogg

I've tested it on Windows 7 Pro SP1 x64

I've tested it on Windows 10 x64, with whatever was the current version in August 2020 and it works.

I'll rehost your file on my website later, if that's OK with you, so people don't have to go to ad-infested download sites.

Reply 30 of 30, by Akuma

User metadata
Rank Member
Rank
Member
pantercat wrote on 2020-10-17, 16:48:

Sure, do whatever you want with the code.

I'm glad it's useful to you. 😀

Do you want to check out mine 😉 ?
BIN/CUE to ISO/CUE converter v1.06, supports : FLAC,MP3,OGG,OPUS (script)