Last Shout - Posted by: Bernie - Sep. 09, 2020, 04:40:16 PM
WTF is up NW?!!!! ;D
Downloads Area

Downloads->PC Engine/TurboGrafx-16 Related Utilities->TocFixer v1.01 (for ISO/MP3/CUE archives) [ Search ]

TocFixer v1.01 (for ISO/MP3/CUE archives)
Name TocFixer v1.01 (for ISO/MP3/CUE archives)
Description A joint project between Squaresoft74 and myself resulted in what we hope will be the mother of all solutions to the dreaded ISO/MP3 archives that have plagued us for so long. This tool, using Square's TOCDB data, will resize MP3 decoded wave files back to their original file sizes, thus restoring the TOC of the image to what it should be.

OK, so you've downloaded that crappy ISO/MP3/CUE archive from some site, IRC channel, or newsgroup, but after decoding the MP3s to waves, then mounting or burning the image thereafter to play it, you find it's unstable... It crashes, and/or there are lip-syncing issues during the cinemas, etc. So why is that? Well, it's quite simple. Early in the PC-Engine pirating scene, the idea of using lossy encoders such as MP3 for the redbook audio tracks took off like wildfire because of the huge compression ratios one was able to achieve. This allowed for easy distribution over the Internet obviously. The problem, however, is that when a MP3 decoder decodes the wave back, it doesn't restore the wave file's original size. That is, the size in bytes the wave originally had before it underwent MP3 encoding. So what happens when you've decoded your MP3s to waves and now you've got your ISO/WAV/CUE image file set mounted with daemon tools or you try to burn it? Well, the offset of where every audio track begins will be different, again, since the waves don't have their original file size. Never mind the lossiness of the encoding process. That's not the issue! The issue is that most game code has the LBA offset hard-coded, which is what's used when it wants to play an audio track. However, there are some games that will dynamically examine their own TOC at runtime when it's time to play the next audio track, but they're few and far in between such as "Ys IV: The Dawn of Ys." Such images would have none of the above aformentioned problems discussed so far. But anyhow, there's your background information on why the vast majority of ISO/MP3/CUE archives suck as a means for archiving PC-Engine CD-ROMs.

Now, how does TocFixer address this problem? Well, it's compiled with a TOC database of PC-Engine CD-ROMs collected by Squaresoft74 from original silver owners. With this data, I know exactly how many bytes in size each of your track files should be, both for wave and ISO. So, with that info, this application will check your ISO and wave files in the folder you select against the verified TOC data and resize the files if necessary. Resizing ISO files is no sweat, but wave files are given extra special attention. The header will be checked to ensure you decoded it correctly. Trailing bytes, should they be present, will be removed before the final resizing attempt. And finally, it will not resize the file such that by default, no more than 3 seconds of audio will be lost, which equals 529,200 bytes. That's pushing the limits, but if that much audio needs to be cut off, there's likely something very wrong with the wave to begin with. Same goes if the file has to be enlarged by more than 529,200 bytes.

So, while I hope this tool will decrease all the tech support problems I and others have had to deal with over the years with those unfortunate enough to have obtained crap ISO/MP3/CUE archives, I am conflicted in offering this tool to the public. I've been strongly advocating the image storage scene adopt, at the very least, lossy encoders such as OGG that restore the wave to its original file size. As a result, they work perfectly, with none of the issues of ISO/MP3/CUE archives. By releasing this tool, I'm objectively supporting the continued usage of ISO/MP3/CUE archives and I'd like to make it clear, that is far from my willful intention. I still wanna see them all nuked, of course. This tool is intended to fix existing archives, not hinder progress towards using OGG and the like. So please, while you may be stuck with an ISO/MP3/CUE archive for now, if you're gonna create new archives, please use OGG at the very least. It achieves just as good lossy compression as MP3, minus all the headaches... Finally, this tool, while created with ISO/MP3/CUE archives in mind, doesn't have to be limited to just that purpose. This tools lends itself as an overall ISO/WAV/CUE image file set verifier. You can use it to check your existing PC-Engine CD-ROM images in general, regardless of what original lossy audio encoder was used. If you're using the latest MagicEngine 1.X emulator, you'll notice that when you click PCECD in the boot CD menu, at the bottom status bar, a full title of the game will appear if the CD can be correctly identified. If a title does appear, that means your CD's TOC is just fine. But if NO title is shown, that means your TOC has been damaged by the MP3 decoding process and you should run this tool to attempt to fix it. Hope that helps.

Well, good luck,

- NightWolve, Squaresoft74

** Instructions **

Usage should be a snap. Basic rundown is this:

1. Run TocFixer by double clicking it.
2. Select the game title from the dropdown combobox that you wish to repair.
3. Click the Browse button to then find the folder that contains the ISO and
wave files that you wish to repair (The files that match the game title
you selected in step 2). Next, simply select any one of the files and
click Open.
4. Check the status output. If it informs you the image is unstable, click
the Repair button to begin the process.
5. Monitor the status output for any other errors that might turn up. If the
process is successful, a new CUE file will be opened up for you in
notepad. You're now ready to mount that CUE file and/or use it to burn
the image for testing. Good luck, ya heathen.

