.\" muroar_beep.3 .TH "muroar_setvolume" "3" "April 2012" "muRoar" "muRoar Programmer's Manual" .SH NAME muroar_setvolume \- Set volume of a stream on a RoarAudio sound server .SH SYNOPSIS #include int muroar_setvolume (muroar_t fh, int stream, long unsigned int left, long unsigned int right); .SH "DESCRIPTION" This function sets the volume of a stream on a sound server supporting the RoarAudio protocol. It takes a connected control connection created with \fBroar_connect\fR(3) and used it to comunicate with the already connected server. In addition it takes the stream ID and the volume for the left and right channel. This function supports both mono and stereo streams. It also supports setting volume to multi-channel streams if the server supports UNMAPPED mode. To set a volume in mono just provide the same volume for both (left and right channel) channels. .SH "PARAMETERS" .TP \fBfh\fR The connected control connection. .TP \fBstream\fR This is the ID of the stream to set the volume for. .TP \fBleft\fR, \fBright\fR This is the volume of the corresponding channel. The value is a 16 bit unsigned number so it has the range from 0 (truly muted, -InfdB) to 65535 (full volume, 0dB). .SH "RETURN VALUE" On success this call return 0. On error, \-1 is returned. .SH BUGS In failure where is no way to tell was was going wrong. In case of failture the control connection needs to be closed with \fBmuroar_close\fR(3). .SH HISTORY This function first appeared in muRoar version 0.1.8. .SH "SEE ALSO" \fBmuroar_connect\fR(3), \fBmuroar_close\fR(3), \fBRoarAudio\fR(7). .\" ll