Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Video Parameters dialogue to ld-analyse #757

Merged
merged 11 commits into from
Jun 11, 2022
Merged
2 changes: 1 addition & 1 deletion tools/ld-analyse/blacksnranalysisdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ BlackSnrAnalysisDialog::BlackSnrAnalysisDialog(QWidget *parent) :
numberOfFrames = 0;

// Connect to scale changed slot
connect(((QObject*)plot->axisWidget(QwtPlot::xBottom)) , SIGNAL(scaleDivChanged () ), this, SLOT(scaleDivChangedSlot () ));
connect(plot->axisWidget(QwtPlot::xBottom), &QwtScaleWidget::scaleDivChanged, this, &BlackSnrAnalysisDialog::scaleDivChangedSlot);
}

BlackSnrAnalysisDialog::~BlackSnrAnalysisDialog()
Expand Down
59 changes: 37 additions & 22 deletions tools/ld-analyse/chromadecoderconfigdialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,16 @@
<x>0</x>
<y>0</y>
<width>460</width>
<height>514</height>
<height>637</height>
</rect>
</property>
<property name="windowTitle">
<string>Chroma Decoder Configuration</string>
</property>
<layout class="QVBoxLayout" name="outerVerticalLayout">
<property name="sizeConstraint">
<enum>QLayout::SetFixedSize</enum>
</property>
<item>
<widget class="QLabel" name="chromaGainLabel">
<property name="text">
Expand All @@ -23,6 +26,18 @@
</item>
<item>
<widget class="QSlider" name="chromaGainHorizontalSlider">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>400</width>
<height>0</height>
</size>
</property>
<property name="maximum">
<number>200</number>
</property>
Expand Down Expand Up @@ -92,6 +107,19 @@
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer_1">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>15</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QTabWidget" name="standardTabs">
<property name="currentIndex">
Expand Down Expand Up @@ -147,7 +175,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>15</height>
</size>
</property>
</spacer>
Expand All @@ -167,7 +195,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>15</height>
</size>
</property>
</spacer>
Expand Down Expand Up @@ -207,7 +235,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>15</height>
</size>
</property>
</spacer>
Expand All @@ -234,7 +262,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>0</height>
</size>
</property>
</spacer>
Expand Down Expand Up @@ -291,7 +319,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>15</height>
</size>
</property>
</spacer>
Expand Down Expand Up @@ -339,7 +367,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>15</height>
</size>
</property>
</spacer>
Expand Down Expand Up @@ -376,7 +404,7 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>0</height>
</size>
</property>
</spacer>
Expand All @@ -385,25 +413,12 @@
</widget>
</widget>
</item>
<item>
<spacer name="verticalSpacer_1">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<resources/>
<connections/>
<buttongroups>
<buttongroup name="palFilterButtonGroup"/>
<buttongroup name="ntscFilterButtonGroup"/>
<buttongroup name="palFilterButtonGroup"/>
</buttongroups>
</ui>
13 changes: 13 additions & 0 deletions tools/ld-analyse/configuration.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ void Configuration::writeConfiguration(void)
configuration->setValue("blackSnrAnalysisDialogGeometry", settings.windows.blackSnrAnalysisDialogGeometry);
configuration->setValue("whiteSnrAnalysisDialogGeometry", settings.windows.whiteSnrAnalysisDialogGeometry);
configuration->setValue("closedCaptionDialogGeometry", settings.windows.closedCaptionDialogGeometry);
configuration->setValue("videoParametersDialogGeometry", settings.windows.videoParametersDialogGeometry);
configuration->setValue("chromaDecoderConfigDialogGeometry", settings.windows.chromaDecoderConfigDialogGeometry);
configuration->endGroup();

