#pragma once #include #include #include #include #include "balance-slider.hpp" class QGridLayout; class QLabel; class QSpinBox; class QCheckBox; class QComboBox; class OBSAdvAudioCtrl : public QObject { Q_OBJECT private: OBSSource source; QPointer forceMonoContainer; QPointer mixerContainer; QPointer balanceContainer; QPointer nameLabel; QPointer volume; QPointer forceMono; QPointer balance; QPointer labelL; QPointer labelR; QPointer syncOffset; QPointer monitoringType; QPointer mixer1; QPointer mixer2; QPointer mixer3; QPointer mixer4; QPointer mixer5; QPointer mixer6; OBSSignal volChangedSignal; OBSSignal syncOffsetSignal; OBSSignal flagsSignal; OBSSignal mixersSignal; static void OBSSourceFlagsChanged(void *param, calldata_t *calldata); static void OBSSourceVolumeChanged(void *param, calldata_t *calldata); static void OBSSourceSyncChanged(void *param, calldata_t *calldata); static void OBSSourceMixersChanged(void *param, calldata_t *calldata); public: OBSAdvAudioCtrl(QGridLayout *layout, obs_source_t *source_); virtual ~OBSAdvAudioCtrl(); inline obs_source_t *GetSource() const { return source; } void ShowAudioControl(QGridLayout *layout); public slots: void SourceFlagsChanged(uint32_t flags); void SourceVolumeChanged(float volume); void SourceSyncChanged(int64_t offset); void SourceMixersChanged(uint32_t mixers); void volumeChanged(double db); void downmixMonoChanged(bool checked); void balanceChanged(int val); void syncOffsetChanged(int milliseconds); void monitoringTypeChanged(int index); void mixer1Changed(bool checked); void mixer2Changed(bool checked); void mixer3Changed(bool checked); void mixer4Changed(bool checked); void mixer5Changed(bool checked); void mixer6Changed(bool checked); void ResetBalance(); };