** Version History **

Version 1.01 (12/31/2005):

+ Fixed a critical issue where if the file is being enlarged, the contents of
the file between the old EOF (End-Of-File) position and the new position
are undefined. Basically, all bytes appended to a file - to grow it - will
definitely be 0x00, rather than undefined. Using the prior method, the file
could be grown quickly, gigabytes in a matter of seconds, but whatever data
is on the harddrive at the time is what's allocated to the file as is. For
an audio file, when enlarged, such a method would produce static at the end.
+ Added support for saving the last folder that track files were loaded from.
+ Edited instructions slightly on main screen.

Version 1.00 (8/13/2005):

+ Generates a default reliable CUE file for use with daemon tools or any CDRW
burning software that supports CDRWIN's CUE format.
+ Added full wave header verification. The tool will not blindly resize your
wave. It will check if the 44 byte header is proper for what's expected for
a CD. If it's not a 44,100 Hz 16-bit stereo wave, it will abort the resizing
attempt and warn you. You'll have to properly convert your waves or obtain
them from a better source in such an event.
+ Added a basic failsafe where if the number of track files in your selected
folder found is not equal to the expected track files of the game title you
selected, the program will abort and warn you of the mismatch/error.
+ Any trailing bytes found present in a wave will automatically be removed.
+ Added a wave resize limit. Basically, if the tool finds that you must resize
a wave beyond the default setting of 3 seconds of audio, it will abort the
resize attempt and warn you that you need to find a better quality source.
In other words, something is really wrong with the wave file if you need to
resize it by that much. (For a CD-quality, 44.1KHz 16-bit stereo wave, three
seconds of audio equals 529,200 bytes.)
+ Improved the scrolling for the status text box.
+ Fixed a bug where a WINAPI didn't work as expected in Win98SE, so it should
now work reliably on all Windows® platforms (9X/NT/2K/XP).
+ Fixed a bad character used in a game title for Square's TOC database.
"Linda ┬│ (J)" will now show up properly.
+ Added an About box.
+ Code is highly optimized. The default VC++ runtime engine is not used.
Instead, I use a small custom runtime engine I prefer to compile with that
results in a much smaller and quicker executable, along with the fact that I
sacrifice ANSI portability by calling Windows APIs directly for speed gains.

The Demo Shots:

Sent by NightWolve
Size 67.05 Kb
Votes Votes: 8 - Average: 3.38

Screenshots Preview 1     Preview 2
Demo URL -
Download File
Download File Add a Comment Rate
Jun. 17, 2006, 03:12:21 PM
Hey, thanks for the comment. I didn't notice it till now. Yeah, this program as well as TurboRip are companion tools for dealing with PC-Engine/TG-16 discs and images. They're both pretty much end-all/be-all solutions and I'm glad to finally have closed the book on the MP3 issue.
Jun. 02, 2006, 10:22:57 PM
I can identify with your hatred of ISO/MP3 and agree they should be nuked (if a group had resampled video and audio from Halo just so they could upload it faster, heads would have rolled). You shouldn't be so hard on yourself acting like you're perpetuating the problem by releasing TOCFix though, people are going to continue to put out garbage because they're lazy and ignorant (and because of Hugo's disc dissector), not because you've created a tool that fixes the problem. If anything, you've made more people aware that there is a problem, many probably weren't even aware it exists. I've noticed that Magic Engine can compensate for bad rips to some extent. The first Dracula X I got ahold of wouldn't even play in a real TG16 at all (until I clipped the noise from the end of the tracks). ME ran that misaligned POS just fine though. If the sync is off, most people probably just think it's the developer's fault or chalk it up to the fact that these were the first CD-based games ever made for a console. The current Turbografx emulator of choice for Xbox (mednafenx_pce) even incorporates a TOC database of it's own and asks you to pick the game out of the list the first time you select the .cue sheet (no need to change switches in TurboRip though, this supports ISO/MP3/CUE and CUE/BIN correctly, ironically, Hugo never supported either correctly). With the emulators covering for the deficiencies in this bad format (and Hugo's author condoning it in spite of the fact it can only run Dracula X in "dissected" format without glitching or crashing, only Super CD it seemed to anyway, normal TGCDs might be more stable), the only people who even know they're getting the raw deal are the Turbografx owners. Thanks to you we'll at least be able to play the bad rips from torrents alright while waiting for proper releases to get posted on usenet.

There are 13 files on the Database
Most Downloaded: Ys Typing Tutor Game v0.85
Most Viewed: TurboRip v1.40 - The PC Engine/TurboGrafx-16 CD-ROM ISO/WAV/CUE Ripper!!
Most Rated: Ys I Complete English Patch v1.27

Total users browsing Downloads Area: 1 (0 Registered Members 1 Guest and 0 Anonymous Members)
Members are: