Hi!
There is an interesting new ticket about UDVD2 on github.
It seems that implementing a very specific detail of what MSCDEX expects
CD-ROM drivers to do might improve compatibility with games like Rayman.
See the text of the ticket below. Thanks to PluMGMK for their thoughts.
Regards, Eric
PluMGMK created an issue:
https://gitlab.com/FreeDOS/drivers/udvd2/-/issues/5
First of all, let me say that it's great to see a "modern" DOS driver
that still implements audio functionality for CD-ROM drives!
But there is an issue with the way the STOP AUDIO request is handled.
The MSCDEX spec indicates that it should behave as per the following
pseudocode:
```
STOP_AUDIO() {
if (playing) {
last_startloc = present q-channel location
playing = FALSE;
paused = TRUE;
if (stop() == SUCCESSFUL)
return no error;
return error;
}
else {
playing = FALSE;
paused = FALSE;
last_startloc = 0;
last_endloc = 0;
return no error;
}
}
```
But UDVD2 only implements the "`if (playing)`" part and not the `else`.
That is, it only ever pauses the drive, it does not stop it if already
paused.
This does cause an issue with games like Rayman, which (for some reason)
insists on having the drive fully "stopped". That is, it calls "STOP
AUDIO" twice to "pause" then "stop", and then it continuously polls the
driver until the "pause" and "busy" flags are both unset. With UDVD2's
behaviour, the "pause" flag never gets unset, since the second call to
"STOP AUDIO" did not unset it. A workaround is to press the physical
Play/Pause button on the drive (if indeed it has one) and wait for the
track to finish, but that's quite inconvenient!
I'd say fixing it should be straightforward, but would unfortunately add
quite a bit of complexity in that bit of the code, which right now is
elegant in its simplicity. I could have a look at it over the weekend.
Are MRs accepted for this?
_______________________________________________
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user