Expand Down Expand Up @@ -111,6 +112,7 @@ void Configuration::readConfiguration(void)
settings.windows.blackSnrAnalysisDialogGeometry = configuration->value("blackSnrAnalysisDialogGeometry").toByteArray();
settings.windows.whiteSnrAnalysisDialogGeometry = configuration->value("whiteSnrAnalysisDialogGeometry").toByteArray();
settings.windows.closedCaptionDialogGeometry = configuration->value("closedCaptionDialogGeometry").toByteArray();
settings.windows.videoParametersDialogGeometry = configuration->value("videoParametersDialogGeometry").toByteArray();
settings.windows.chromaDecoderConfigDialogGeometry = configuration->value("chromaDecoderConfigDialogGeometry").toByteArray();
configuration->endGroup();
}
Expand All @@ -135,6 +137,7 @@ void Configuration::setDefault(void)
settings.windows.blackSnrAnalysisDialogGeometry = QByteArray();
settings.windows.whiteSnrAnalysisDialogGeometry = QByteArray();
settings.windows.closedCaptionDialogGeometry = QByteArray();
settings.windows.videoParametersDialogGeometry = QByteArray();
settings.windows.chromaDecoderConfigDialogGeometry = QByteArray();

// Write the configuration
Expand Down Expand Up @@ -265,6 +268,16 @@ QByteArray Configuration::getClosedCaptionDialogGeometry(void)
return settings.windows.closedCaptionDialogGeometry;
}

void Configuration::setVideoParametersDialogGeometry(QByteArray videoParametersDialogGeometry)
{
settings.windows.videoParametersDialogGeometry = videoParametersDialogGeometry;
}

QByteArray Configuration::getVideoParametersDialogGeometry(void)
{
return settings.windows.videoParametersDialogGeometry;
}

void Configuration::setChromaDecoderConfigDialogGeometry(QByteArray chromaDecoderConfigDialogGeometry)
{
settings.windows.chromaDecoderConfigDialogGeometry = chromaDecoderConfigDialogGeometry;
Expand Down
3 changes: 3 additions & 0 deletions tools/ld-analyse/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ class Configuration : public QObject
QByteArray getWhiteSnrAnalysisDialogGeometry(void);
void setClosedCaptionDialogGeometry(QByteArray closedCaptionDialogGeometry);
QByteArray getClosedCaptionDialogGeometry(void);
void setVideoParametersDialogGeometry(QByteArray videoParametersConfigDialogGeometry);
QByteArray getVideoParametersDialogGeometry(void);
void setChromaDecoderConfigDialogGeometry(QByteArray chromaDecoderConfigDialogGeometry);
QByteArray getChromaDecoderConfigDialogGeometry(void);

Expand Down Expand Up @@ -98,6 +100,7 @@ public slots:
QByteArray blackSnrAnalysisDialogGeometry;
QByteArray whiteSnrAnalysisDialogGeometry;
QByteArray closedCaptionDialogGeometry;
QByteArray videoParametersDialogGeometry;
QByteArray chromaDecoderConfigDialogGeometry;
};

Expand Down
2 changes: 1 addition & 1 deletion tools/ld-analyse/dropoutanalysisdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ DropoutAnalysisDialog::DropoutAnalysisDialog(QWidget *parent) :
numberOfFrames = 0;

// Connect to scale changed slot
connect(((QObject*)plot->axisWidget(QwtPlot::xBottom)) , SIGNAL(scaleDivChanged() ), this, SLOT(scaleDivChangedSlot() ));
connect(plot->axisWidget(QwtPlot::xBottom), &QwtScaleWidget::scaleDivChanged, this, &DropoutAnalysisDialog::scaleDivChangedSlot);
}

DropoutAnalysisDialog::~DropoutAnalysisDialog()
Expand Down
3 changes: 3 additions & 0 deletions tools/ld-analyse/ld-analyse.pro
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ SOURCES += \
oscilloscopedialog.cpp \
vectorscopedialog.cpp \
aboutdialog.cpp \
videoparametersdialog.cpp \
chromadecoderconfigdialog.cpp \
tbcsource.cpp \
vbidialog.cpp \
Expand Down Expand Up @@ -65,6 +66,7 @@ HEADERS += \
oscilloscopedialog.h \
vectorscopedialog.h \
aboutdialog.h \
videoparametersdialog.h \
chromadecoderconfigdialog.h \
tbcsource.h \
vbidialog.h \
Expand Down Expand Up @@ -99,6 +101,7 @@ FORMS += \
oscilloscopedialog.ui \
vectorscopedialog.ui \
aboutdialog.ui \
videoparametersdialog.ui \
chromadecoderconfigdialog.ui \
vbidialog.ui \
dropoutanalysisdialog.ui \
Expand Down
Loading