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);
|
CRevoicePlayer* plr = GetPlayerByClientPtr(cl);
|
||||||
plr->OnConnected(protocol);
|
plr->OnConnected(protocol);
|
||||||
|
|
||||||
if (protocol == 47) {
|
// default codec
|
||||||
plr->InitVoice(vct_speex);
|
plr->InitVoice(vct_speex);
|
||||||
}
|
|
||||||
|
|
||||||
//for p48 we will query sv_version cvar value later in mm_ClientConnect
|
//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()) {
|
switch (srcPlayer->GetCodecType()) {
|
||||||
case vct_silk:
|
case vct_silk:
|
||||||
{
|
{
|
||||||
//if (nDataLength > MAX_SILK_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SILK_VOICE_RATE)
|
if (nDataLength > MAX_SILK_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SILK_VOICE_RATE)
|
||||||
//return;
|
return;
|
||||||
|
|
||||||
silkData = chReceived; silkDataLen = nDataLength;
|
silkData = chReceived; silkDataLen = nDataLength;
|
||||||
speexData = transcodedBuf;
|
speexData = transcodedBuf;
|
||||||
@ -111,8 +110,8 @@ void SV_ParseVoiceData_emu(IGameClient* cl) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
case vct_speex:
|
case vct_speex:
|
||||||
//if (nDataLength > MAX_SPEEX_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SPEEX_VOICE_RATE)
|
if (nDataLength > MAX_SPEEX_DATA_LEN || srcPlayer->GetVoiceRate() > MAX_SPEEX_VOICE_RATE)
|
||||||
//return;
|
return;
|
||||||
|
|
||||||
speexData = chReceived; speexDataLen = nDataLength;
|
speexData = chReceived; speexDataLen = nDataLength;
|
||||||
silkData = transcodedBuf;
|
silkData = transcodedBuf;
|
||||||
|
Loading…
Reference in New Issue
Block a user