mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-07 22:25:46 +01:00
[Summary] Added possibility to identify IO thread which does not have required resources initialized during process callback handling
Conflicts: libs/ardour/ardour/audioengine.h libs/backends/wavesaudio/waves_audiobackend.cc libs/pbd/pbd/pool.h
This commit is contained in:
parent
017e580c9f
commit
ef59fbffa1
7 changed files with 42 additions and 1 deletions
|
|
@ -758,6 +758,17 @@ WavesAudioBackend::_audio_device_callback (const float* input_buffer,
|
|||
AudioEngine::thread_init_callback (this);
|
||||
}
|
||||
|
||||
if ( !engine.thread_initialised_for_audio_processing () ) {
|
||||
std::cerr << "\tWavesAudioBackend::_audio_device_callback (): It's an attempt to call process callback from the thread which didn't initialize it " << std::endl;
|
||||
|
||||
if (process_id != pthread_self() ) {
|
||||
std::cerr << "Process thread ID has changed. Expected thread: " << process_id << " current thread: " << pthread_self() << std::dec << " !" << std::endl;
|
||||
process_id = pthread_self();
|
||||
}
|
||||
|
||||
AudioEngine::thread_init_callback (this);
|
||||
}
|
||||
|
||||
engine.process_callback (nframes);
|
||||
|
||||
_write_audio_data_to_device (output_buffer, nframes);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue