Skip to content

Commit 8dd17cc

Browse files
committed
libmodplug: Add BWSB General Digital Music module loader
Based on patch by Alice Rowan (Lachesis) - see: Konstanty/libmodplug#57
1 parent c1fa7ac commit 8dd17cc

File tree

6 files changed

+454
-1
lines changed

6 files changed

+454
-1
lines changed

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ if(SDLSOUND_DECODER_MODPLUG)
102102
src/libmodplug/load_mt2.c
103103
src/libmodplug/load_mtm.c
104104
src/libmodplug/load_okt.c
105+
src/libmodplug/load_gdm.c
105106
src/libmodplug/load_psm.c
106107
src/libmodplug/load_ptm.c
107108
src/libmodplug/load_s3m.c

src/Makefile.os2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ MODPSRCS = modplug.c sndfile.c fastmix.c snd_dsp.c snd_flt.c snd_fx.c sndmix.c &
2929
load_669.c load_amf.c load_ams.c load_dbm.c load_dmf.c load_dsm.c &
3030
load_far.c load_it.c load_mdl.c load_med.c load_mod.c load_mt2.c &
3131
load_mtm.c load_okt.c load_psm.c load_ptm.c load_s3m.c load_stm.c &
32-
load_ult.c load_umx.c load_xm.c
32+
load_gdm.c load_ult.c load_umx.c load_xm.c
3333

3434
TIMISRCS = common.c instrum.c mix.c output.c playmidi.c readmidi.c resample.c &
3535
tables.c timidity.c

src/SDL_sound_modplug.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ static const char *extensions_modplug[] =
3636
"DMF", /* DMF DELUSION DIGITAL MUSIC FILEFORMAT (X-Tracker) */
3737
"DSM", /* DSIK Internal Format module */
3838
"FAR", /* Farandole module */
39+
"GDM", /* General Digital Music */
3940
"IT", /* Impulse Tracker IT file */
4041
"MDL", /* DigiTracker module */
4142
"MED", /* OctaMed MED file */

src/libmodplug/libmodplug.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ typedef const BYTE * LPCBYTE;
131131
#define MOD_TYPE_AMF0 0x200000
132132
#define MOD_TYPE_PSM 0x400000
133133
#define MOD_TYPE_J2B 0x800000
134+
#define MOD_TYPE_GDM 0x40000000 // Fake type
134135
#define MOD_TYPE_UMX 0x80000000 // Fake type
135136
#define MAX_MODTYPE 24
136137

@@ -692,6 +693,7 @@ void delete_CSoundFile(CSoundFile *_this);
692693
BOOL CSoundFile_ReadAMF(CSoundFile *_this, LPCBYTE lpStream, DWORD dwMemLength);
693694
BOOL CSoundFile_ReadMT2(CSoundFile *_this, LPCBYTE lpStream, DWORD dwMemLength);
694695
BOOL CSoundFile_ReadPSM(CSoundFile *_this, LPCBYTE lpStream, DWORD dwMemLength);
696+
BOOL CSoundFile_ReadGDM(CSoundFile *_this, LPCBYTE lpStream, DWORD dwMemLength);
695697
BOOL CSoundFile_ReadUMX(CSoundFile *_this, LPCBYTE lpStream, DWORD dwMemLength);
696698

697699
// MOD Convert function

0 commit comments

Comments
 (0)