X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=src%2Fclient.h;h=82792e9924312f9edb17b0065d0dbdadc7b0a54a;hb=46d18f60766f997d0ca37c5937f58c0c06477932;hp=b7460b635fd1d9227ee8a5fc018aa8340beea0c9;hpb=6a6908d7031a79b5767d86a4da056f65a742ac9f;p=umurmur.git diff --git a/src/client.h b/src/client.h index b7460b6..82792e9 100644 --- a/src/client.h +++ b/src/client.h @@ -1,5 +1,5 @@ -/* Copyright (C) 2009, Martin Johansson - Copyright (C) 2005-2009, Thorvald Natvig +/* Copyright (C) 2009-2010, Martin Johansson + Copyright (C) 2005-2010, Thorvald Natvig All rights reserved. @@ -46,10 +46,12 @@ #include "messages.h" #include "crypt.h" #include "timer.h" +#include "pds.h" #define BUFSIZE 2048 #define UDP_BUFSIZE 512 #define INACTICITY_TIMEOUT 15 /* Seconds */ +#define MAX_CODECS 10 #define IS_AUTH(_a_) ((_a_)->authenticated) @@ -67,17 +69,21 @@ typedef struct { uint32_t rxcount, msgsize, drainleft, txcount, txsize; int sessionId; uint64_t key; - char playerName[MAX_TEXT]; - int playerId; + char *playerName; bool_t authenticated, deaf, mute; + char *os, *release; + uint32_t version; + int codec_count; + int32_t codecs[MAX_CODECS]; int availableBandwidth; etimer_t lastActivity; struct dlist node; struct dlist txMsgQueue; int txQueueCount; - /* Channel */ - void *channel; /*Ugly... */ + void *channel; /* Ugly... */ + char *context; struct dlist chan_node; + struct dlist voicetargets; } client_t; @@ -94,5 +100,7 @@ client_t *Client_iterate(client_t **client); int Client_send_message_except(client_t *client, message_t *msg); int Client_read_udp(void); void Client_disconnect_all(); +int Client_voiceMsg(client_t *client, uint8_t *data, int len); +void recheckCodecVersions(); #endif