4 * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Jonghyuk Choi <jhchoi.choi@samsung.com>
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
22 #ifndef __AVSYS_AUDIO_PACTRL_H__
23 #define __AVSYS_AUDIO_PACTRL_H__
28 #include <avsys-audio-handle.h>
29 #include <pulse/pulseaudio.h>
30 #include <pulse/thread-mainloop.h>
31 #include <pulse/error.h>
32 #include <pulse/gccmacro.h>
33 #include <pulse/proplist.h>
39 AVSYS_AUDIO_PA_CTL_SINK_UNKNOWN = 0x0000,
40 AVSYS_AUDIO_PA_CTL_SINK_ALSA = 0x0001,
41 AVSYS_AUDIO_PA_CTL_SINK_BLUEZ = 0x0002,
53 #define ALSA_SINK_EXIST ((1 << (_EXIST + ALSA_SINK)))
54 #define ALSA_SINK_DEACTIVE ((1 << (_DEACTIVE + ALSA_SINK)))
55 #define ALSA_SINK_ACTIVE ((1 << (_ACTIVE + ALSA_SINK)))
57 #define BULEZ_SINK_EXIST ((1 << (_EXIST + BLUEZ_SINK)))
58 #define BULEZ_SINK_DEACTIVE ((1 << (_DEACTIVE + BLUEZ_SINK)))
59 #define BULEZ_SINK_ACTIVE ((1 << (_ACTIVE + BLUEZ_SINK)))
64 int avsys_audio_pa_ctrl_volume_by_index(unsigned int idx, int volume, int ch);
65 int avsys_audio_pa_ctrl_mute_by_index(unsigned int idx, int mute);
66 int avsys_audio_pa_ctrl_get_default_sink(int *sink);
72 #endif /* __AVSYS_AUDIO_PACTRL_H__ */