[Scummvm-git-logs] scummvm master -> 8b2966326154fc9c2fc6388c6cac8c80d8a007db

NMIError noreply at scummvm.org
Sun Sep 21 18:10:36 UTC 2025


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .

Summary:
8b29663261 AUDIO: Move AdLib transpose init


Commit: 8b2966326154fc9c2fc6388c6cac8c80d8a007db
    https://github.com/scummvm/scummvm/commit/8b2966326154fc9c2fc6388c6cac8c80d8a007db
Author: Coen Rampen (crampen at gmail.com)
Date: 2025-09-21T20:10:15+02:00

Commit Message:
AUDIO: Move AdLib transpose init

Changed paths:
    audio/adlib_ms.cpp
    audio/adlib_ms.h
    engines/agos/drivers/accolade/adlib.cpp
    engines/agos/drivers/simon1/adlib.cpp
    engines/ultima/nuvie/sound/mididrv_m_adlib.cpp


diff --git a/audio/adlib_ms.cpp b/audio/adlib_ms.cpp
index 2401f0b04f3..32f299b6c04 100644
--- a/audio/adlib_ms.cpp
+++ b/audio/adlib_ms.cpp
@@ -96,6 +96,7 @@ void AdLibBnkInstrumentDefinition::toOplInstrumentDefinition(OplInstrumentDefini
 	// TODO Figure out if this is the same as rhythmVoiceNumber
 	instrumentDef.rhythmNote = 0;
 	instrumentDef.rhythmType = RHYTHM_TYPE_UNDEFINED;
+	instrumentDef.transpose = 0;
 }
 
 void AdLibIbkInstrumentDefinition::toOplInstrumentDefinition(OplInstrumentDefinition &instrumentDef) const {
diff --git a/audio/adlib_ms.h b/audio/adlib_ms.h
index c29f09ed3a1..122cad32d87 100644
--- a/audio/adlib_ms.h
+++ b/audio/adlib_ms.h
@@ -119,7 +119,7 @@ struct OplInstrumentDefinition {
 	 * Number of semitones the notes played by this instrument should be
 	 * transposed up or down.
 	 */
-	int8 transpose = 0;
+	int8 transpose;
 
 	/**
 	 * Check if this instrument definition contains any data.
diff --git a/engines/agos/drivers/accolade/adlib.cpp b/engines/agos/drivers/accolade/adlib.cpp
index c410e609ead..2ae9016dfd6 100644
--- a/engines/agos/drivers/accolade/adlib.cpp
+++ b/engines/agos/drivers/accolade/adlib.cpp
@@ -476,6 +476,7 @@ void MidiDriver_Accolade_AdLib::loadInstrumentData(OplInstrumentDefinition &defi
 
 	definition.rhythmType = rhythmType;
 	definition.rhythmNote = rhythmNote;
+	definition.transpose = 0;
 }
 
 void MidiDriver_Accolade_AdLib::readDriverData(byte *driverData, uint16 driverDataSize, bool newVersion) {
diff --git a/engines/agos/drivers/simon1/adlib.cpp b/engines/agos/drivers/simon1/adlib.cpp
index c5c63dc6864..3868aff18b6 100644
--- a/engines/agos/drivers/simon1/adlib.cpp
+++ b/engines/agos/drivers/simon1/adlib.cpp
@@ -125,6 +125,7 @@ void MidiDriver_Simon1_AdLib::parseInstrumentData(const byte *instrumentData) {
 		instrumentBank[i].connectionFeedback1 = 0;
 		instrumentBank[i].rhythmNote = 0;
 		instrumentBank[i].rhythmType = RHYTHM_TYPE_UNDEFINED;
+		instrumentBank[i].transpose = 0;
 
 		// Remaining bytes seem to be unused.
 		dataPtr += 5;
@@ -151,6 +152,7 @@ void MidiDriver_Simon1_AdLib::parseInstrumentData(const byte *instrumentData) {
 			// 15 - hi-hat
 			rhythmBank[i].rhythmType = static_cast<OplInstrumentRhythmType>(6 - (RHYTHM_MAP[i].channel - 10));
 			rhythmBank[i].rhythmNote = RHYTHM_MAP[i].note;
+			rhythmBank[i].transpose = 0;
 		}
 	}
 
diff --git a/engines/ultima/nuvie/sound/mididrv_m_adlib.cpp b/engines/ultima/nuvie/sound/mididrv_m_adlib.cpp
index a22f001f2b3..dccc9972e6d 100644
--- a/engines/ultima/nuvie/sound/mididrv_m_adlib.cpp
+++ b/engines/ultima/nuvie/sound/mididrv_m_adlib.cpp
@@ -265,6 +265,8 @@ void MidiDriver_M_AdLib::metaEvent(int8 source, byte type, const byte* data, uin
 		instrument->operator1.waveformSelect = data[10];
 
 		instrument->connectionFeedback0 = data[11];
+
+		instrument->transpose = 0;
 	}
 }
 




More information about the Scummvm-git-logs mailing list