use integer for the fader level message

This commit is contained in:
Volker Fischer 2019-01-12 12:59:16 +00:00
parent ea24503fdc
commit 91642b0c2e
9 changed files with 24 additions and 19 deletions

View file

@ -1,6 +1,11 @@
3.4.4
- added support for controlling the audio mixer faders with a MIDI controller (MacOS only)
3.4.3 (2018-05-17) 3.4.3 (2018-05-17)

View file

@ -669,15 +669,15 @@ void CAudioMixerBoard::ApplyNewConClientList ( CVector<CChannelInfo>& vecChanInf
emit NumClientsChanged ( iNumConnectedClients ); emit NumClientsChanged ( iNumConnectedClients );
} }
void CAudioMixerBoard::SetFaderLevel ( const int iChannelIdx, void CAudioMixerBoard::SetFaderLevel ( const int iChannelIdx,
const double dValue ) const int iValue )
{ {
// only apply new fader level if channel index is valid and the fader is visible // only apply new fader level if channel index is valid and the fader is visible
if ( ( iChannelIdx >= 0 ) && ( iChannelIdx < MAX_NUM_CHANNELS ) ) if ( ( iChannelIdx >= 0 ) && ( iChannelIdx < MAX_NUM_CHANNELS ) )
{ {
if ( vecpChanFader[iChannelIdx]->IsVisible() ) if ( vecpChanFader[iChannelIdx]->IsVisible() )
{ {
vecpChanFader[iChannelIdx]->SetFaderLevel ( dValue ); vecpChanFader[iChannelIdx]->SetFaderLevel ( iValue );
} }
} }
} }

View file

@ -102,8 +102,8 @@ public:
void SetServerName ( const QString& strNewServerName ); void SetServerName ( const QString& strNewServerName );
void SetGUIDesign ( const EGUIDesign eNewDesign ); void SetGUIDesign ( const EGUIDesign eNewDesign );
void SetFaderLevel ( const int iChannelIdx, void SetFaderLevel ( const int iChannelIdx,
const double dValue ); const int iValue );
// settings // settings
CVector<QString> vecStoredFaderTags; CVector<QString> vecStoredFaderTags;

View file

@ -198,8 +198,8 @@ CClient::CClient ( const quint16 iPortNumber,
this, SLOT ( OnSndCrdReinitRequest ( int ) ) ); this, SLOT ( OnSndCrdReinitRequest ( int ) ) );
QObject::connect ( &Sound, QObject::connect ( &Sound,
SIGNAL ( ControllerInFaderLevel ( int, double ) ), SIGNAL ( ControllerInFaderLevel ( int, int ) ),
SIGNAL ( ControllerInFaderLevel ( int, double ) ) ); SIGNAL ( ControllerInFaderLevel ( int, int ) ) );
QObject::connect ( &Socket, SIGNAL ( InvalidPacketReceived ( CHostAddress ) ), QObject::connect ( &Socket, SIGNAL ( InvalidPacketReceived ( CHostAddress ) ),
this, SLOT ( OnInvalidPacketReceived ( CHostAddress ) ) ); this, SLOT ( OnInvalidPacketReceived ( CHostAddress ) ) );

View file

@ -411,7 +411,7 @@ signals:
#endif #endif
void Disconnected(); void Disconnected();
void ControllerInFaderLevel ( int iChannelIdx, double dValue ); void ControllerInFaderLevel ( int iChannelIdx, int iValue );
}; };
#endif /* !defined ( CLIENT_HOIHGE76GEKJH98_3_43445KJIUHF1912__INCLUDED_ ) */ #endif /* !defined ( CLIENT_HOIHGE76GEKJH98_3_43445KJIUHF1912__INCLUDED_ ) */

View file

@ -483,8 +483,8 @@ CClientDlg::CClientDlg ( CClient* pNCliP,
this, SLOT ( OnCLPingTimeWithNumClientsReceived ( CHostAddress, int, int ) ) ); this, SLOT ( OnCLPingTimeWithNumClientsReceived ( CHostAddress, int, int ) ) );
QObject::connect ( pClient, QObject::connect ( pClient,
SIGNAL ( ControllerInFaderLevel ( int, double ) ), SIGNAL ( ControllerInFaderLevel ( int, int ) ),
this, SLOT ( OnControllerInFaderLevel ( int, double ) ) ); this, SLOT ( OnControllerInFaderLevel ( int, int ) ) );
#ifdef ENABLE_CLIENT_VERSION_AND_OS_DEBUGGING #ifdef ENABLE_CLIENT_VERSION_AND_OS_DEBUGGING
QObject::connect ( pClient, QObject::connect ( pClient,

View file

@ -134,9 +134,9 @@ public slots:
int iPingTime, int iPingTime,
int iNumClients ); int iNumClients );
void OnControllerInFaderLevel ( const int iChannelIdx, void OnControllerInFaderLevel ( const int iChannelIdx,
const double dValue ) { MainMixerBoard->SetFaderLevel ( iChannelIdx, const int iValue ) { MainMixerBoard->SetFaderLevel ( iChannelIdx,
dValue ); } iValue ); }
#ifdef ENABLE_CLIENT_VERSION_AND_OS_DEBUGGING #ifdef ENABLE_CLIENT_VERSION_AND_OS_DEBUGGING
void OnCLVersionAndOSReceived ( CHostAddress InetAddr, void OnCLVersionAndOSReceived ( CHostAddress InetAddr,

View file

@ -100,9 +100,9 @@ void CSoundBase::run()
void CSoundBase::ParseMIDIMessage ( const CVector<int8_t>& vMIDIPaketBytes ) void CSoundBase::ParseMIDIMessage ( const CVector<int8_t>& vMIDIPaketBytes )
{ {
// TODO // TODO
int iChannelIdx = 0; int iChannelIdx = 0;
double dFaderLevel = 0; int iFaderLevel = 0;
EmitControllerInFaderLevel ( iChannelIdx, dFaderLevel ); EmitControllerInFaderLevel ( iChannelIdx, iFaderLevel );
} }

View file

@ -89,8 +89,8 @@ public:
void EmitReinitRequestSignal ( const ESndCrdResetType eSndCrdResetType ) void EmitReinitRequestSignal ( const ESndCrdResetType eSndCrdResetType )
{ emit ReinitRequest ( eSndCrdResetType ); } { emit ReinitRequest ( eSndCrdResetType ); }
void EmitControllerInFaderLevel ( const int iChannelIdx, void EmitControllerInFaderLevel ( const int iChannelIdx,
const double dValue ) { emit ControllerInFaderLevel ( iChannelIdx, dValue ); } const int iValue ) { emit ControllerInFaderLevel ( iChannelIdx, iValue ); }
protected: protected:
// driver handling // driver handling
@ -129,7 +129,7 @@ protected:
signals: signals:
void ReinitRequest ( int iSndCrdResetType ); void ReinitRequest ( int iSndCrdResetType );
void ControllerInFaderLevel ( int iChannelIdx, double dValue ); void ControllerInFaderLevel ( int iChannelIdx, int iValue );
}; };
#endif /* !defined ( SOUNDBASE_HOIHGEH8_3_4344456456345634565KJIUHF1912__INCLUDED_ ) */ #endif /* !defined ( SOUNDBASE_HOIHGEH8_3_4344456456345634565KJIUHF1912__INCLUDED_ ) */