[Gambas-user] Release of Gambas 3 RC3. But I have a dream....

Benoît Minisini gambas at ...1...
Wed Sep 7 19:09:37 CEST 2011


> > And where will these file descriptors come from?
> 
> ...from ALSA.
> 
> If I have a Gambas3-program, able to *receive* data Midi from ALSA
> (external Midi-Keyboard-->ALSA-sistem--->My-Gambas-Program), I could use
> "snd_seq_poll_descriptors_count()" and "snd_seq_poll_descriptors()" ALSA
> functions to get one or more file descriptors and event masks for the
> sequencer device; these file descriptors can be used to wait for events.
> 
> When I receive an event, I 'ld check if the device is actually ready for
> reading or writing by calling snd_seq_poll_descriptors_revents().
> 
> These ALSA functions are designed to be used with poll() !
> 
> I'ld need some mechanism to watch a file that is identified by its
> already opened file descriptor.
> 
> Bye
> Paolo
> 

Did you try to use "OPEN ... FOR READ / WRITE" on "/proc/self/fd/xxx" where 
xxx is the file descriptor you want to watch?

-- 
Benoît Minisini




More information about the User mailing list