mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-10 10:33:29 -05:00
ATV Demod: feed the video signal scope only if the scope tab is selected
This commit is contained in:
parent
4ef2386945
commit
d292e2a040
@ -99,7 +99,8 @@ void ATVDemod::configure(
|
||||
float fltVoltLevelSynchroBlack,
|
||||
bool blnHSync,
|
||||
bool blnVSync,
|
||||
bool blnInvertVideo)
|
||||
bool blnInvertVideo,
|
||||
int intVideoTabIndex)
|
||||
{
|
||||
Message* msgCmd = MsgConfigureATVDemod::create(
|
||||
fltLineDurationUs,
|
||||
@ -110,7 +111,8 @@ void ATVDemod::configure(
|
||||
fltVoltLevelSynchroBlack,
|
||||
blnHSync,
|
||||
blnVSync,
|
||||
blnInvertVideo);
|
||||
blnInvertVideo,
|
||||
intVideoTabIndex);
|
||||
objMessageQueue->push(msgCmd);
|
||||
}
|
||||
|
||||
@ -223,7 +225,7 @@ void ATVDemod::feed(const SampleVector::const_iterator& begin, const SampleVecto
|
||||
}
|
||||
}
|
||||
|
||||
if(m_objScopeSink != 0)
|
||||
if ((m_objRunning.m_intVideoTabIndex == 1) && (m_objScopeSink != 0)) // do only if scope tab is selected and scope is available
|
||||
{
|
||||
m_objScopeSink->feed(m_objScopeSampleBuffer.begin(), m_objScopeSampleBuffer.end(), false); // m_ssb = positive only
|
||||
}
|
||||
|
@ -66,6 +66,7 @@ public:
|
||||
bool m_blnHSync;
|
||||
bool m_blnVSync;
|
||||
bool m_blnInvertVideo;
|
||||
int m_intVideoTabIndex;
|
||||
|
||||
ATVConfig() :
|
||||
m_intSampleRate(0),
|
||||
@ -77,7 +78,8 @@ public:
|
||||
m_fltVoltLevelSynchroBlack(1.0f),
|
||||
m_blnHSync(false),
|
||||
m_blnVSync(false),
|
||||
m_blnInvertVideo(false)
|
||||
m_blnInvertVideo(false),
|
||||
m_intVideoTabIndex(0)
|
||||
{
|
||||
}
|
||||
};
|
||||
@ -142,7 +144,8 @@ public:
|
||||
float fltVoltLevelSynchroBlack,
|
||||
bool blnHSync,
|
||||
bool blnVSync,
|
||||
bool blnInvertVideo);
|
||||
bool blnInvertVideo,
|
||||
int intVideoTabIndex);
|
||||
|
||||
void configureRF(MessageQueue* objMessageQueue,
|
||||
ATVModulation enmModulation,
|
||||
@ -188,7 +191,8 @@ private:
|
||||
float fltVoltLevelSynchroBlack,
|
||||
bool blnHSync,
|
||||
bool blnVSync,
|
||||
bool blnInvertVideo)
|
||||
bool blnInvertVideo,
|
||||
int intVideoTabIndex)
|
||||
{
|
||||
return new MsgConfigureATVDemod(
|
||||
fltLineDurationUs,
|
||||
@ -199,7 +203,8 @@ private:
|
||||
fltVoltLevelSynchroBlack,
|
||||
blnHSync,
|
||||
blnVSync,
|
||||
blnInvertVideo);
|
||||
blnInvertVideo,
|
||||
intVideoTabIndex);
|
||||
}
|
||||
|
||||
ATVConfig m_objMsgConfig;
|
||||
@ -214,7 +219,8 @@ private:
|
||||
float fltVoltLevelSynchroBlack,
|
||||
bool blnHSync,
|
||||
bool blnVSync,
|
||||
bool blnInvertVideo) :
|
||||
bool blnInvertVideo,
|
||||
int intVideoTabIndex) :
|
||||
Message()
|
||||
{
|
||||
m_objMsgConfig.m_fltVoltLevelSynchroBlack = fltVoltLevelSynchroBlack;
|
||||
@ -226,6 +232,7 @@ private:
|
||||
m_objMsgConfig.m_blnHSync = blnHSync;
|
||||
m_objMsgConfig.m_blnVSync = blnVSync;
|
||||
m_objMsgConfig.m_blnInvertVideo = blnInvertVideo;
|
||||
m_objMsgConfig.m_intVideoTabIndex = intVideoTabIndex;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -370,7 +370,8 @@ void ATVDemodGUI::applySettings()
|
||||
ui->blackLevel->value() / 1000.0f,
|
||||
ui->hSync->isChecked(),
|
||||
ui->vSync->isChecked(),
|
||||
ui->invertVideo->isChecked());
|
||||
ui->invertVideo->isChecked(),
|
||||
ui->screenTabWidget->currentIndex());
|
||||
|
||||
qDebug() << "ATVDemodGUI::applySettings:"
|
||||
<< " m_objChannelizer.inputSampleRate: " << m_objChannelizer->getInputSampleRate()
|
||||
@ -617,6 +618,11 @@ void ATVDemodGUI::on_fmDeviation_valueChanged(int value)
|
||||
applyRFSettings();
|
||||
}
|
||||
|
||||
void ATVDemodGUI::on_screenTabWidget_currentChanged(int index)
|
||||
{
|
||||
applySettings();
|
||||
}
|
||||
|
||||
void ATVDemodGUI::lineTimeUpdate()
|
||||
{
|
||||
float nominalLineTime = getNominalLineTime(ui->nbLines->currentIndex(), ui->fps->currentIndex());
|
||||
|
@ -84,6 +84,7 @@ private slots:
|
||||
void on_deltaFrequencyMinus_toggled(bool minus);
|
||||
void on_bfo_valueChanged(int value);
|
||||
void on_fmDeviation_valueChanged(int value);
|
||||
void on_screenTabWidget_currentChanged(int index);
|
||||
|
||||
private:
|
||||
Ui::ATVDemodGUI* ui;
|
||||
|
Loading…
Reference in New Issue
Block a user