Opened 16 years ago

Closed 11 years ago

Last modified 11 years ago

#1849 closed defect (fixed)

MI2: Minor problems in native MT-32 mode

Reported by: SF/newrisingsun Owned by: lordhoto
Priority: low Component: Engine: SCUMM
Keywords: Cc:
Game: Monkey Island 2


1. The original ROLAND.IMS reverses pan directions, ScummVM does not. 2. Incorrect Reverb handling: During MI2 Introduction Tune, "LeshBass" and "Elec Org 2" should be without reverb. A part's reverb information is stored in byte 2, bit 2 (0x02) of a part's "part_alloc" sysex (cmd 0). 3. Incorrect Panpot handling in Woodtick, Wally's Room etc. For example, in Wally's Room, "Pizzicato" should play on the right, however, in ScummVM, it always plays centered. The correct panpot information is stored in bytes 07 & 08 (upper / lower 4 bits) in signed format, i.e. 0=center, 0xc1 (= minus 0x3f) = left, 0x3f = right. 4. Collapsing pillars on Dinky Island: incorrect pitch bend range handling (plays as 2, should be 12). The correct bend range information is stored in bytes 13 & 14 (upper / lower 4 bits, decimal).

Ticket imported from: #1088045. Ticket imported from: bugs/1849.

Change History (19)

comment:1 by SF/newrisingsun, 16 years ago

Summary: Minor problems in native MT-32 modeMI2: Minor problems in native MT-32 mode

comment:2 by SF/newrisingsun, 16 years ago

Priority: normallow

comment:3 by SF/khalek, 16 years ago

Owner: set to SF/jamieson630

comment:4 by kingguppy, 16 years ago

Owner: changed from SF/jamieson630 to kingguppy

comment:5 by kingguppy, 16 years ago

Interesting stuff, thanks. I'll look into it.

comment:6 by SF/tbcarey, 15 years ago

Just a note regarding #4:

Roland's official GM -> MT-32 setup/remapping sets pitch bend sensitivity to 12 for all channels, and this is what I've done in the new GS settings. Part::setup automatically changes pitch bend sensitivity to 2 on account of _pitchbend_factor = 2. I had always assumed that 12 was the default pitch bend sensitivity for the MT-32, so why does ScummVM use 2 by default? Is this a mistake or is there a specific instance where it makes sense to use this value?

comment:7 by SF/jamieson630, 14 years ago

Most GM devices use a default pitchbend range of +/- two half steps, although they are also generally capable of going up to +/- 12. The default we use is geared toward GM, not MT-32.

I am fixing Part 2 and Part 3 from the original problem description. I can validate a fix for Part 4 if someone will attach a savegame at the scene in question, but I do not have one, myself. I am also looking into where Part 1 may be fixed in the cleanest manner possible.

comment:8 by Kirben, 14 years ago

For Part 4, just use boot param 993 to get to the correct scene in Monkey Island 2.

comment:9 by SF/jamieson630, 14 years ago

A fix for Parts 2, 3 and 4 are in Subversion. As far as Part 1, does this reversal of pan directions apply only to the SysEx command 0 processing, or does it also apply to Control Change 10 messages as well?

comment:10 by SF/newrisingsun, 14 years ago

I don't know how you process Control Change 10.

If you connect the MT-32 module properly to your stereo, on a "normal" MIDI file player, control change value 0 will be 100% right and value 127 will be 100% left. This is a peculiarity of the MT-32.

ROLAND.IMS reverses it to conform to the MIDI specification so that a MIDI file's controller 10 value 0 will be 100% left and 127 will be 100% right. As for sysex command 0, 0xc1 = 100% left, 0x3f = 100% right, as stated previously.

On another note, I see you are not currently emulating sysex command 1 for MI2, only commands 0 and 2. While command 0 is "part_alloc" (allocating a part, setting the part's parameters), command 1 is "part_dealloc" (freeing a part). Its only paramenter is the part number, and it's used in: song 102 (Cemetery) song 115 (Booty Island Overview) song 127 (Rum Roger's House) song 128 (Rum Roger's Island) song 178 (Love Theme) and possibly others.

comment:11 by SF/jamieson630, 14 years ago

Alright, so music panning is universally reversed on the MT-32. That will affect where compensation gets implemented. Coming soon.

In the meantime, I have implemented SysEx command 1 per your description. It's in Subversion.

comment:12 by sev-, 14 years ago

What is the status of this item?

comment:13 by SF/newrisingsun, 14 years ago

MT-32 music is perfect EXCEPT for the reverb: the squirt sound when selecting the difficulty level in MI2 should have NO reverb, yet it has in ScummVM 0.9.1 and previous.

Having looked at the source, it seems that the iMuse sysex bit is correctly interpreted (the value is stored in part->effectLevel). However, if I understand the source correctly, part->effectLevel gets sent as controller 91 value even in native MT-32 mode. This is wrong.

To enable/disable a channel's reverb on the MT-32, use the following sysex: F0 41 cc 16 12 00 00 06 vv ss F7 with cc=channel number (01-09 for channels 2-10), vv=0/1 for off/on, and ss being the checksum.

Hope this helps.

comment:14 by sev-, 14 years ago

Hmm... In fact, we are really need MT-32/MIDI hacker in our Team. Both Jamieson630 and KingGuppy are effectively defunct.

Practically nobody else can even evaluate this. So if you want to help ScummVM Team, you're welcome :)

comment:15 by SF/jamieson630, 14 years ago

Just a note.... The reason this got stalled is because the ideal solution is an MT-32 translation layer between the player and the output device. In the case of the SCUMM engine (and any other engine that bothered to use the unified music architecture), the interaction layer (iMuse in the case of the SCUMM engine) would probably be the "player" in question, rather than the MIDI parser itself. The MT-32 translation layer could handle such tweaks as panning reversal and conversion of GM control change messages into MT-32 SysEx counterparts.

Unfortunately, the MT-32 translation layer is outside the scope of my availability at this time. I can try to work on an implementation, but cannot guarantee a timeline.

comment:16 by lordhoto, 11 years ago

I did implement support for panning reversal and the reverb setting in iMuse now. Thus I'm closing this, since all points are fixed judged by the comments. I'll still leave it assigned to jamieson630 though, since he did fix most / all of it.

comment:17 by lordhoto, 11 years ago

Resolution: fixed
Status: newclosed

comment:18 by lordhoto, 11 years ago

Actually I just noticed it wasn't assigned to jamieson630 at all and I can't assign it to him, so I'll just assign it to myself now...

comment:19 by lordhoto, 11 years ago

Owner: changed from kingguppy to lordhoto
Note: See TracTickets for help on using tickets.