VOGONS


DOSMid - an open-source MIDI player for DOS

Topic actions

Reply 80 of 91, by K.A.R.R.

User metadata
Rank Newbie
Rank
Newbie

here are the 2 files

the doom midi file plays ok but
when i play the other file 1st (just 5 sec are enough) and then the doom file
the overdriven guitar plays with a strange sound

Attachments

  • Filename
    test.zip
    File size
    24.66 KiB
    Downloads
    6 downloads
    File license
    Fair use/fair dealing exception

Reply 81 of 91, by mateusz.viste

User metadata
Rank Newbie
Rank
Newbie
K.A.R.R. wrote on 2020-04-01, 17:35:
here are the 2 files […]
Show full quote

here are the 2 files

the doom midi file plays ok but
when i play the other file 1st (just 5 sec are enough) and then the doom file
the overdriven guitar plays with a strange sound

Hello Karr, I finally found some time to set up dosbox with gus emulation. Sadly, I am unable to reproduce the problem... or incapable of hearing it. I recorded both tests I performed (playing the doom tune with and without running 0001.mid first), both my tests are here:
http://mateusz.viste.fr/tmp/vogons/

Do you hear the problem you described on any of these videos?

If not, then I'd be interested in knowing what is the difference in our setups. On my side, I use:
DOSBox v0.74-3
DOSMid v0.9.5
UltraSound TSR ver. 1.12

http://mateusz.viste.fr | gopher://gopher.viste.fr

Reply 82 of 91, by K.A.R.R.

User metadata
Rank Newbie
Rank
Newbie

hi thx for testing the files

i can hear the problem with your test files:
with file dosbox_000.avi
after 16 seconds the overdriven guitar is played with a strange looping sound. (same at second 20 and second 25)

with dosbox_001.avi the song played flawless.

i tested the midi files with old gravis playmidi player and it does not have this bug when playing the other file first.

Reply 83 of 91, by mateusz.viste

User metadata
Rank Newbie
Rank
Newbie
K.A.R.R. wrote on 2020-04-06, 11:53:

i can hear the problem with your test files:
with file dosbox_000.avi
after 16 seconds the overdriven guitar is played with a strange looping sound. (same at second 20 and second 25)

Ah, indeed - now I hear it. I wasn't sure what to pay attention to. I am impressed you were able to spot this, I would never notice that myself since both "versions" sound fun to me.
Anyway, it sounds like the 0001.mid enabled vibrato on the second channel, and it was kept on at the second song. I will do some investigations. If it's anything I can fix, I will fix it. Thanks for the report.

http://mateusz.viste.fr | gopher://gopher.viste.fr

Reply 85 of 91, by mateusz.viste

User metadata
Rank Newbie
Rank
Newbie

After investigations I found out that the 0001.mid song is issuing an RPN controller setting that modifies a parameter called "Pitch bend", and the odd effect you noticed in the doom ep1 tune is a surviving consequence.

The reason why this RPN setting makes troubles is not entirely clear to me. DOSMid sends an explicit "all controllers off" message to the midi device before playing any file, yet the pitch bend controller does not appear to be impacted by this.

As a test, I also tried sending a "MIDI RESET" (status 0xff) message - but it does not reset the pitch bend either.

I am not sure what the good practice would be to deal with this... For the time being I added a hack that resets the pitch bend by crafting a controller set instruction before each file, but I doubt this is the proper approach - after all, there can be lots of RPNs (up to 16 thousands), and lots of NRPNs, too. I cannot possibly reset them all, esp. since their implementation and meaning may vary from one device to another.

Anyway, here attached is the hacked version. I will have to do some further research to devise a more generic solution, though.

Attachments

  • Filename
    dosmid_karr.zip
    File size
    47.17 KiB
    Downloads
    6 downloads
    File license
    Fair use/fair dealing exception

http://mateusz.viste.fr | gopher://gopher.viste.fr

Reply 86 of 91, by Falcosoft

User metadata
Rank Oldbie
Rank
Oldbie
mateusz.viste wrote on 2020-04-06, 19:32:
After investigations I found out that the 0001.mid song is issuing an RPN controller setting that modifies a parameter called "P […]
Show full quote

After investigations I found out that the 0001.mid song is issuing an RPN controller setting that modifies a parameter called "Pitch bend", and the odd effect you noticed in the doom ep1 tune is a surviving consequence.

The reason why this RPN setting makes troubles is not entirely clear to me. DOSMid sends an explicit "all controllers off" message to the midi device before playing any file, yet the pitch bend controller does not appear to be impacted by this.

As a test, I also tried sending a "MIDI RESET" (status 0xff) message - but it does not reset the pitch bend either.

