RupertAvery / PSXPackager

A utility to convert Playstation disc images in various formats to PBP format and back
Other
230 stars 15 forks source link

Merging a two-disk game to one pbp #50

Open finnlogin opened 1 year ago

finnlogin commented 1 year ago

Hi there!

I tried to convert Abe's Exoddus to PBP format using your utility, but unfortunately without success so far. The game consists of two disks (cue + bin). Thus, four files in total need to be merged. Following your instructions, I created an m3u file with the following lines, which I saved in the files directory:

Oddworld - Abe's Exoddus (USA) (Disc 1).bin
Oddworld - Abe's Exoddus (USA) (Disc 1).cue
Oddworld - Abe's Exoddus (USA) (Disc 2).bin
Oddworld - Abe's Exoddus (USA) (Disc 2).cue

The PBP file was created, but it doesn't work on my PS Vita. Apparently, I did something wrong. Could you please help me figure out how to create a valid PBP file ? I would appreciate any help in this matter.

Viacheslav

RupertAvery commented 1 year ago

Sorry for the delay!

You should just put the .cue file. The .cue file references one or more .bin files per disc (a .bin can either be data or audio - the .cue is a text file that says what sector the .bin is located in a disc)

MeatballSub commented 8 months ago

Command line seems to have issues, but GUI is working fine for me. Potentially, I just don't know enough about what I need for a command line...

$ psxpackager.exe -i "Driver 2.m3u" PSXPackager v1.6.2 by RupertAvery

Input : Driver 2.m3u Output: Compression Level: 5

Processing started: 12:29:14 Processing Driver 2.m3u Found 2 entries Found SLUS01161 "Driver 2 - Disc 1" Found SLUS01318 "Driver 2 - Disc 2" Using Title 'Driver 2' Writing Disc 1 - Unhandled exception. System.IO.IOException: The handle is invalid. at System.ConsolePal.set_CursorVisible(Boolean value) at System.Console.set_CursorVisible(Boolean value) at PSXPackager.ConsoleNotifier.Notify(PopstationEventEnum event, Object value) at PSXPackager.AggregateNotifier.Notify(PopstationEventEnum event, Object value) at Popstation.Processing.ProcessFile(String file, ProcessOptions options, CancellationToken cancellationToken) at PSXPackager.Program.ProcessFiles(ProcessOptions options) at PSXPackager.Program.<>c__DisplayClass2_0.

b__0(Options o) at CommandLine.ParserResultExtensions.WithParsed[T](ParserResult1 result, Action1 action) at PSXPackager.Program.Main(String[] args)

$ cat Driver\ 2.m3u Driver 2 (USA) (Disc 1).cue Driver 2 (USA) (Disc 2).cue

$ cat "Driver 2 (USA) (Disc 1).cue" FILE "Driver 2 (USA) (Disc 1).bin" BINARY TRACK 01 MODE2/2352 INDEX 01 00:00:00

$ cat "Driver 2 (USA) (Disc 2).cue" FILE "Driver 2 (USA) (Disc 2).bin" BINARY TRACK 01 MODE2/2352 INDEX 01 00:00:00

RupertAvery commented 8 months ago

System.IO.IOException: The handle is invalid. at System.ConsolePal.set_CursorVisible(Boolean value)

This doesn't seem to be an issue with the processing code. It looks as if its with the Console displaying the progress. What OS / shell are you running it on?

MeatballSub commented 8 months ago

System.IO.IOException: The handle is invalid. at System.ConsolePal.set_CursorVisible(Boolean value)

This doesn't seem to be an issue with the processing code. It looks as if its with the Console displaying the progress. What OS / shell are you running it on?

Windows 11 MSYS2 terminal that comes with git for windows Windows PowerShell works Command Prompt also works

Consider me surprised that choice of terminal affects this.

I'm usually more comfortable with command line utilities, and I had intended to wrap the call in a loop in a bash script. However, when I experienced the issue, I took a look at the gui, and found you'd already created a batch mode that served my purposes nicely(even looks like it might be parallelized, nice touch!)

RupertAvery commented 8 months ago

Great to hear. In case I'd ever want to fix or workaround this, it seems to be related to IsOutputRedirected.

https://github.com/dotnet/runtime/issues/28625#issuecomment-460736213

I actually thought of parallelization in the CLI, it's just that displaying parallel updates would have been challenging.