[Scummvm-git-logs] scummvm master -> f140f4f7c823efb08744256d4a8b5c591876b7fd

lephilousophe lephilousophe at users.noreply.github.com
Sun Feb 7 17:23:17 UTC 2021


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

Summary:
f140f4f7c8 AGS: Allow building when libmad is not present


Commit: f140f4f7c823efb08744256d4a8b5c591876b7fd
    https://github.com/scummvm/scummvm/commit/f140f4f7c823efb08744256d4a8b5c591876b7fd
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2021-02-07T18:22:34+01:00

Commit Message:
AGS: Allow building when libmad is not present

Changed paths:
    engines/ags/engine/media/audio/sound.cpp


diff --git a/engines/ags/engine/media/audio/sound.cpp b/engines/ags/engine/media/audio/sound.cpp
index f621e2a98e..81c148e332 100644
--- a/engines/ags/engine/media/audio/sound.cpp
+++ b/engines/ags/engine/media/audio/sound.cpp
@@ -66,6 +66,7 @@ SOUNDCLIP *my_load_wave(const AssetPath &asset_name, int voll, int loop) {
 }
 
 SOUNDCLIP *my_load_static_mp3(const AssetPath &asset_name, int voll, bool loop) {
+#ifdef USE_MAD
 	Common::SeekableReadStream *data = get_cached_sound(asset_name);
 	if (data) {
 		Audio::AudioStream *audioStream = Audio::makeMP3Stream(data, DisposeAfterUse::YES);
@@ -73,6 +74,9 @@ SOUNDCLIP *my_load_static_mp3(const AssetPath &asset_name, int voll, bool loop)
 	} else {
 		return nullptr;
 	}
+#else
+	return nullptr;
+#endif
 }
 
 SOUNDCLIP *my_load_mp3(const AssetPath &asset_name, int voll) {




More information about the Scummvm-git-logs mailing list