mirror of
https://github.com/rehlds/revoice.git
synced 2024-12-28 15:45:52 +03:00
Merge pull request #6 from Adidasman1/master
Uncommented limiter voice and default voice codex speex for everyone.
This commit is contained in:
commit
fcc2d4f522
@ -9,9 +9,8 @@ void Rehlds_ClientConnected_Hook(IRehldsHook_ClientConnected* chain, IGameClient
|
||||
CRevoicePlayer* plr = GetPlayerByClientPtr(cl);
|
||||
plr->OnConnected(protocol);
|
||||
|
||||
if (protocol == 47) {
|
||||
plr->InitVoice(vct_speex);
|
||||
}
|
||||
// default codec
|
||||
plr->InitVoice(vct_speex);
|
||||
|
||||
//for p48 we will query sv_version cvar value later in mm_ClientConnect
|
||||
}
|
||||
@ -101,8 +100,8 @@ void SV_ParseVoiceData_emu(IGameClient* cl) {
|
||||
switch (srcPlayer->GetCodecType()) {
|
||||
case vct_silk:
|
||||
{
|
||||
//if (nDataLength > MAX_SILK_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SILK_VOICE_RATE)
|
||||
//return;
|
||||
if (nDataLength > MAX_SILK_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SILK_VOICE_RATE)
|
||||
return;
|
||||
|
||||
silkData = chReceived; silkDataLen = nDataLength;
|
||||
speexData = transcodedBuf;
|
||||
@ -111,8 +110,8 @@ void SV_ParseVoiceData_emu(IGameClient* cl) {
|
||||
}
|
||||
|
||||
case vct_speex:
|
||||
//if (nDataLength > MAX_SPEEX_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SPEEX_VOICE_RATE)
|
||||
//return;
|
||||
if (nDataLength > MAX_SPEEX_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SPEEX_VOICE_RATE)
|
||||
return;
|
||||
|
||||
speexData = chReceived; speexDataLen = nDataLength;
|
||||
silkData = transcodedBuf;
|
||||
|
Loading…
Reference in New Issue
Block a user