Skip to content

Commit

Permalink
Add eglfs-viv support for INTEGRITY
Browse files Browse the repository at this point in the history
Change-Id: I5ea23eeac930dcc628047e3322061d543bddb643
Reviewed-by: Laszlo Agocs <[email protected]>
Reviewed-by: Oswald Buddenhagen <[email protected]>
Reviewed-by: Nikola Velinov <[email protected]>
  • Loading branch information
kiollila authored and Kimmo Ollila committed Jan 18, 2017
1 parent d3eec16 commit daf2aa0
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
4 changes: 4 additions & 0 deletions config.tests/qpa/eglfs-viv/eglfs-viv.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,12 @@

int main(int, char **)
{
#if defined(__INTEGRITY)
fbGetDisplay();
#else
// Do not rely on fbGetDisplay() since the signature has changed over time.
// Stick to fbGetDisplayByIndex().
fbGetDisplayByIndex(0);
#endif
return 0;
}
5 changes: 5 additions & 0 deletions src/gui/opengl/qopenglshaderprogram.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3739,6 +3739,11 @@ QOpenGLProgramBinarySupportCheck::QOpenGLProgramBinarySupportCheck(QOpenGLContex
: QOpenGLSharedResource(context->shareGroup()),
m_supported(false)
{
// Shader cache is disabled for INTEGRITY as the driver doesn't handle
// unaligned data.
#if defined(Q_OS_INTEGRITY)
return;
#endif
if (QCoreApplication::testAttribute(Qt::AA_DisableShaderDiskCache)) {
qCDebug(DBG_SHADER_CACHE, "Shader cache disabled via app attribute");
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,11 @@ void QEglFSVivIntegration::platformInit()

#ifdef Q_OS_INTEGRITY
VivanteInit();
mNativeDisplay = fbGetDisplay();
#else
mNativeDisplay = fbGetDisplayByIndex(framebufferIndex());
#endif

mNativeDisplay = fbGetDisplayByIndex(framebufferIndex());
fbGetDisplayGeometry(mNativeDisplay, &width, &height);
mScreenSize.setHeight(height);
mScreenSize.setWidth(width);
Expand Down

0 comments on commit daf2aa0

Please sign in to comment.