Wohlstand / OPL3BankEditor

A small cross-platform editor of the OPL3 FM banks of different formats (Downloads in README below)
GNU General Public License v3.0
143 stars 12 forks source link

Check out for ESFM emulation #164

Open Wohlstand opened 4 years ago

Wohlstand commented 4 years ago

ESFM is an extended clone of OPL3. Recently I got the ESS card with ES1688F chip that has ESFM. I tried it in action with my old Windows 98 machine, and it's very interesting thing. I heard about ESFM before from @jpcima, however, I had't much information about it and how it actually sounds. So, getting the real ESS card with a compatible chip gave me some proveground for researches.

ESS Technology's in-house developed derivative, termed ESFM, is an enhanced, 20-voice, 72-operator, OPL3-compatible clone incorporating two operating modes, a Native mode and a Legacy mode, which controls its feature-set and behavior. In Native mode, ESFM allows more than six 4-operator FM voices to be mapped, potentially allowing for a significant increase in the complexity of tones generated. The drivers for Windows 9x incorporate their own custom instrument patches which make use of this extended mode. Conversely, Legacy mode provides full backward-compatibility with Yamaha's YMF262. ESFM's output in this mode is moderately faithful to the YMF262 overall, but some tones are rendered quite differently, resulting in unique distortions in the sound and music of some games.

However, I saw nothing about any sort of emulation of this chip. However, there are some details at VOGONS: https://www.vogons.org/viewtopic.php?f=46&t=37497&start=120#p738552 (thanks to @nukeykt for a hint)

freq-mod commented 3 years ago

Yeah, interesting card. In its nativ mode, it reportedly has 18 4-op channels (18x4=72). But it's not a dual OPL3, so 2-op channels count stays the same.

Reverse enginnering project: https://github.com/pachuco/ESSPlayMid

pachuco commented 3 years ago

https://github.com/pachuco/Buttler I'm working on separate project of providing hardware read/write port access to other people online, so people can remotely play with other people's hardware. Which is totes not a reckless and dangerous thing to do. I'll lend my ESSFM for study on request.

Currently not finished, so stay tuned, I guess.

sneakernets commented 3 years ago

This is a great idea. I would love to write/extend DMXOPL3 to support this if there are more features.

freq-mod commented 1 year ago

ESFM is getting properly investigated. Turns out, it's MUCH more capable... https://github.com/jwt27/esfm

Per-op frequency, customizable op connections, per 2-op pair envelope, customizable LFO, noise generation (?), ability to output sound and modulate another op at once, and the list goes on.

Wohlstand commented 1 year ago

Very interesting, I should take a look on that soon 👀

freq-mod commented 1 year ago

https://discord.gg/C9FRkma5 - Discord server for ESFM research.

leecher1337 commented 1 year ago

In case someone wants to enhance the original sound card driver, I reverse engineered the Windows 2000 driver (which uses ESFM mode, if supported by card) to build a 64bit Windows driver for the ES1969 card: https://github.com/leecher1337/es1969 May still have some bugs, but generally works on my ES1969.

leecher1337 commented 1 year ago

I quickly hacked together an ESFM bank editor for Windows, as this was easier for me than having the deal with complicated QT C++ code and create a pull-request. Maybe you can take some code from it: https://github.com/leecher1337/esfmbank

Wohlstand commented 1 year ago

Adding support for new bank format isn't hard: you need to just make a class that inherits the https://github.com/Wohlstand/OPL3BankEditor/blob/master/src/FileFormats/ffmt_base.h, and use existing files as an example (take the apogee TMB code as a simplest example). And then, add it into the ffmt_factory.cpp to be registered and being available.

However, if speak about adding new features generally, that yeah, needs a modify the structure of bank and instruments, and additionally implement missing UI fields.

Anyway, I'll try to take a look by myself soon.

leecher1337 commented 1 year ago

Yeah, figured that out, but adding only format definitions is useless in this case.

Wohlstand commented 1 year ago

The only last case is left - the emulation-side support to let my thing to preview these instruments.

leecher1337 commented 1 year ago

Don't know how far https://github.com/Kagamiin/ESFMu progressed with emulation.

pachuco commented 1 year ago

Don't know how far https://github.com/Kagamiin/ESFMu progressed with emulation.

It is now pretty far. Sufficient for instrument preview. Maybe have to compare to hardware afterwards, since emulation is still WIP.

freq-mod commented 11 months ago

ESFMu emulator is fairly complete, except cymbal noise pattern emulation I tink (yk, ESFM does some things differently than OPL3). It will get integrated into Furnace for the next release.

Cacodemon345 commented 8 months ago

The ESFMu emulator appears to be complete save for two issues regarding math precision and Top Cymbal noise mode from what I have seen.