rsked/mpdclient.cc
/// Set the volume to a given percentage of full (0-100).
///
Set the volume to a given percentage of full (0-100).
Set the volume to a given percentage of full ( 0 - 100 ) .
void Mpd_client::set_volume(unsigned pct)
{
    if (pct > 100) {
        pct = 100;
    }
    connect();
    assert_connected();
    if (not mpd_run_set_volume(m_conn, pct)) {
        enum mpd_server_error serr;
        diag_error("Mpd_client::set_volume: ",serr);
        throw Mpd_run_exception();
    }
}
void Mpd_client :: set_volume ( unsigned pct ) { if ( pct > 100 ) { pct = 100 ; } connect ( ) ; assert_connected ( ) ; if ( not mpd_run_set_volume ( m_conn , pct ) ) { enum mpd_server_error serr ; diag_error ( " " , serr ) ; throw Mpd_run_exception ( ) ; } }
Set the volume to a given percentage of full (0-100).
Set the volume to a given percentage of full ( 0 - 100 ) .