简体   繁体   English

qtwebkit qt5 beta webgl

[英]qtwebkit qt5 beta webgl

I was trying to run WebGL application on QtWebKit (Qt 5.0 beta Version). 我试图在QtWebKit(Qt 5.0 beta版)上运行WebGL应用程序。 I am using eglfs plugin on a mips based platform. 我在基于mips的平台上使用eglfs插件。 I used QtTestBrowser as the test browser. 我使用QtTestBrowser作为测试浏览器。

I ran an webgl site- 我经营了一个webgl网站-

./QtTestBrowser -webgl -graphicsbased http://jsbin.com/ulazel

It reported no-webgl support. 它报告没有webgl支持。

I did a bit of debugging and found that in file 我做了一些调试,发现在文件中

qtwebkit/Source/WebKit/qt/WebCoreSupport/PageClientQt.cpp

it returns as it cannot find glViewport: 因为找不到glViewport而返回:

QGLWidget* glViewport = qobject_cast<QGLWidget*>(scrollArea->viewport());
    if (!glViewport) {
        //Returns from here....
        return;
    }

By enabling “-gl-viewport” I was able to get the glContext in HTML page. 通过启用“ -gl-viewport”,我可以在HTML页面中获取glContext。 But it was not properly displayed. 但是没有正确显示。 Also since every widget (launcherWindow etc) it was trying to create a “Window” intern calling eglCreateWindow() and resulting in memory issues (Around 12 window was created all full size of 1920×1080. Finally the displayed image is also not proper. 另外,由于每个小部件(launcherWindow等)都试图创建一个调用eglCreateWindow()的“窗口”实习生,从而导致内存问题(在12个左右的窗口中创建的全尺寸为1920×1080。最终显示的图像也不正确。

Any one have suggestion? 有人有建议吗? where i am going wrong? 我要去哪里错了?

WebGL is functional with additional patches on top of Qt5. WebGL在Qt5之上具有附加补丁的功能。 You might want to take a look at the patchset for WebGL for eglfs, at the below link. 您可能想在下面的链接中查看WebGL for eglfs的补丁集。

https://bugreports.qt-project.org/browse/QTBUG-30405 https://bugreports.qt-project.org/browse/QTBUG-30405

(Note - I have validated this only on ARMv7, but I cannot see a dependency on arch for this patchset) (注意-我仅在ARMv7上对此进行了验证,但是我看不到此补丁集对arch的依赖)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM