Jump to content
LaunchBox Community Forums

Bulk Convert .cue/.bin (or files other than .bin) to .chd


Recommended Posts

Bulk Convert .cue/.bin (or files other than .bin) to .chd

View File

Bulk Convert .cue/.bin (or files other than .bin) to .chd

Using MAME’s chdman.exe (“Compressed Hunks of Data (CHD) Manager”, included with MAME), this plugin will convert CD based game files to a single .chd file in your selected Platform.  Example:

Before    Loom (USA).cue     Loom (USA).ccd     Loom (USA).img     Loom (USA).sub
After       Loom (USA).chd
Before    Arctic Thunder.cue     Arctic Thunder.bin
After       Arctic Thunder.chd

 

Why convert?

  • You end up with just a single file per game
  • A CHD file is, well… compressed. Resulting in less storage space requirements
    • Arctic Thunder.cue + .bin = 601MB    Arctic Thunder.chd = 466MB
    • Spider-Man 2: Enter Electro = 684MB    CHD format = 318MB
  • Because we can and it's easy to do


Requirements

  • This plugin file
  • chdman.exe (included with MAME)
  • Game rom-sets that include a .cue file. (Loom (USA).cue, Arctic Thunder.cue etc.)

 

What happens after converting?
After successfully creating a CHD Image, the games application path will be changed to the new .chd file.

Also, after the files have been converted you have the option to 

  • Leave the old files in place (default)
  • Move the old files to a separate [backup] folder
  • Delete the old files
     

 

Installing the plugin

  1. Download the plugin
  2. Unblock “cue2chd (v1.00).zip” by right clicking the file and checking “Unblock” and clicking “OK”.
  3. Open the zip file and copy the contents (1 folder containing 1 file) into /LaunchBox/Plugins/
    • i.e. G:/LaunchBox/Plugins/cue2chd/cue2chd.dll

image.png.85087847d85ef26c747b022235f9e1a3.png

 

Using the plugin

  1. Start LaunchBox
  2. Select Tools, Convert cue to chd
  3. Select a Platform
  4. Click Convert
  5. (Optional)
    • Check Delete old files when complete 
      • This will permanently delete the old files (.cue, .bin, .img etc) after successfully converting them to .chd.
    • Check Move old files when complete
      • This will move the old files (.cue, .bin, .img etc) after successfully converting them to .chd to a folder you specify [for ‘backup’].
         

If you do not select Delete or Move, all files will remain in their current location along with the newly created .chd file. 

 

 If you opt to delete the old files and later want/need to convert the CHD files back to .cue etc., you can use chdman.exe to "reverse the process".  The command line is:

chdman.exe extractcd -i “file_name.chd” -o “file_name.cue”

 

 

Special thanks to @faeran for coming up with the idea for this plugin and his support and testing.

 As always, all comments and suggestions are welcome.


 

  • Thanks 1
  • Unusual Gem 1
Link to comment
Share on other sites

  • 3 weeks later...

For some reason it does not see all the cue+bin files for my images. It looks like it skips them or cant read them. I do not know why? I got no error stating why they were skipped. I have other files that error and it ask me to skip them, but the files that is not see never error out. Other than that excellent tool. Anything I can provide to help determine the problem please let me know.

Link to comment
Share on other sites

8 hours ago, Egnom said:

For some reason it does not see all the cue+bin files for my images. It looks like it skips them or cant read them. I do not know why? I got no error stating why they were skipped. I have other files that error and it ask me to skip them, but the files that is not see never error out. Other than that excellent tool. Anything I can provide to help determine the problem please let me know.

It shouldn't be skipping any games without giving you the popup error message.  Since you are seeing the message [on some of them] tells me you have the latest version (v1.02, released Saturday).  Which is good. :) 

Are the games that are not converting and not showing the error message 'main' games?  Or games that are Additional Apps to a main game?  And are all these games [and Additional Apps] all pointing to a .cue file in their application path [path to the ROM file]?

 

How it works

The plugin looks at each game and its Additional Apps (if any) in your selected Platform, at the games path to the ROM. 

If the ROM file in that path has a file extension of .cue, it sends it to chdman to convert it (the .bin file(s) that particular .cue file references) to a CHD. 

After conversion is 'completed' (chdman exits its process), the plugin checks to see if the [created] CHD file exists.

If the CHD file doesn't exist, something went wrong with the conversion and you get the [generic] error message.

 

I've only heard of one instance where conversions were failing.  The fix was update the version of chdman being used.

Link to comment
Share on other sites