I am not sure what the good practice would be to deal with this... For the time being I added a hack that resets the pitch bend by crafting a controller set instruction before each file, but I doubt this is the proper approach - after all, there can be lots of RPNs (up to 16 thousands), and lots of NRPNs, too. I cannot possibly reset them all, esp. since their implementation and meaning may vary from one device to another.

Anyway, here attached is the hacked version. I will have to do some further research to devise a more generic solution, though.

Hi,
1. All Controllers Off (CC#121) does not affect RPN/NRPN settings. While the exact implementation details of CC#121 can depend on the device usually only these controllers are affected:

cc121.png
Filename
cc121.png
File size
340.66 KiB
Views
200 views
File license
CC-BY-4.0

2. In case of GM/GS/XG compatible devices the best practice is to send GM/GS/XG reset SysEx messages to set all parameters to default.
In case of most players you can select what kind of reset message you would like to send before playing. I think it's important to preserve the option of no reset in case someone would like to use his own custom SysEx initialization message.
Besides RPN/NRPN problems All Controllers Off is definitely not enough in case of advanced GS/XG devices since many controllers that can affect the sound radically (e.g. CC# 72-75) are not reset to default by this.

3. In case of not so advanced devices like GUS or OPL you should manually reset known supported parameters to default. Fortunately these devices usually do not support NRPN messages at all. Also there are only 5 possible RPN messages defined.
( Theoretically more could be possible but they are not defined. RPN messages are not vendor specific)
Fortunately Midi files only use and also these devices usually only support Pitch Bend Sensitivity ( RPN 0,0).

Website, Facebook, Youtube
Falcosoft Midi Player + Munt VSTi + BassMidi VSTi topic

Reply 87 of 91, by mateusz.viste

User metadata
Rank Newbie
Rank
Newbie
Falcosoft wrote on 2020-04-06, 22:00:

1. All Controllers Off (CC#121) does not affect RPN/NRPN settings. While the exact implementation details of CC#121 can depend on the device usually only these controllers are affected:
cc121.png

2. In case of GM/GS/XG compatible devices the best practice is to send GM/GS/XG reset SysEx messages to set all parameters to default

Hello Falcosoft, thanks for your input! I figured the same after reading this Roland documentation:
https://static.roland.com/assets/media/pdf/FP … Imple_e01_W.pdf

I will add a /reset=GM|GS|XG|no switch to DOSMid, allowing the user to enforce resetting the hardware between each song to a selected program. GM will probably be the default, since I assume it is a common denominator for all the other. This won't have any effect on OPL emulation or to other primitive ways of producing music, but I do not think it's a problem, since these are unlikely to bother about RPN/NRPN parameters anyway.

http://mateusz.viste.fr | gopher://gopher.viste.fr

Reply 88 of 91, by mateusz.viste

User metadata
Rank Newbie
Rank
Newbie

I have added a new feature to DOSMid, that presets the midi hardware into GM/GS/XG mode (/preset=GM|GS|XG|NONE). Unfortunately this does not make a difference with GUS, since Ultramid does not seem to react to a GM reset at all. Therefore ultimately DOSMid will do both a GM reset (or GS/XG if specified), and on top of that it will enforce a bend pitch RPN reset. This should, I hope, cover all practical cases. Attached the current version with these changes.

Attachments

  • Filename
    dosmid096beta-vogons.zip
    File size
    52.38 KiB
    Downloads
    17 downloads
    File license
    Fair use/fair dealing exception

http://mateusz.viste.fr | gopher://gopher.viste.fr

Reply 89 of 91, by carlostex

User metadata
Rank l33t
Rank
l33t

Can i make some suggestions to this program?

Use a config file so we can define and assign a function key to a specific MPU port like:

F1 - MPU port 330
F2 - MPU port 320
F3 - GUS
F4 - SB MIDI

Something like this. This is somewhat similar to what GS Play does, but unfortunately GSPlay only allows you to define one MPU-401 port. It would also be nice if you develop the GUI a bit more like loading MIDI files from within the GUI.

Reply 90 of 91, by K.A.R.R.

User metadata
Rank Newbie
Rank
Newbie
mateusz.viste wrote on 2020-04-07, 20:21:

I have added a new feature to DOSMid, that presets the midi hardware into GM/GS/XG mode (/preset=GM|GS|XG|NONE). Unfortunately this does not make a difference with GUS, since Ultramid does not seem to react to a GM reset at all. Therefore ultimately DOSMid will do both a GM reset (or GS/XG if specified), and on top of that it will enforce a bend pitch RPN reset. This should, I hope, cover all practical cases. Attached the current version with these changes.

thx for the fix
sound much better now 😀