wohlstand / opn2bankeditor Goto Github PK
View Code? Open in Web Editor NEWA small cross-platform editor of the OPN2 FM banks of different formats (Downloads in README below)
License: GNU General Public License v3.0
A small cross-platform editor of the OPN2 FM banks of different formats (Downloads in README below)
License: GNU General Public License v3.0
Rather minor bug, but anyway:
Happens on OPL bank editor as well.
Fix next imperfections:
Anything below OP3 and OP4 "Detune" parameter is invisible, including piano keys and there is no way to resize the window for it to fit.
The same applies to OPL3BE.
I want to import an opl2 or OPL3 instrument, which can be used as an opn2 instrument after a little modification
Found a format of banks and its documentation : https://segaretro.org/YMX
The format is present in multiple software and there exist some instruments to be found.
In the software "Sonic QX" there are banks : S2b-81.ymx
Saxman.ymx
I'm trying to build the package on the AUR (package opn2bankeditor-git
), and I've been having this error:
/home/yohanan/.cache/paru/clone/opn2bankeditor-git/src/OPN2BankEditor/src/delay_analysis.cpp: In member function ‘virtual double DelayAnalysisDialog::PlotData::y(double) const’:
/home/yohanan/.cache/paru/clone/opn2bankeditor-git/src/OPN2BankEditor/src/delay_analysis.cpp:250:15: error: cannot declare variable ‘spline’ to be of abstract type ‘QwtSpline’
250 | QwtSpline spline;
| ^~~~~~
In file included from /home/yohanan/.cache/paru/clone/opn2bankeditor-git/src/OPN2BankEditor/src/delay_analysis.cpp:29:
/usr/include/qwt/qwt_spline.h:57:18: note: because the following virtual functions are pure within ‘QwtSpline’:
57 | class QWT_EXPORT QwtSpline
| ^~~~~~~~~
/usr/include/qwt/qwt_spline.h:176:26: note: ‘virtual QPainterPath QwtSpline::painterPath(const QPolygonF&) const’
176 | virtual QPainterPath painterPath( const QPolygonF& ) const = 0;
| ^~~~~~~~~~~
/home/yohanan/.cache/paru/clone/opn2bankeditor-git/src/OPN2BankEditor/src/delay_analysis.cpp:251:12: error: ‘class QwtSpline’ has no member named ‘setPoints’
251 | spline.setPoints(poly);
| ^~~~~~~~~
/home/yohanan/.cache/paru/clone/opn2bankeditor-git/src/OPN2BankEditor/src/delay_analysis.cpp:254:35: error: ‘class QwtSpline’ has no member named ‘value’
254 | double interpolatedY = spline.value(x);
| ^~~~~
make[2]: *** [CMakeFiles/OPN2BankEditor.dir/build.make:361: CMakeFiles/OPN2BankEditor.dir/src/delay_analysis.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:238: CMakeFiles/OPN2BankEditor.dir/all] Error 2
make: *** [Makefile:136: all] Error 2
==> ERROR: A failure occurred in build().
Aborting...
error: failed to build 'opn2bankeditor-git-1.3.beta.r80.g78c2a34-1':
:: Packages failed to build: opn2bankeditor-git-1.3.beta.r80.g78c2a34-1
Any clue on what this could be? I believe it's versioning related but I'm not sure what version of what program I should switch to.
Some FM tone editors/utilities and textual MML formats refer to detune values as unsigned numbers:
No detune can be either 0
or 4
1+ε
= 1
1+2ε
= 2
1+3ε
= 3
1-ε
= 5
1-2ε
= 6
1-3ε
= 7
Also, Bamboo Tracker has such option.
If it can copy and paste instruments using text formats, OPN2-BE is able exchange to quickly with other software, without needing to involve files in the workflow.
(software: BambooTracker, Mucom88, and mine, as a feature that I will add)
We already have OPM implemented, for which BT has support, I guess it would be an adequate choice.
Since OPN instrument format support was brought back, it seems that there are more formats that could be supported here:
Rate Scale Level.
Attenuates level output towards higher pitch.
It just a question at this point. I think it rathers shortens the ADSR envelope towards higher pitch rather than attenuating modulation/output. Take a look:
Notice that volume and timbre of instrument didn't changed, its envelope did instead. Even release rates got compressed. If you want, you may create an instrument thats just sine wave with attack rate=31 and release rate=15 and then play with RSL. Output will stay the same.
Looks like description was copied from OPL3 bank edit, key scale level rate. OPN/OPM don't have it.
As current GENS 2.10 emulator is very old and very inaccurate, it must be replaced with any other like Aly James and use sample-accurate Nuked OPN2 emulator which simulates same processes as in real chip (include ladder-effect deffect of YM2612!!!).
It's would be cool to be able open two separated bank editors and copy / paste instruments between of them. For now, the clipboard is only internal and can copy and paste instruments inside of same instance of BE. It can be solved by any of ways:
P.S. The task is same for OPL3-BE too. Why I wrote here? I have tried to organize GENS bank into GM, but I have found it would be more convenient to open two instances of same BE and paste copied instruments into another opened bank.
It has these XG percussion banks.
Some numbers disagree with the naming, with value off by 1.
Name | MSB | LSB |
---|---|---|
48 - Orchestra | 000 | 048 |
26 - AnalogKit | 000 | 025 |
25 - ElectroKit | 000 | 024 |
2 - StandardKit2 | 000 | 001 |
In contrast, this is the data I collected from Sekaiju's MU1000 instruments.
On the left is MSB:Program
with 0-indexing.
P127:048 "YAMAHA MU1000/MU2000 #049 SymphKit"
P127:025 "YAMAHA MU1000/MU2000 #026 AnalgKit"
P127:024 "YAMAHA MU1000/MU2000 #025 ElctrKit"
P127:001 "YAMAHA MU1000/MU2000 #002 StndKit2"
(in comparison, XG spec indicates MSB in 0-indexing, LSB constant at 0, and Program in 1-indexing)
On some rare occasions, VGM importer won't detect every instrument in .vgm file.
example - 15 - Expander.zip - importer sees only 3 instruments, while there are much more than that (such as detuned piano playing on YM2612 Channel 0 and 1, is missing).
With using of VGM specification, implement the import of YM2612 instruments from the VGM files
http://vgmrips.net/wiki/VGM_Specification
Algorithm is simple:
The current GYB file format specification was reverse-engineered.
Feel free to use the actual specification instead: http://vgmrips.net/programs/_gyb_format.txt
Because of the case noticed by @freq-mod, there is a big source of duplicated instruments that appear because they were altered by the original driver. To resolve this, it's reasonable to provide some options to specify different conditions on how instrument differences will be recognized (for example, ignore any LFO changes, etc).
When a GEMS banks is open and then saved as WOPN file, this WOPN file cannot be opened again.
An error is raised about a bad format.
My suspicion in on the exporter, as it is not able to open this file the wopn_file library either.
Originally, coefficients was calibrated on GENS and channel management worked fine. However, after switching into MAME as sounding delays computation, resulted values are became too long. In result, OneStop.mid began to break synth strings in begin. When re-calculate full xg.wopn
bank with GENS, everything is playing fine. It's need to re-calibrate all coefficients to give correct values on MAME emulator are will don't harm channel management in libOPNMIDI.
I would like to have command line utilities for converting wopn to a format convenient for editing in a regular editor (gedit, geany, mcedit, nano, ...).
By chance I found the checksum formula of this file format which was previouly unknown.
The project vgmpre has it, where it is known as "nineko's crazy checksum formula".
Judging from code, I guess we can say it's a somewhat fitting description.
https://github.com/vgmtool/vgm2pre/blob/f4f917df35d531512292541234a5c1722b8af96f/vgm2pre/fmt/gyb.hpp#L30-L70
It's inconvenient to open importer and load instrument file into it each time to just import one small silly instrument. It's would be a good thing when attempt to drop the single-instrument file into the main bank editor window, will automatically open the Importer and will load the instrument into it to let user choice the import destination or quickly preview the instrument itself.
Some instruments, like cymbals, hi-hats, triangles, etc would greatly benefit from it. The same can apply to OPL3-BE - when having dual 2-op voice, second voice can be detuned. If the voice 2 is pasted as voice 1, when creating a normal 2-op instr, detune information is lost.
I got some patches online for touhou, but the gyb import just imports the same instrument 100 times, which seems wrong (but probably not the converters fault), and the instrument importer, which does read dmp and vgi correctly, will only import them 1 at a time through the menu, please consider allowing people to drag multiple single instrument files into the instrument importer.
I made some recordings comparing MAME's and Gens' output when I "noticed" THIS
https://instaud.io/1Z0Z - recorded using Deflemask, MAME emulation
https://instaud.io/1Z10 - recorded using bank editor, Gens 2.10 core
Difference is rather apparent...
bird.zip
This is instrument in question.
https://www.vogons.org/viewtopic.php?p=704730#p704730
SLON: What about the possibility of using the YM2608 core? It was distinguished by the presence of additional SSG and ADPCM (and RHY-channels), and also, as far as I know, a higher-quality DAC. True, I do not know how useful this will be for MIDI.
Wohlstand: It's dependent on the availability of necessary emulator and the chip specification I can use to provide an interface. For now, libOPNMIDI doesn't use DAC, but its support is WIP. On side of libOPNMIDI are three emulators: Nuked OPN2 is implemented YM3438 chip, but it's very powerful and won't work on slow hardware in real-time if you running more than 3 chips; MAME OPN2 is implemented YM2612, doesn't using much power, but is a most balanced emulator that gives well-accurate and doesn't eat too much CPU; And the GENS 2.10, the old and inaccurate emulator, but, the fastest emulator I have at me.
If the OPNA chip has compatible ABI, we can try to use it as an alternative chip together with existing OPN2 chips. For the case of DAC-equipped chips, they are all will have the sample-streamer on the side of ChipSet base backend, and necessary to do that from outside. The only exception would be for OPNA that does support of ADPCM.
This mode often used in various games with playing same notes in two channels
When you have count of bank less than importing instrument, the crash will happen as the reason of instruments store arrays mismatch. To fix this, it's need to check the instrument number, and then automatically expand the banks set to let instruments be correctly imported.
P.S. It's absolutely same crash on OPL3 Bank Editor as the same importer code was used in both cases.
After some work on improving the importer, I find importer use to be kind of confusing by some aspects, and it's possible to improve the user-friendlyness.
when an instrument is imported into the selected slot, you can't play it; you have to select another and go back to this instrument, to allow it to play.
when under "assign" mode, the instruments assign to the melodic/percussive side of banks depending on which panel it is that is selected in the main window. In my opinion, it is not intuitive.
I prefer if the importer had a choice which says: "Where do you want the instruments to go into?".
Steps to replicate:
This bug can be hard to replicate, since it seems to be very random. Tested on Nuked OPN2 core.
Would it be possible to import instruments in TFI or DMP format? (both are rather popular and most YM2612 patches on internet are in either of these)
http://www.deflemask.com/DMP_SPECS.txt -specs of DMP instrument format
😜
In OPL3-BE you can detune second voice against the first. Here, I would like to ask about option to change the pitch of OPN2 voice by up to 128 cents up or down. Reason for that - some OPNA FM percussion instruments aren't compatible with OPN2... unless you turn the pitch down by some cents (for C6, it's around 70).
Below is an archive which contains the melodic set.
Tomsoft.tar.gz
This file has:
I took the melodics from a GYM dump and a slightly modified importer, such that there are the 128 of them in the GM order, and allowing duplicates (as the bank has a few).
For the drums, I have not found how to make sense of the percussive dump.
This bug is weird, it seems to occur consistently, yet with many prerequisites. Only steps to replicate I can come up with:
There might be other ways to replicate this behaviour, I guess.
It describes the architecture of OPL3 and was a straight copy out of the other editor.
It's the text label in the top right corner.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.