ServantOfGlaaki Posted July 15, 2002 Share Posted July 15, 2002 Hi there, I've always been a fan of the dig, mainly because of its amazing music. Just recently I discovered the music player for the dig. I wish to 'update' the player, adding a GUI, and also a feature to encode the audio to a file. However, I don't know how to decode the music from the file digmusic.bun into the bytes I can send to a soundcard/file. If possible, could anyone describe the decoding algorithm used? Thanks. I need, somehow, to get the data into a format that can be written to a soundcard or file. Link to comment Share on other sites More sharing options...
CCCP Posted July 15, 2002 Share Posted July 15, 2002 That's what I'm trying to find out too, though for ScummVM. If I discover anything more about it I'll reply here. CCCP Link to comment Share on other sites More sharing options...
ServantOfGlaaki Posted July 16, 2002 Author Share Posted July 16, 2002 Thanks CCCP. I E-mailed the creator of the music player the other day, but I haven't had a reply from him yet. *crosses fingers* If I ever find it out, I'll let you know. Link to comment Share on other sites More sharing options...
Faceless007 Posted July 16, 2002 Share Posted July 16, 2002 Back in February, when all the files at LucasHacks were offline, I also e-mailed him asking if he could send the player to me. No reply yet. Link to comment Share on other sites More sharing options...
ServantOfGlaaki Posted July 17, 2002 Author Share Posted July 17, 2002 Originally posted by Faceless007 Back in February, when all the files at LucasHacks were offline, I also e-mailed him asking if he could send the player to me. No reply yet. Damn... that kind of ruins that idea. Does anyone know if it is possible to decompile the dig player? Link to comment Share on other sites More sharing options...
john_doe Posted July 17, 2002 Share Posted July 17, 2002 Hiho, few days after the The Dig music player came out I mailed the guy who coded it and asked for the source code, and got it some days later. Essentially it's just some disassebled code (asm output from IDA) wrapped up with C code, i.e. the real algorithm to decode the data is not really there, it's just a copy from the original exe. The player also can only decode some of the used codecs. I don't know if it's ok to hand out the source code, maybe I'll up it somewhere to d/l in 1-2 weeks if he hasn't replied to you yet then. Link to comment Share on other sites More sharing options...
ServantOfGlaaki Posted July 19, 2002 Author Share Posted July 19, 2002 Hi there, Not to sound impatient, but I really don't think I'll ever get a reply from the coder of the dig player. Could you send the source code to me at servantofglaaki@lineone.net. Thanks Stu Link to comment Share on other sites More sharing options...
Ender Posted July 20, 2002 Share Posted July 20, 2002 One of the ScummVM coders (Pawel) was busy, and I hereby present - under the GPL - the fruits of his labor http://www.enderboi.com/digmusic.zip Please note the GPL license, if you create something using this code it must also be GPL'ed. This code is missing three codecs, so it can only decode 74 of the 84 songs. If anyone has any details on the missing codecs (4,5 and 6) let me know. Note to run the above util, you need around 650MB of free space. Link to comment Share on other sites More sharing options...
Ender Posted July 21, 2002 Share Posted July 21, 2002 Originally posted by Serge I believe I described the IACT (the cutscene audio) format to Endy once. Yeah, ScummVM can play SMUSH movies with audio from either Full Throttle or The Dig - however (besides the fact it can't quite read fast enough to run without stuttering we wrote that straight into the engine without making an external program first. Link to comment Share on other sites More sharing options...
Ender Posted July 21, 2002 Share Posted July 21, 2002 Originally posted by ServantOfGlaaki Is this everything? Nope, each wav file is it's own individual song. So something screwed up. What error did you get? Anyway, I'm not really supporting this code, I just posted it here for other people to play with if they really want to come up with their own Music Player software Also, any ideas on when the other codecs will be finished? I'm dying to be able to get the full music onto my PC... Some time, I'm sure. These codecs were very similar to the existing BUN voice codecs, so it was quite easy for Pawel to work them out. But the other three seem to be using a quite different algorithm. Link to comment Share on other sites More sharing options...
ServantOfGlaaki Posted July 21, 2002 Author Share Posted July 21, 2002 Thanks! I ran the program, but I got an error (I'm using Windows XP, BTW). I got 3 WAV files, of sizes: 23,972kb 23,968kb 13,168kb 10,241kb Is this everything? Also, any ideas on when the other codecs will be finished? I'm dying to be able to get the full music onto my PC... Also, is SCUMM VM able to decode The Dig's videos? (My favourite piece of music in the whole game is that of the introduction video...) Thanks Stu Link to comment Share on other sites More sharing options...
Serge Posted July 21, 2002 Share Posted July 21, 2002 I believe I described the IACT (the cutscene audio) format to Endy once. So SCUMMVM should support it. Although I must say, the audio quality of The Dig seems to me to be the worst in the history of LucasArts adventures. Thankfully, there's the soundtrack CD - even if it doesn't include all the cues, that version of the intro score is far superior to the ingame music - Serge Link to comment Share on other sites More sharing options...
CCCP Posted August 6, 2002 Share Posted August 6, 2002 Looks like the missing codecs were recently completed and committed to the ScummVM CVS, so it shouldn't be too hard to add the new codecs to the player. If it's not done by the end of the day, I'll work on it myself CCCP Link to comment Share on other sites More sharing options...
CCCP Posted August 9, 2002 Share Posted August 9, 2002 It seems to be working, so for anyone who wants it, here: http://www.geocities.com/c3p1models/dig/index.html All 84 files are decompressed. I haven't listened through all of them yet, but beginning of each file sounds ok. Most files are Stereo, some are Mono. CCCP Link to comment Share on other sites More sharing options...
ServantOfGlaaki Posted August 10, 2002 Author Share Posted August 10, 2002 Thanks, I got the Dig Player, then ran it. It created the first four tracks, but then the Windows XP Error thingy stepped in, saying there was some error. I tried to copy some of the info it gave, but it wouldn't let me select any of the text. Thanks Stu Link to comment Share on other sites More sharing options...
CCCP Posted August 11, 2002 Share Posted August 11, 2002 hmm, I had a similar problem with the original exe. I recompiled in Debug mode and it worked fine (Release had the same error). With the changed source, the problem was gone. I'm running Win2K. I will take a look at it later to see what could be going wrong. I suspect it could have something to do with memory allocation. CCCP Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.