191 |
|
|
192 |
/** |
/** |
193 |
* Will be called by the InstrumentResourceManager when the instrument |
* Will be called by the InstrumentResourceManager when the instrument |
194 |
* we are currently using in this engine is going to be updated, so we |
* we are currently using on this EngineChannel is going to be updated, |
195 |
* can stop playback before that happens. |
* so we can stop playback before that happens. |
196 |
*/ |
*/ |
197 |
void EngineChannel::ResourceToBeUpdated(::gig::Instrument* pResource, void*& pUpdateArg) { |
void EngineChannel::ResourceToBeUpdated(::gig::Instrument* pResource, void*& pUpdateArg) { |
198 |
dmsg(3,("gig::Engine: Received instrument update message.\n")); |
dmsg(3,("gig::Engine: Received instrument update message.\n")); |
210 |
if (pEngine) pEngine->Enable(); |
if (pEngine) pEngine->Enable(); |
211 |
} |
} |
212 |
|
|
213 |
|
/** |
214 |
|
* Will be called by the InstrumentResourceManager on progress changes |
215 |
|
* while loading or realoading an instrument for this EngineChannel. |
216 |
|
* |
217 |
|
* @param fProgress - current progress as value between 0.0 and 1.0 |
218 |
|
*/ |
219 |
|
void EngineChannel::OnResourceProgress(float fProgress) { |
220 |
|
this->InstrumentStat = int(fProgress * 100.0f); |
221 |
|
dmsg(7,("gig::EngineChannel: progress %d%", InstrumentStat)); |
222 |
|
} |
223 |
|
|
224 |
void EngineChannel::Connect(AudioOutputDevice* pAudioOut) { |
void EngineChannel::Connect(AudioOutputDevice* pAudioOut) { |
225 |
if (pEngine) { |
if (pEngine) { |
226 |
if (pEngine->pAudioOutputDevice == pAudioOut) return; |
if (pEngine->pAudioOutputDevice == pAudioOut) return; |