[Scummvm-cvs-logs] SF.net SVN: scummvm:[42567] scummvm/branches/gsoc2009-mods

nolange at users.sourceforge.net nolange at users.sourceforge.net
Fri Jul 17 18:07:57 CEST 2009


Revision: 42567
          http://scummvm.svn.sourceforge.net/scummvm/?rev=42567&view=rev
Author:   nolange
Date:     2009-07-17 16:07:57 +0000 (Fri, 17 Jul 2009)

Log Message:
-----------
added primitive support for Kyrandia`s Intro Music.

Modified Paths:
--------------
    scummvm/branches/gsoc2009-mods/dists/msvc9/kyra.vcproj
    scummvm/branches/gsoc2009-mods/engines/kyra/kyra_v1.cpp
    scummvm/branches/gsoc2009-mods/engines/kyra/module.mk
    scummvm/branches/gsoc2009-mods/engines/kyra/sound_intern.h
    scummvm/branches/gsoc2009-mods/sound/mods/maxtrax.cpp

Modified: scummvm/branches/gsoc2009-mods/dists/msvc9/kyra.vcproj
===================================================================
--- scummvm/branches/gsoc2009-mods/dists/msvc9/kyra.vcproj	2009-07-17 15:40:20 UTC (rev 42566)
+++ scummvm/branches/gsoc2009-mods/dists/msvc9/kyra.vcproj	2009-07-17 16:07:57 UTC (rev 42567)
@@ -502,6 +502,10 @@
 			>
 		</File>
 		<File
+			RelativePath="..\..\engines\kyra\sound_amiga.cpp"
+			>
+		</File>
+		<File
 			RelativePath="..\..\engines\kyra\sound_digital.cpp"
 			>
 		</File>

Modified: scummvm/branches/gsoc2009-mods/engines/kyra/kyra_v1.cpp
===================================================================
--- scummvm/branches/gsoc2009-mods/engines/kyra/kyra_v1.cpp	2009-07-17 15:40:20 UTC (rev 42566)
+++ scummvm/branches/gsoc2009-mods/engines/kyra/kyra_v1.cpp	2009-07-17 16:07:57 UTC (rev 42567)
@@ -113,6 +113,8 @@
 				_sound = new SoundPC98(this, _mixer);
 			else
 				_sound = new SoundTownsPC98_v2(this, _mixer);
+		} else if (_flags.platform == Common::kPlatformAmiga) {
+			_sound = new SoundAmiga(this, _mixer);
 		} else if (midiDriver == MD_ADLIB) {
 			_sound = new SoundAdlibPC(this, _mixer);
 			assert(_sound);

Modified: scummvm/branches/gsoc2009-mods/engines/kyra/module.mk
===================================================================
--- scummvm/branches/gsoc2009-mods/engines/kyra/module.mk	2009-07-17 15:40:20 UTC (rev 42566)
+++ scummvm/branches/gsoc2009-mods/engines/kyra/module.mk	2009-07-17 16:07:57 UTC (rev 42567)
@@ -50,6 +50,7 @@
 	sequences_hof.o \
 	sequences_mr.o \
 	sound_adlib.o \
+	sound_amiga.o \
 	sound_digital.o \
 	sound_midi.o \
 	sound_pcspk.o \

Modified: scummvm/branches/gsoc2009-mods/engines/kyra/sound_intern.h
===================================================================
--- scummvm/branches/gsoc2009-mods/engines/kyra/sound_intern.h	2009-07-17 15:40:20 UTC (rev 42566)
+++ scummvm/branches/gsoc2009-mods/engines/kyra/sound_intern.h	2009-07-17 16:07:57 UTC (rev 42567)
@@ -36,6 +36,7 @@
 
 namespace Audio {
 class PCSpeaker;
+class MaxTrax;
 } // end of namespace Audio
 
 namespace Kyra {
@@ -343,6 +344,33 @@
 	static const uint8 _noteTable2[];
 };
 
+class SoundAmiga : public Sound {
+public:
+	SoundAmiga(KyraEngine_v1 *vm, Audio::Mixer *mixer);
+	~SoundAmiga();
+
+	virtual kType getMusicType() const { return kPC98; } //FIXME
+
+	bool init();
+
+	void process() {}
+	void loadSoundFile(uint file);
+	void loadSoundFile(Common::String);
+
+	void playTrack(uint8 track);
+	void haltTrack();
+	void beginFadeOut();
+
+	int32 voicePlay(const char *file, Audio::SoundHandle *handle, uint8 volume, bool isSfx) { return -1; }
+	void playSoundEffect(uint8);
+
+protected:
+	Audio::MaxTrax *_driver;
+	uint _fileLoaded;
+
+	static const char *const kFilenameTable[3][2];
+};
+
 } // end of namespace Kyra
 
 #endif

Modified: scummvm/branches/gsoc2009-mods/sound/mods/maxtrax.cpp
===================================================================
--- scummvm/branches/gsoc2009-mods/sound/mods/maxtrax.cpp	2009-07-17 15:40:20 UTC (rev 42566)
+++ scummvm/branches/gsoc2009-mods/sound/mods/maxtrax.cpp	2009-07-17 16:07:57 UTC (rev 42567)
@@ -567,7 +567,6 @@
 	}
 	memset(const_cast<Patch *>(_patch), 0, sizeof(_patch));
 }
-// LONG PlayNote(UWORD note,UWORD patch,UWORD duration,UWORD volume,UWORD pan)
 
 int MaxTrax::playNote(byte note, byte patch, uint16 duration, uint16 volume, bool rightSide) {
 	assert(patch < ARRAYSIZE(_patch));


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list