- Apply parts of Ben Millwood's target bitfield patch (#3787)

- Fix Ryan's FIXME and have voip packet buffer on the server dynamically allocated via Z_Malloc and store pointers in a circular buffer
- Improve voip target parsing on top of Ben Millwood's patch
- Add new "spatial" target where speaker is spatialized in 3d space and can be heard by all clients in hearing range (s_alMaxDistance)
  (#4467)
- Decrease voip sound lengths from 240ms to 80ms per voip packet to mitigate udp packet loss and decrease latency
- Protocol version incremented to 71
This commit is contained in:
Thilo Schulz 2011-07-27 15:47:29 +00:00
parent 41ac8a232a
commit 2349148cf1
19 changed files with 403 additions and 241 deletions

View file

@ -250,9 +250,10 @@ typedef struct {
qboolean voipMuteAll;
// outgoing data...
int voipTarget1; // these three ints make up a bit mask of 92 bits.
int voipTarget2; // the bits say who a VoIP pack is addressed to:
int voipTarget3; // (1 << clientnum). See cl_voipSendTarget cvar.
// if voipTargets[i / 8] & (1 << (i % 8)),
// then we are sending to clientnum i.
uint8_t voipTargets[(MAX_CLIENTS + 7) / 8];
uint8_t voipFlags;
SpeexPreprocessState *speexPreprocessor;
SpeexBits speexEncoderBits;
void *speexEncoder;