On 03/09/2018 10:55 PM, Martin Schreiber wrote:
> On 03/09/2018 10:05 PM, fredvs wrote:
>> Re-re-re Hello.
>>
>> About the crash of the demo, this solves all on my system:
>>
>> procedure tmainfo.soundoff() at line 220:
>>
>> wavethread.terminate();
>> wavethread.active:= false; // add this here, not 4 lines later.
>>
> The problem probably is
> "
> int
> alsa_object_flush(struct audio_object *object)
> {
> struct alsa_object *self = to_alsa_object(object);
> if (!self) return 0;
>
> // Using snd_pcm_drop does not discard the audio, so reopen the device
> // to reset the sound buffer.
> if (self->is_open) {
> audio_object_close(object); <<<<----
> "
> there are still pending operations in another thread.
>
"
int
alsa_object_flush(struct audio_object *object)
{
struct alsa_object *self = to_alsa_object(object);
if (self && self->handle){
snd_pcm_drop(self->handle);
}
return 0;
}
"
seems to work. There still is the problem that the alsa buffer is many
seconds long.
Martin
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
mseide-msegui-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk