summaryrefslogtreecommitdiff
path: root/plugins/Jingle/src/account.h
blob: ae974b93630d657bf76f250a3c0f196acca88764 (plain)
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
35
36
#ifndef _ACCOUNT_H
#define _ACCOUNT_H

struct CJabberAccount : public MZeroedObject
{
	CJabberAccount(IJabberInterface *_1);
	~CJabberAccount();

	IJabberInterface *m_api;

	CMOption<bool> m_bEnableVOIP;

	void Init();
	static void InitHooks();

	void InitVoip(bool bEnable);
	bool OnICECandidate(const TiXmlElement *Node);
	bool OnRTPDescription(const TiXmlElement *Node);
	bool VOIPCreatePipeline();
	bool VOIPTerminateSession(const char *reason = "cancel");
	bool VOIPCallIinitiate(MCONTACT hContact);

	const char *m_szModuleName;
	CMStringA m_voipSession, m_voipPeerJid;
	CMStringA m_voipICEPwd, m_voipICEUfrag, m_medianame;
	bool m_isOutgoing = false;
	TiXmlDocument m_offerDoc;
	const TiXmlElement *m_offerNode = 0;
	HANDLE m_hVoiceEvent = 0;
	struct _GstElement *m_pipe1 = 0;
	struct _GstElement *m_webrtc1 = 0;
};

extern OBJLIST<CJabberAccount> g_arJabber;

#endif //_ACCOUNT_H