add image rotation and flipping
This commit is contained in:
@@ -41,6 +41,8 @@ void GStreamerPipelineWidget::setupUI()
|
||||
auto* formatLabel = new QLabel("Video Format:", this);
|
||||
m_formatCombo = new QComboBox(this);
|
||||
m_formatCombo->addItem("1280x720@30fps UYVY (Default/Supported)", "1280,720,30,UYVY");
|
||||
m_formatCombo->setSizeAdjustPolicy(QComboBox::AdjustToMinimumContentsLengthWithIcon);
|
||||
m_formatCombo->setMinimumContentsLength(20);
|
||||
groupLayout->addWidget(formatLabel);
|
||||
groupLayout->addWidget(m_formatCombo);
|
||||
|
||||
@@ -54,6 +56,8 @@ void GStreamerPipelineWidget::setupUI()
|
||||
m_pipelinePresets->addItem("TCP H.264 Stream", "videoconvert ! x264enc ! h264parse ! mpegtsmux ! tcpserversink host=0.0.0.0 port=5000");
|
||||
m_pipelinePresets->addItem("MJPEG HTTP Stream", "videoconvert ! jpegenc ! multipartmux ! tcpserversink host=0.0.0.0 port=8080");
|
||||
m_pipelinePresets->addItem("Save to File", "videoconvert ! x264enc ! mp4mux ! filesink location=/tmp/output.mp4");
|
||||
m_pipelinePresets->setSizeAdjustPolicy(QComboBox::AdjustToMinimumContentsLengthWithIcon);
|
||||
m_pipelinePresets->setMinimumContentsLength(25);
|
||||
|
||||
connect(m_pipelinePresets, QOverload<int>::of(&QComboBox::currentIndexChanged),
|
||||
this, &GStreamerPipelineWidget::onPipelinePresetChanged);
|
||||
@@ -91,6 +95,8 @@ void GStreamerPipelineWidget::setupUI()
|
||||
m_statusLabel->setStyleSheet("QLabel { background-color: #f0f0f0; padding: 5px; border-radius: 3px; }");
|
||||
groupLayout->addWidget(m_statusLabel);
|
||||
|
||||
groupBox->setMaximumWidth(500);
|
||||
|
||||
mainLayout->addWidget(groupBox);
|
||||
mainLayout->addStretch();
|
||||
|
||||
@@ -305,7 +311,7 @@ void GStreamerPipelineWidget::onFormatsReceived(const QJsonObject& response)
|
||||
QString format = fmt["format"].toString();
|
||||
|
||||
QString displayText = QString("%1x%2@%3fps %4").arg(width, height, fps).arg(format);
|
||||
QString data = QString("%1,%2,%3,%4").arg(width, height, fps).arg(format);
|
||||
QString data = QString("%1,%2,%3,%4").arg(width).arg(height).arg(fps).arg(format);
|
||||
|
||||
m_formatCombo->addItem(displayText, data);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user