1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#ifndef _UTIL_H_
#define _UTIL_H_
#include <glib.h>
#include "cmumble.h"
gpointer
cmumble_find_by_id(GList *list, gsize member_offset, guint id);
char *
cmumble_get_os_name(void);
static inline struct cmumble_user *
find_user(struct cmumble *cm, uint32_t session_id)
{
return cmumble_find_by_id(cm->users,
G_STRUCT_OFFSET(struct cmumble_user, session),
session_id);
}
static inline struct cmumble_channel *
find_channel(struct cmumble *cm, guint channel_id)
{
return cmumble_find_by_id(cm->channels,
G_STRUCT_OFFSET(struct cmumble_channel, id),
channel_id);
}
GstBuffer *
_gst_opus_enc_create_id_buffer(gint nchannels, gint n_stereo_streams,
gint sample_rate, guint8 channel_mapping_family,
const guint8 * channel_mapping);
#endif /* _UTIL_H_ */
|