3 * Declarations of RTP audio routing class
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
9 * SPDX-License-Identifier: GPL-2.0-or-later
12 #ifndef RTP_AUDIO_ROUTING_H
13 #define RTP_AUDIO_ROUTING_H
20 channel_any
, // Used just for changes of mute
22 channel_stereo_left
, // L
23 channel_stereo_right
, // R
24 channel_stereo_both
// L+R
25 } audio_routing_channel_t
;
30 AudioRouting() = default;
31 ~AudioRouting() = default;
32 AudioRouting(const AudioRouting
&) = default;
33 AudioRouting
&operator=(const AudioRouting
&) = default;
35 AudioRouting(bool muted
, audio_routing_channel_t channel
);
36 bool isMuted() { return muted_
; }
37 void setMuted(bool muted
) { muted_
= muted
; }
38 audio_routing_channel_t
getChannel() { return channel_
; }
39 void setChannel(audio_routing_channel_t channel
) { channel_
= channel
; }
40 char const *formatAudioRoutingToString();
41 AudioRouting
getNextChannel(bool stereo_available
);
42 AudioRouting
convert(bool stereo_available
);
43 void mergeAudioRouting(AudioRouting new_audio_routing
);
47 audio_routing_channel_t channel_
;
49 Q_DECLARE_METATYPE(AudioRouting
)
51 #define AUDIO_MUTED true
52 #define AUDIO_UNMUTED false
55 #endif // RTP_AUDIO_ROUTING_H