One thing that is common across all the "skipped" images is that the cues that seems to be skipped are multi disc games. I looked thru the message window and I see is scanning the games but not converting them. The other ones that are not multi disc they converted fine. The multi-disc cue does not have all the disc within the cue. is a cue per game disc. Will that be the problem? do I have to put in one cue al the discs?

Link to comment
Share on other sites

14 hours ago, Egnom said:

The multi-disc cue does not have all the disc within the cue. is a cue per game disc.

These should still work fine.  1 CUE per disc.   So your imported games would be something like (4 separate games in LaunchBox)

This_is_a_game_(disc_1).cue
This_is_a_game_(disc_2).cue
This_is_a_game_(disc_3).cue
This_is_a_game_(disc_4).cue

And then in your folder you'd also have something like

This_is_a_game_(disc_1).bin
This_is_a_game_(disc_2).bin
This_is_a_game_(disc_3).bin
This_is_a_game_(disc_4).bin

 

For the multi-disc games, you say you see in the output window that is says "Checking main game This_is_a_game_(disc_1)".  Then right after that, does it say "Converting Complete"?  Or does it go right to saying "Checking Additional Apps...."?

If it doesn't show "Converting Complete" or "Error Converting", then that particular game ("This_is_a_game" in this example) isn't pointing to a CUE file.

Double check that the games path is pointing to a .cue file.  If you had created a .m3u for these multi discs, that won't work for converting.

Are you using the most recent version of chdman.exe?

Link to comment
Share on other sites

8 hours ago, Egnom said:

I have attached to pngs for reference and below is the cue file content for Lunar-Silver Star Story Complete one of my multi disc games. As you can see the converter is reading it but never converst it.

Thanks for the screen shots.  The CUE file appears fine.  Please Edit your game Lunar-Silver Star Story Complete.  Based on the output display, I'm guessing you have (Disc 1) as the main game and (Disc 2) is an Additional App.  Go to the Launching section and share a screenshot of the 1st field, ROM File.

My guess is that it's not point to "Lunar-Silver Star Story Complete (Disc 1).cue".  

Now go to the Additional Apps section and edit the one for Disc 2.  (assuming it's an Additional App) Check the Application Path.  Is it pointing to "Lunar-Silver Star Story Complete (Disc 2).cue"?

If my guess is correct, they both do not point to file_name.cue.  (quite possibly they point to .chd? [which doesn't exist]).  If that's the case, change the file extensions [back] to .cue, save and run the plugin again.

If that's not the case and/or it doesn't resolve the issue, we'll look at Plan "B".

Link to comment
Share on other sites

awesome tool, can't wait to give it a try!  Are there any emulators that don't like chd files?  iu'd hate to convert to then find out my emu wont read the file.  maybe we could come up with a reference guide for CD based systems, which emu's will work with chd's, which won't?

thanks again!

  • Thanks 1
Link to comment
Share on other sites

5 minutes ago, Egnom said:

Now it sees it but it errors out. Is there a reason an image will error out. 

It will show that error when chdman fails to convert the file.  This is where plan "B" comes into play...

 

Open the Windows Command Prompt to where your cue/bin files are located and run the command

"d:\Mame\chdman.exe" createcd -i "filename.cue" -o "filename.chd"

Change (inside, and keeping the quotes) the full path to where your chdman.exe file is located.  also change (again... inside, and keeping the quotes) "filename" (2 locations) of the cue file you're converting.  i.e.

"d:\Mame\chdman.exe" createcd -i "Lunar-Silver Star Story Complete (Disc 1).cue" -o "Lunar-Silver Star Story Complete (Disc 1).chd"

 If (when?) it fails here, it should give an indication as to why.

 

You didn't by chance simply rename your m3u to cue?  That won't work unfortunately.  You need to have all the different discs imported into LaunchBox and pointing to their respective game_name (Disc #).cue files.

Link to comment
Share on other sites

9 hours ago, latin625 said:

Great Plugin! Using it now!  Any way to auto skip to next game when it encounters an error?

Thanks! Glad you're liking it.

There's currently no option to automatically go to the next game when an error occurs. 

My thinking is:  if there's an error converting, it's most likely you're using an older/outdated version of chdman.exe.  (Other issues are possible, but this seems to be to most common one.)  So you get the popup message and [optionally] attempt the next game.  After seeing 2 or 3 of these error messages in a row, rather than attempting to convert [and failing?] the next 120 games, you can quit scanning and resolve the issue causing conversions to fail.

 

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...