1 /*****************************************************************************
2 * audio.cpp: audio part of the media player
3 *****************************************************************************
4 * Copyright (C) 2010 the VideoLAN team
7 * Authors: RĂ©mi Duraffort <ivoire@videolan.org>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
22 *****************************************************************************/
27 using namespace libvlc;
35 libvlc_media_player_release( m_player );
38 void Audio::toggleMute()
40 libvlc_audio_toggle_mute( m_player );
45 return libvlc_audio_get_mute( m_player );
48 void Audio::setMute( int mute )
50 libvlc_audio_set_mute( m_player, mute );
55 return libvlc_audio_get_volume( m_player );
58 void Audio::setVolume( int volume )
60 libvlc_audio_set_volume( m_player, volume );
65 return libvlc_audio_get_track( m_player );
68 int Audio::trackCount()
70 return libvlc_audio_get_track_count( m_player );
73 void Audio::setTrack( int track )
75 libvlc_audio_set_track( m_player, track );
78 void Audio::setMediaPlayer( libvlc_media_player_t *player )
80 libvlc_media_player_retain( player );