Fixed an issue with recording audio.
Prior to this fix, AudioEffectRecordInstance::init() was called before recording_active is set to true in AudioEffectRecord::set_recording_active(). This was setting is_recording to false in AudioEffectRecordInstance, because is_recording updates to the value of recording_active in AudioEffectRecordInstance::_io_thread_process(). To fix this issue, AudioEffectRecordInstance::init() is now called after recording_active is set to true.
This commit is contained in:
parent
f065b34e96
commit
86096313be
1 changed files with 3 additions and 2 deletions
|
@ -192,10 +192,11 @@ void AudioEffectRecord::set_recording_active(bool p_record) {
|
|||
}
|
||||
|
||||
ensure_thread_stopped();
|
||||
recording_active = true;
|
||||
current_instance->init();
|
||||
} else {
|
||||
recording_active = false;
|
||||
}
|
||||
|
||||
recording_active = p_record;
|
||||
}
|
||||
|
||||
bool AudioEffectRecord::is_recording_active() const {
|
||||
|
|
Loading…
Reference in a new issue