Opened 5 years ago

Closed 5 years ago

Last modified 2 years ago

#12421 closed Bug Report - General (Fixed)

When using vaapi decoding, video fails with "QOpenGLContext::swapBuffers() called with non-exposed window, behavior is undefined"

Reported by: Stuart Auchterlonie Owned by: Jonatan Lindblad
Priority: blocker Milestone: 0.28
Component: Qt5 issues Version: Master Head
Severity: high Keywords: vaapi
Cc: Ticket locked: no

Description

When using vaapi playback, no video is shown, just the error "QOpenGLContext::swapBuffers() called with non-exposed window, behavior is undefined" is thrown.

Switching to the opengl normal playback profile allows recordings to be watched

Attachments (1)

frontend2.log (21.1 KB) - added by Stuart Auchterlonie 5 years ago.

Download all attachments as: .zip

Change History (16)

Changed 5 years ago by Stuart Auchterlonie

Attachment: frontend2.log added

comment:1 Changed 5 years ago by Stuart Auchterlonie

Owner: set to Jonatan Lindblad
Status: newassigned

comment:2 Changed 5 years ago by Stuart Auchterlonie

Jonatan,

The devel/vaapifix branch works for all the content I have available

  • h264 / ac3 (uses H264High profile)
  • mpeg2video / MP2 (uses MPEG2Main profile) + dvb subtitles

Regards Stuart

Last edited 5 years ago by Stuart Auchterlonie (previous) (diff)

comment:3 Changed 5 years ago by Stuart Auchterlonie

comment:4 Changed 5 years ago by Stuart Auchterlonie

Only newer libva releases define "VAProfileH264StereoHigh"

https://code.mythtv.org/cgit/mythtv/commit/?id=c608732c328fe1ce95aadff771760f119e7d5771

comment:5 Changed 5 years ago by Stuart Auchterlonie

Merged to master :)

comment:6 Changed 5 years ago by Jonatan Lindblad

Resolution: Fixed
Status: assignedclosed

comment:7 Changed 5 years ago by Stuart Auchterlonie

comment:8 Changed 5 years ago by Jonatan Lindblad <jlindblad@…>

In cd9762c6acaa1fa26f4c5e29f2bc83d4e7e2353e/mythtv:

Video output: Add default fragment shader for OpenGL 2

When there were no color conversions with the YUV->RGB shader, there was no
other fragment shader active and because of that the video was black.

(cherry picked from commit b997114683759562dbaf6b80a651070d099195ac)

Refs #12421

comment:9 Changed 5 years ago by Jonatan Lindblad <jlindblad@…>

In 9ac80fbb52a5c8022d5cb4374cf6b455785a3990/mythtv:

Video output: Fix OpenGL 1 output after b9971146

(cherry picked from commit 2b01ed3894be8374b6c143449fa563fbd945da5a)

Refs #12421

comment:10 Changed 5 years ago by Jonatan Lindblad <jlindblad@…>

In a848edd7a4450db1c0eb839cc41ebdd6c6b2dbb6/mythtv:

Video output: Add default fragment shader for OpenGL 2

When there were no color conversions with the YUV->RGB shader, there was no
other fragment shader active and because of that the video was black.

(cherry picked from commit b997114683759562dbaf6b80a651070d099195ac)
Signed-off-by: Stuart Auchterlonie <stuarta@…>

Refs #12421

comment:11 Changed 5 years ago by Jonatan Lindblad <jlindblad@…>

In 8b6d4da2a185e7b07c432267dc9fb80075f9565c/mythtv:

Video output: Fix OpenGL 1 output after b9971146

(cherry picked from commit 2b01ed3894be8374b6c143449fa563fbd945da5a)
Signed-off-by: Stuart Auchterlonie <stuarta@…>

Refs #12421

comment:12 Changed 4 years ago by Hamish Moffatt <hamish@…>

I've just installed the 0.28 release (code revision b4e03c8, from Mythbuntu package 2:0.28.0+fixes.20160418.b4e03c8-0ubuntu0mythbuntu4), and I'm getting this exact problem whenever I use the OpenGL, OpenGL High Quality, or VAAPI profiles.

It's working with the standard or high resolution (non-OpenGL) profiles although those seem to have other issues of their own.

comment:13 in reply to:  12 Changed 4 years ago by Hamish Moffatt <hamish@…>

Replying to Hamish Moffatt <hamish@…>:

I've just installed the 0.28 release (code revision b4e03c8, from Mythbuntu package 2:0.28.0+fixes.20160418.b4e03c8-0ubuntu0mythbuntu4), and I'm getting this exact problem whenever I use the OpenGL, OpenGL High Quality, or VAAPI profiles.

It's working with the standard or high resolution (non-OpenGL) profiles although those seem to have other issues of their own.

My main MythTV mode was set to Qt instead of auto/OpenGL. Changing it to auto fixed this problem for me.

comment:14 Changed 2 years ago by Oliver.Freyd@…

I had the exact same problem, playback would crash immediately if OpenGL or VAAPI profile was set, only Normal would work. Only after finding that "Qt" main mode instead of "Auto" was incompatible with "OpenGL" playback mode I could fix the problem.

Why not disable the selection of these playback modes, or give a hint that you need "Auto" main mode in order to use OpenGL or VAAPI playback?!

Would be more user-friendly...

comment:15 Changed 2 years ago by Peter Bennett

This was done 6 months ago, and the fix is in version 29. See e9daa4e for details

Note: See TracTickets for help on using tickets.