@@ -380,7 +380,8 @@ void CBassAudio::PlayStreamIntern ( void* arguments )
380
380
//
381
381
void CBassAudio::CompleteStreamConnect ( HSTREAM pSound )
382
382
{
383
- if ( pSound )
383
+ SString strError;
384
+ if (pSound)
384
385
{
385
386
m_pSound = pSound;
386
387
@@ -395,11 +396,11 @@ void CBassAudio::CompleteStreamConnect ( HSTREAM pSound )
395
396
396
397
if ( BASS_FX_BPM_CallbackSet ( pSound, (BPMPROC*)&BPMCallback, 1 , 0 , 0 , m_uiCallbackId ) == false )
397
398
{
398
- g_pCore-> GetConsole ()-> Print ( " BASS ERROR in BASS_FX_BPM_CallbackSet" ) ;
399
+ strError = " BASS ERROR in BASS_FX_BPM_CallbackSet" ;
399
400
}
400
401
if ( BASS_FX_BPM_BeatCallbackSet ( pSound, (BPMBEATPROC*)&BeatCallback, m_uiCallbackId ) == false )
401
402
{
402
- g_pCore-> GetConsole ()-> Print ( " BASS ERROR in BASS_FX_BPM_BeatCallbackSet" ) ;
403
+ strError = " BASS ERROR in BASS_FX_BPM_BeatCallbackSet" ;
403
404
}
404
405
// get the broadcast name
405
406
const char * szIcy;
@@ -439,11 +440,11 @@ void CBassAudio::CompleteStreamConnect ( HSTREAM pSound )
439
440
// g_pCore->GetConsole()->Printf ( "BASS ERROR %d in BASS_SYNC_WMA_CHANGE", BASS_ErrorGetCode() );
440
441
}
441
442
else
442
- g_pCore-> GetConsole ()-> Printf ( " BASS ERROR %d in PlayStream b3D = %s path = %s" , BASS_ErrorGetCode (), m_b3D ? " true" : " false" , m_strPath.c_str () );
443
+ strError = SString ( " BASS ERROR %d in PlayStream b3D = %s path = %s" , BASS_ErrorGetCode (), m_b3D ? " true" : " false" , m_strPath.c_str () );
443
444
444
445
OutputDebugLine ( " [Bass] stream connect complete" );
445
446
446
- AddQueuedEvent ( SOUND_EVENT_STREAM_RESULT, m_strStreamName, GetLength (), pSound ? true : false );
447
+ AddQueuedEvent ( SOUND_EVENT_STREAM_RESULT, m_strStreamName, GetLength (), pSound ? true : false , strError );
447
448
}
448
449
449
450
@@ -1025,13 +1026,14 @@ void CBassAudio::ParseShoutcastMeta ( const SString& strMeta )
1025
1026
//
1026
1027
// Add queued event from
1027
1028
//
1028
- void CBassAudio::AddQueuedEvent ( eSoundEventType type, const SString& strString, double dNumber, bool bBool )
1029
+ void CBassAudio::AddQueuedEvent ( eSoundEventType type, const SString& strString, double dNumber, bool bBool, const SString& strError )
1029
1030
{
1030
1031
SSoundEventInfo info;
1031
1032
info.type = type;
1032
1033
info.strString = strString;
1033
1034
info.dNumber = dNumber;
1034
1035
info.bBool = bBool;
1036
+ info.strError = strError;
1035
1037
m_EventQueue.push_back ( info );
1036
1038
}
1037
1039
0 commit comments