Qt Centre Forum >
Qt >
Newbie > QtWebEngine display black block when I called QWidget::winId() for displaying video
View Full Version : QtWebEngine display black block when I called QWidget::winId() for displaying video
swarupa
11th March 2016, 07:01
Hi Everyone,
Iam new to Qt. Iam displaying a video as well as a webpage by using qtwebengine on the same mainwindow. But QtWebEngine display black block when I called QWidget::winId().
Iam using winId() for displaying my video on a widget. But it is affecting my webpage. i dont know why its happening. Iam getting the correct winid for displaying the video on a widget and iam able to display video. but webpage
is blocked by black screen.
anda_skoa
11th March 2016, 12:00
Can you be more specific?
Which widget are you getting te windId() for?
Where is this widget relative to the web view? Parent, sibling?
Cheers,
_
swarupa
12th March 2016, 06:54
Hi,
In the following example you can observe the black block if you run the code. In the same way iam also getting problem when i display video by using its corresponding winId(). its is affecting webengine by displaying black block on it..
When i searched in the net i found QtQTBUG-48130
Calling winId() on a widget breaks QOpenGLWidget/QQuickWidget/QWebEngineView in the same TLW.
QtWebEngine display black block when I called QWidget::winId().
for more information on the bug please visit following link. They said they fixed the bug in 5.6.0 RC
https://bugreports.qt.io/browse/QTBUG-48130
But how to install 5.6.0 RC now.. i dont see it in online installer.. if you provide me information about how to install 5.6.0 RC that will be helpful to me..
#include "mainwindow.h"
#include "ui_mainwindow.h"
#include <QPushButton>
#include <QWebEngineView>
#include <QWidget>
#include <QtCore/QDebug>
//#include <qDebug>
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
ui->setupUi(this);
#if 1
QPushButton *btn = new QPushButton;
ui->gridLayout->addWidget(btn);
qDebug()<<btn->winId();
#endif
QWebEngineView *web = new QWebEngineView;
ui->gtridLayout->addWidget(web);
web->load(QUrl("http://www.google.com"));
}
MainWindow::~MainWindow()
{
delete ui;
}
Thanks,,
anda_skoa
12th March 2016, 11:38
But how to install 5.6.0 RC now.. i dont see it in online installer.. if you provide me information about how to install 5.6.0 RC that will be helpful to me..
http://download.qt.io/development_releases/qt/5.6/5.6.0-rc/
Cheers,
_
swarupa
12th March 2016, 15:04
Hi,
I have already downloaded qt-opensource-linux-x64-5.6.0-rc.run file. But it is a 64 bit file. i need 32 bit file because iam using 32 bit ubuntu with 14.04 version. But i dont find 32 bit file in that link. so please if you know how to download 32 bit file let me know.
Thanks,
anda_skoa
12th March 2016, 16:07
Then you will either have to build it yourself or wait for the 5.6 release next week.
Cheers,
_
swarupa
23rd March 2016, 16:12
Hi all ,
when will qt release 5.6 version for 32-bit ubuntu OS? Already final release on march 16th is over. Does any one have idea on this release. please let me know if any one knows it.
Thanks
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.