OPL passthrough in MAME?

Emulation of old consoles and arcades.

OPL passthrough in MAME?

Postby j^aws » 2018-10-18 @ 20:11

Anyone build a MAME setup with passthrough for real OPL2/ OPL3 soundcards (ISA/ PCI) as opposed to FM sound being emulated?

What OS and version of MAME worked best? Thx.
j^aws
Oldbie
 
Posts: 665
Joined: 2013-2-02 @ 19:39
Location: UK

Re: OPL passthrough in MAME?

Postby Stiletto » 2018-10-18 @ 22:15

I had to hit the ol' memory banks for this.

I may not be 100% correct but MAME's and MAME32's OPL passthrough feature (-ym3812opl / -noym3812opl, with accompanying MAMEOPL.SYS on Windows/MAME32, direct write on DOS/MAME) entered MAME in MAME 0.23 (June 2 1997) and left after MAME 0.37b14 (April 7 2001). It functioned on both DOS and Windows.

I am not certain if the feature was kept after MAME 0.37b14 in the DOS port. (At MAME 0.37b15, the Windows port became the main supported port.)

I left some of the sourcecode for it in this antique VOGONS VDMSound post here. Note that it was Tatsuyuki Satoh's old code, pre Jarek Burczynski's rewrite.
viewtopic.php?t=255
"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto
User avatar
Stiletto
l33t
 
Posts: 4133
Joined: 2002-7-01 @ 21:57

Re: OPL passthrough in MAME?

Postby j^aws » 2018-10-18 @ 22:44

^^ That's a lot of cool info - much appreciated. I tried following the links, but a lot of them are broken. At least I have the filenames to track.
j^aws
Oldbie
 
Posts: 665
Joined: 2013-2-02 @ 19:39
Location: UK

Re: OPL passthrough in MAME?

Postby leileilol » 2018-10-18 @ 23:09

I know the final DOS release had -ym3812opl at least.

Games that usually worked in my experience:
- Bubble Bobble
- Many, many Data East games
- Many, many SNK games (pre-NEOGEO and yes this mutes the singing in Psycho Soldier)

OPL passthrough sounds fun with an AudioPCI "enhancing" these games ;)

Shame there wasn't an attempt to bring the very common YM-2151 into a "passthrough"...
Voodoo2s aren't 100mhz stock
Geforce256 isn't released as a beta on New Years '99 under the Quadro brand
DOS gaming isn't a bilinear 320x200 16:10
DOS PCs aren't better than the Macintosh
DOSBox is not for running Windows 9x
SGL != Glide
User avatar
leileilol
l33t++
 
Posts: 9463
Joined: 2006-12-16 @ 18:03

Re: OPL passthrough in MAME?

Postby Stiletto » 2018-10-19 @ 03:50

leileilol wrote:I know the final DOS release had -ym3812opl at least.


Do you mean MAME 0.37b14 (DOS)? Or the "official DOS port" DOS MAME 0.106? I am almost tempted to go check...
"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto
User avatar
Stiletto
l33t
 
Posts: 4133
Joined: 2002-7-01 @ 21:57

Re: OPL passthrough in MAME?

Postby j^aws » 2018-10-19 @ 16:50

leileilol wrote:I know the final DOS release had -ym3812opl at least.

Games that usually worked in my experience:
- Bubble Bobble
- Many, many Data East games
- Many, many SNK games (pre-NEOGEO and yes this mutes the singing in Psycho Soldier)

OPL passthrough sounds fun with an AudioPCI "enhancing" these games ;)

Shame there wasn't an attempt to bring the very common YM-2151 into a "passthrough"...

Do you remember any lag with your passthrough setup? I remember a lot of these arcade games, but the tunes played in a noisy arcade environment were often diluted in quality. Would be great to hear them in a passthrough setup, ideally with minimal lag.

And YM2151 (OPM) "passthrough" would've been great to see as well. I wonder what the best host would have been - OPL3? There's OPP (YM2164) for PC (IBM MFC), but OPM was Sharp X68000, IIRC.

@Stilleto: If you're tempted to check, then go ahead - confirmation would be great.
j^aws
Oldbie
 
Posts: 665
Joined: 2013-2-02 @ 19:39
Location: UK

Re: OPL passthrough in MAME?

Postby Stiletto » 2018-10-19 @ 20:32

Did some further checking.

The -ym3812opl option was eliminated from MAME source as of 0.60. DMAME (DOS MAME) fork maintained by "smf" continued from DMAME 0.61 to DMAME 0.106 but did not include it that I can see.

MAMEDEV.org's History pages puts it this way:
https://www.mamedev.org/history.html
Code: Select all
02 Jun 97    0.23    First FM synthesis-based sound chip supported — but only through a hack to use the OPL on a SoundBlaster card under DOS.
...
01 May 02    0.60    Removed SoundBlaster FM support as software-based emulation finally became better in almost all cases.


from whatsnew060.txt:
- osd_opl_control() and osd_opl_write() removed; direct access to the SoundBlaster OPL chip is no longer useful.


