|
LONG Buffoper(WORD mode) | Description: Positionne ou retourne l'état du système sonore.
Opcode: 136 (0x0088)
Availability: Présent si le bit 2 du cookie '_SND' est à 1 (0x04).
Parameters:
mode est un champ de bits dont voici la composition :
Nom Masque Signification PLAY_ENABLE 0x01 Démarre la resitution sonore. L'échantillon doit auparavant être défini au moyen de Buffptr(). PLAY_REPEAT 0x02 Ce drapeau permet de jouer le son en boucle. Arrivé à la fin du tampon, la son recommence au début jusqu'à ce que le son soit coupé à l'aide de Buffoper(0). RECORD_ENABLE 0x04 Démarre l'enregistrement du son. Le tampon d'enregistrement doit auparavant être défini au moyen de Buffptr(). RECORD_REPEAT 0x08 Ce drapeau permet d'enregistrer en continu dans le tampon d'enregistrement. L'enregistrement est alors cyclique. Arrivé à la fin du tampon, il recommence au début.
En appelant la fonction avec mode positionné à SND_INQUIRE(-1), Buffoper() retourne un champ de bits de même composition que ci-dessus indiquant l'état du système sonore.
Binding: move.w mode,-(sp) move.w #$88,-(sp) trap #14 addq.l #4,sp Return value: Buffoper() renvoie 0 en cas de succès et une valeur non nulle sinon, excepté dans le mode INQUIRE comme indiqué plus haut.
Definition:Le système sonore utilise une file FIFO (premier entré, premier sorti) de 32 bits. La file de lecture ne se vide que lorsque le bit PLAY_ENABLE est à zéro, et la file d'enregistrement lorsque le bit RECORD_ENABLE est à zéro. Lorsque vous changez les bornes d'un des buffers il faut vous assurer que le bit correspondant est à zéro si vous voulez que les changements prennent effet immédiatement.
mailto: Stabylo
HTTP: http://removers.atari.org
LONG Buffoper(WORD mode) | Description: Sets or reads the state of the harware sound system
Opcode: 136 (0x0088)
Availability: Available if '_SND' cookie has bit 2 set (0x04).
Parameters:
Name Bit Mask Meaning PLAY_ENABLE 0x01 Enable DMA Sound Playback. The sound must have been previously identified to the XBIOS with the Buffptr() function. PLAY_REPEAT 0x02 Setting this flag will cause any sound currently playing or started as a result of this call to be looped indefinitely (until Buffoper(0) is used). RECORD_ENABLE 0x04 Enable DMA Sound Recording. The sound must have been previously identified to the XBIOS with the Buffptr() function. RECORD_REPEAT 0x08 Setting this flag during a record will cause the recording to continue indefinitely within the currently set recording buffer (as set by Buffptr())
Alternately, calling this function with a mode parameter of SND_INQUIRE (-1) will return a bit mask indicating the current sound system state as shown above.
Binding: move.w mode,-(sp) move.w #$88,-(sp) trap #14 addq.l #4,sp Return value: Buffoper() returns 0 when successful or non-zero otherwise (except in inquire mode as indicated above).
Definition:The sound system uses a 32 bit FIFO (First In First Out). The FIFO is only guaranteed to be clear when the record enable bit is clear. When transferring new data to the record buffers, the record enable bit should be cleared to flush the FIFO.
mailto: Stabylo
HTTP: http://removers.atari.org
See Also: Buffptr() Setbuffer() Setmode() Setinterrupt() |
Thanks for your GEMTOS visit!!!
(C) 2000 Gemtos.free.fr. All rights reserved by the authors.
|