[mythtv-commits] Ticket #12311: tearing on full-screen video playback when 2D glamor accell is enabled

MythTV noreply at mythtv.org
Wed Oct 29 21:19:40 UTC 2014


#12311: tearing on full-screen video playback when 2D glamor accell is enabled
-----------------------------------------+----------------------------
     Reporter:  warpme@…                 |      Owner:  jyavenard
         Type:  Bug Report - General     |     Status:  new
     Priority:  minor                    |  Milestone:  unknown
    Component:  MythTV - Video Playback  |    Version:  Master Head
     Severity:  medium                   |   Keywords:  tearing glamor
Ticket locked:  0                        |
-----------------------------------------+----------------------------
 Tear-free 2D glamor accell (used by default by all radeonsi and also
 recommended for intel) with current xorg server requires alignment between
 X11 root window size/position and application window (myth).
 If both root window and app window have equal size&position - graphic
 stack can turn-off glamor and use DRI based vsync for frame page flipping.
 This can give tearing free video playback without expensive video frame
 copies.
 On current master with: 'separate video modes' disabled; "Use GUI size for
 TV playback" and "Use fixed window size" enabled, I can't achieve tear-
 free playabck, because X11 root window and Myth window are not aligned:

 root window:

 {{{
 xrandr
 Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 16384 x 16384
 HDMI-0 connected 1920x1080+0+0 (normal left inverted right x axis y axis)
 820mm x 460mm
    1920x1080      50.0*+   60.0     50.0     59.9     24.0     24.0
    1920x1080i     60.1     50.0     60.0
    1600x1200      60.0
    1400x1050      59.9
    1280x1024      60.0
    1360x768       60.0
    1280x720       60.0     50.0     59.9
    1440x576i      50.1
    1024x768       75.1     70.1     60.0
    1440x480i      60.1     60.1
    800x600        72.2     75.0     60.3     56.2
    720x576        50.0
    720x480        60.0     59.9
    640x480        75.0     72.8     60.0     59.9
    720x400        70.1
 DVI-0 disconnected (normal left inverted right x axis y axis)
 VGA-0 disconnected (normal left inverted right x axis y axis)

 }}}


 mythtv window: gui

 {{{
 xwininfo: Window id: 0x1600050 "MythTV Frontend"

   Absolute upper-left X:  0
   Absolute upper-left Y:  0
   Relative upper-left X:  0
   Relative upper-left Y:  0
   Width: 1920
   Height: 1080
   Depth: 24
   Visual: 0x21
   Visual Class: TrueColor
   Border width: 1
   Class: InputOutput
   Colormap: 0x20 (installed)
   Bit Gravity State: NorthWestGravity
   Window Gravity State: NorthWestGravity
   Backing Store State: NotUseful
   Save Under State: no
   Map State: IsViewable
   Override Redirect State: no
   Corners:  +0+0  --2+0  --2--2  +0--2
   -geometry 1920x1080+0+0
 }}}


 myth window: video playback


 {{{
 xwininfo: Window id: 0x1600050 "MythTV Frontend"

   Absolute upper-left X:  -1
   Absolute upper-left Y:  -1
   Relative upper-left X:  -1
   Relative upper-left Y:  -1
   Width: 1920
   Height: 1080
   Depth: 24
   Visual: 0x21
   Visual Class: TrueColor
   Border width: 1
   Class: InputOutput
   Colormap: 0x20 (installed)
   Bit Gravity State: NorthWestGravity
   Window Gravity State: NorthWestGravity
   Backing Store State: NotUseful
   Save Under State: no
   Map State: IsViewable
   Override Redirect State: no
   Corners:  +-1+-1  --1+-1  --1--1  +-1--1
   -geometry 1920x1080+-1+-1
 }}}



 Missaligment causing tearing. xorg log shows:

 {{{
 [1561601.461] (--) RADEON(0): HDMI max TMDS frequency 170000KHz
 [1561609.906] DRI2CanFlip: Window clipList doesn\'t match root window
 dimensions:
 [1561609.906] Window clipList extents: (1, 1)-(1920, 1080)
 [1561609.906] Root window extents: (0, 0)-(1920, 1080)
 [1561609.906] Can\'t flip because DRI2CanFlip failed
 [1561609.941] DRI2CanFlip: Window clipList doesn\'t match root window
 dimensions:
 [1561609.941] Window clipList extents: (1, 1)-(1920, 1080)
 [1561609.941] Root window extents: (0, 0)-(1920, 1080)
 [1561609.941] Can\'t flip because DRI2CanFlip failed
 [1561611.345] DRI2CanFlip: Window clipList doesn\'t match root window
 dimensions:
 }}}


 It is also interesting that after any video playback, GUI & video starts
 to have thesame pos/size (but still missaligned to X11 root window):


 {{{
 xwininfo: Window id: 0x1600050 "MythTV Frontend"

   Absolute upper-left X:  -1
   Absolute upper-left Y:  -1
   Relative upper-left X:  -1
   Relative upper-left Y:  -1
   Width: 1920
   Height: 1080
   Depth: 24
   Visual: 0x21
   Visual Class: TrueColor
   Border width: 1
   Class: InputOutput
   Colormap: 0x20 (installed)
   Bit Gravity State: NorthWestGravity
   Window Gravity State: NorthWestGravity
   Backing Store State: NotUseful
   Save Under State: no
   Map State: IsViewable
   Override Redirect State: no
   Corners:  +-1+-1  --1+-1  --1--1  +-1--1
   -geometry 1920x1080+-1+-1
 }}}



 Another, parralel issue is when 'separate video modes' option is enabled:
 In such case playback start to have also cropped height.

 mythtv window: GUI

 {{{
 xwininfo: Window id: 0x16000e3 "MythTV Frontend"

   Absolute upper-left X:  0
   Absolute upper-left Y:  0
   Relative upper-left X:  0
   Relative upper-left Y:  0
   Width: 1920
   Height: 1080
   Depth: 24
   Visual: 0x21
   Visual Class: TrueColor
   Border width: 1
   Class: InputOutput
   Colormap: 0x20 (installed)
   Bit Gravity State: NorthWestGravity
   Window Gravity State: NorthWestGravity
   Backing Store State: NotUseful
   Save Under State: no
   Map State: IsViewable
   Override Redirect State: no
   Corners:  +0+0  --2+0  --2--2  +0--2
   -geometry 1920x1080+0+0
 }}}



 mythtv window: video playback:

 {{{
 xwininfo: Window id: 0x16000e3 "MythTV Frontend"

   Absolute upper-left X:  -1
   Absolute upper-left Y:  -1
   Relative upper-left X:  -1
   Relative upper-left Y:  -1
   Width: 1920
   Height: 1078
   Depth: 24
   Visual: 0x21
   Visual Class: TrueColor
   Border width: 1
   Class: InputOutput
   Colormap: 0x20 (installed)
   Bit Gravity State: NorthWestGravity
   Window Gravity State: NorthWestGravity
   Backing Store State: NotUseful
   Save Under State: no
   Map State: IsViewable
   Override Redirect State: no
   Corners:  +-1+-1  --1+-1  --1-1  +-1-1
   -geometry 1920x1078+-1+-1
 }}}

--
Ticket URL: <https://code.mythtv.org/trac/ticket/12311>
MythTV <http://www.mythtv.org>
MythTV Media Center


More information about the mythtv-commits mailing list