1 // ============================================================== 2 // This file is part of Glest Shared Library (www.glest.org) 3 // 4 // Copyright (C) 2001-2008 Marti�o Figueroa 5 // 6 // You can redistribute this code and/or modify it under 7 // the terms of the GNU General Public License as published 8 // by the Free Software Foundation; either version 2 of the 9 // License, or (at your option) any later version 10 // ============================================================== 11 12 #include "sound_interface.h" 13 14 #include "leak_dumper.h" 15 16 namespace Shared{ namespace Sound{ 17 18 // ===================================================== 19 // class SoundInterface 20 // ===================================================== 21 getInstance()22SoundInterface &SoundInterface::getInstance(){ 23 static SoundInterface soundInterface; 24 return soundInterface; 25 } 26 setFactory(SoundFactory * soundFactory)27void SoundInterface::setFactory(SoundFactory *soundFactory){ 28 this->soundFactory= soundFactory; 29 } 30 newSoundPlayer()31SoundPlayer *SoundInterface::newSoundPlayer(){ 32 return soundFactory->newSoundPlayer(); 33 } 34 35 }}//end namespace 36