So the passthrough functionality existed in MAME from MAME 0.23 (DOS) to MAME 0.59 (DOS). It wasn't supported by the DOS port from MAME 0.60 up to MAME 0.106 and it also doesn't look like it was ever supported by the official MAME Windows port from MAME 0.37b15 onward.

The official "unofficial" MAME Windows port, MAME32, supported the feature from MAME32 0.34 BETA2 to MAME32 0.37B14.

... as far as I know, that's now the definitive answer.

Ergo, if you want this feature for a retro rig...
- Windows OS: any version of MAME32 0.34 BETA2 to MAME32 0.37B14
- DOS OS: any version of MAME 0.23 to MAME (DOS) 0.59.
(FYI: You cannot currently get DOS MAME binaries > 0.37b14 from mamedev.org and must go elsewhere.)

NOTE: as I understand it, in MAME 0.23, the feature was known as "-fm" and supported as a hack passing emulated YM2203 through to the real YM3812 as well as YM3812 to the YM3812. It didn't become -ym2203opl/-ym3812opl until MAME 0.34b6 (the first YM3812 digital emulation went in in MAME 0.34b5).

I don't know of any forks that backported (forward-ported?) the OPL passthrough feature to DOS versions higher than 0.59, or to any "official" MAME Windows versions at all.
"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto
User avatar
Stiletto
l33t
 
Posts: 4133
Joined: 2002-7-01 @ 21:57

Re: OPL passthrough in MAME?

Postby j^aws » 2018-10-19 @ 23:08

^^ Amazing detective work!

From the history log:
Code: Select all
01 May 02    0.60    Removed SoundBlaster FM support as software-based emulation finally became better in almost all cases.

Do you know what "almost all cases" is referring to?
j^aws
Oldbie
 
Posts: 665
Joined: 2013-2-02 @ 19:39
Location: UK

Re: OPL passthrough in MAME?

Postby leileilol » 2018-10-19 @ 23:23

That was long before NukeYKT and knowing better about OPL2/3 emulation ;)


Also maybe some of the OPL passthrough could be forward ported to Raine since MAME's too big and slow for a lot of the games on even a modern DOS system these days and Raine can be rather speedier in some places appropriate for low-end Pentium systems. Seems more appropriate


As for lag I can't recall a significant addition of lag with the OPL passthrough, except on AudioPCI where mame was overall slower from the poor audiopci SB emulation under DOS.
Voodoo2s aren't 100mhz stock
Geforce256 isn't released as a beta on New Years '99 under the Quadro brand
DOS gaming isn't a bilinear 320x200 16:10
DOS PCs aren't better than the Macintosh
DOSBox is not for running Windows 9x
SGL != Glide
User avatar
leileilol
l33t++
 
Posts: 9463
Joined: 2006-12-16 @ 18:03

Re: OPL passthrough in MAME?

Postby Stiletto » 2018-10-20 @ 00:13

leileilol wrote:That was long before NukeYKT and knowing better about OPL2/3 emulation ;)


Also maybe some of the OPL passthrough could be forward ported to Raine since MAME's too big and slow for a lot of the games on even a modern DOS system these days and Raine can be rather speedier in some places appropriate for low-end Pentium systems. Seems more appropriate


As for lag I can't recall a significant addition of lag with the OPL passthrough, except on AudioPCI where mame was overall slower from the poor audiopci SB emulation under DOS.


Might be a license conflict in doing that, IDK. MAME was GPLv2 from MAME 0.22 to MAME 0.25, a GPLv2+ frankenstein that was frankly embarrassing at MAME 0.26, and then MAME 0.27 began under its own custom license, MAME 0.30 with a modification to that license, and again with MAME 0.33b7 and again with MAME 0.36. Also, some individual sourcecode was under its own licenses as well.

Raine since IDK when seems (eh, vaguely) to be under the Artistic License, either 1.0 or 2.0, who can say.
https://github.com/zelurker/raine/issues/14
No idea what the Artistic license is compatible with, though Artistic 2.0 is approved by the OSI: https://opensource.org/licenses/Artistic-2.0

AdvanceMAME (DOS) might be a better fit as it is still under the "MAME license" for the most part (which edition, IDK): https://www.advancemame.it/

smf has said that someday he'd like to pursue porting something like current MAME to DOS, but VOGONS folks would probably hate it, and I doubt he'd re-enable OPL passthrough :D (Besides, like me, smf has a billion things on his to-do list...)
"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto
User avatar
Stiletto
l33t
 
Posts: 4133
Joined: 2002-7-01 @ 21:57

Re: OPL passthrough in MAME?

Postby Stiletto » 2018-10-20 @ 00:19

Here, VOGONS friends, we made you a perma-link :)
https://docs.mamedev.org/usingmame/comm ... xternalopl
"I see a little silhouette-o of a man, Scaramouche, Scaramouche, will you
do the Fandango!" - Queen

Stiletto
User avatar
Stiletto
l33t
 
Posts: 4133
Joined: 2002-7-01 @ 21:57


Return to Console & Arcade Emulation

Who is online

Users browsing this forum: No registered users and 1 guest