fix audio issue with licence dialog
This commit is contained in:
parent
c7dcfe855e
commit
e7bb2ad1c6
4 changed files with 24 additions and 4 deletions
|
@ -11,6 +11,7 @@
|
||||||
- fixed low-res icon issue (Ticket #28)
|
- fixed low-res icon issue (Ticket #28)
|
||||||
|
|
||||||
|
|
||||||
|
TODO insert licence setting in server dialog -> on per default
|
||||||
|
|
||||||
TODO support OPUS 64 in the server as a first step towards official 64 samples frame size support
|
TODO support OPUS 64 in the server as a first step towards official 64 samples frame size support
|
||||||
|
|
||||||
|
@ -25,8 +26,6 @@ TODO client: larger sound card buffers are managed by conversion buffer, not in
|
||||||
|
|
||||||
TODO #12 A server in the same NAT region as the client is not visible (https://sourceforge.net/p/llcon/bugs/12/)
|
TODO #12 A server in the same NAT region as the client is not visible (https://sourceforge.net/p/llcon/bugs/12/)
|
||||||
|
|
||||||
TODO #71 Increase "stability" of Connection Setup server list
|
|
||||||
|
|
||||||
TODO update text in CAboutDlg
|
TODO update text in CAboutDlg
|
||||||
|
|
||||||
TODO mixer faders linear -> log gain is better
|
TODO mixer faders linear -> log gain is better
|
||||||
|
|
|
@ -52,6 +52,7 @@ CClient::CClient ( const quint16 iPortNumber,
|
||||||
eAudioQuality ( AQ_NORMAL ),
|
eAudioQuality ( AQ_NORMAL ),
|
||||||
eAudioChannelConf ( CC_MONO ),
|
eAudioChannelConf ( CC_MONO ),
|
||||||
bIsInitializationPhase ( true ),
|
bIsInitializationPhase ( true ),
|
||||||
|
bMuteInputAndOutput ( false ),
|
||||||
Socket ( &Channel, iPortNumber ),
|
Socket ( &Channel, iPortNumber ),
|
||||||
Sound ( AudioCallback, this, iCtrlMIDIChannel, bNoAutoJackConnect ),
|
Sound ( AudioCallback, this, iCtrlMIDIChannel, bNoAutoJackConnect ),
|
||||||
iAudioInFader ( AUD_FADER_IN_MIDDLE ),
|
iAudioInFader ( AUD_FADER_IN_MIDDLE ),
|
||||||
|
@ -820,8 +821,9 @@ void CClient::Init()
|
||||||
2 );
|
2 );
|
||||||
}
|
}
|
||||||
|
|
||||||
// reset initialization phase flag
|
// reset initialization phase flag and mute flag
|
||||||
bIsInitializationPhase = true;
|
bIsInitializationPhase = true;
|
||||||
|
bMuteInputAndOutput = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CClient::AudioCallback ( CVector<int16_t>& psData, void* arg )
|
void CClient::AudioCallback ( CVector<int16_t>& psData, void* arg )
|
||||||
|
@ -842,6 +844,12 @@ static CTimingMeas JitterMeas ( 1000, "test2.dat" );
|
||||||
JitterMeas.Measure();
|
JitterMeas.Measure();
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// mute input if requested
|
||||||
|
if ( bMuteInputAndOutput )
|
||||||
|
{
|
||||||
|
vecsStereoSndCrd.Reset ( 0 );
|
||||||
|
}
|
||||||
|
|
||||||
// check if a conversion buffer is required or not
|
// check if a conversion buffer is required or not
|
||||||
if ( bSndCrdConversionBufferRequired )
|
if ( bSndCrdConversionBufferRequired )
|
||||||
{
|
{
|
||||||
|
@ -869,6 +877,12 @@ JitterMeas.Measure();
|
||||||
// process audio data
|
// process audio data
|
||||||
ProcessAudioDataIntern ( vecsStereoSndCrd );
|
ProcessAudioDataIntern ( vecsStereoSndCrd );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// mute output if requested
|
||||||
|
if ( bMuteInputAndOutput )
|
||||||
|
{
|
||||||
|
vecsStereoSndCrd.Reset ( 0 );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void CClient::ProcessAudioDataIntern ( CVector<int16_t>& vecsStereoSndCrd )
|
void CClient::ProcessAudioDataIntern ( CVector<int16_t>& vecsStereoSndCrd )
|
||||||
|
|
|
@ -247,6 +247,8 @@ public:
|
||||||
bool GetFraSiFactDefSupported() { return bFraSiFactDefSupported; }
|
bool GetFraSiFactDefSupported() { return bFraSiFactDefSupported; }
|
||||||
bool GetFraSiFactSafeSupported() { return bFraSiFactSafeSupported; }
|
bool GetFraSiFactSafeSupported() { return bFraSiFactSafeSupported; }
|
||||||
|
|
||||||
|
void SetMuteInputAndOutputState ( const bool bDoMute ) { bMuteInputAndOutput = bDoMute; }
|
||||||
|
|
||||||
void SetRemoteChanGain ( const int iId, const double dGain )
|
void SetRemoteChanGain ( const int iId, const double dGain )
|
||||||
{ Channel.SetRemoteChanGain ( iId, dGain ); }
|
{ Channel.SetRemoteChanGain ( iId, dGain ); }
|
||||||
|
|
||||||
|
@ -331,6 +333,7 @@ protected:
|
||||||
EAudioQuality eAudioQuality;
|
EAudioQuality eAudioQuality;
|
||||||
EAudChanConf eAudioChannelConf;
|
EAudChanConf eAudioChannelConf;
|
||||||
bool bIsInitializationPhase;
|
bool bIsInitializationPhase;
|
||||||
|
bool bMuteInputAndOutput;
|
||||||
CVector<unsigned char> vecCeltData;
|
CVector<unsigned char> vecCeltData;
|
||||||
|
|
||||||
CHighPrioSocket Socket;
|
CHighPrioSocket Socket;
|
||||||
|
|
|
@ -743,7 +743,8 @@ void CClientDlg::OnLicenceRequired ( ELicenceType eLicenceType )
|
||||||
{
|
{
|
||||||
CLicenceDlg LicenceDlg;
|
CLicenceDlg LicenceDlg;
|
||||||
|
|
||||||
// TODO mute the client
|
// mute the client
|
||||||
|
pClient->SetMuteInputAndOutputState ( true );
|
||||||
|
|
||||||
// Open the licence dialog and check if the licence was accepted. In
|
// Open the licence dialog and check if the licence was accepted. In
|
||||||
// case the dialog is just closed or the decline button was pressed,
|
// case the dialog is just closed or the decline button was pressed,
|
||||||
|
@ -752,6 +753,9 @@ void CClientDlg::OnLicenceRequired ( ELicenceType eLicenceType )
|
||||||
{
|
{
|
||||||
Disconnect();
|
Disconnect();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// unmute the client
|
||||||
|
pClient->SetMuteInputAndOutputState ( false );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue