Opened 10 years ago

Closed 9 years ago

#6947 closed defect (worksforme)

xinerama now plays squashed recordings since 21135

Reported by: anonymous Owned by: markk
Priority: minor Milestone: 0.24
Component: MythTV - Video Playback Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

I have a xinerama setup with a 1440x900 lcd monitor, and a 720x576 4:3 tv, the lcd being display 0, tv being display 1. If I'm just watching tv, I'll watch it on the monitor, otherwise we'll all watch on the tv.

I've just updated to the latest trunk (last time being a few weeks ago) and I've noticed that my old recordings appear horizontally squashed on the monitor. My tv's currently not available so I'm not able to check on that.

Debug shows:

2009-08-30 03:52:36.812 Display Rect left: 0, top: 112, width: 1440, height: 675, aspect: 1.33333 2009-08-30 03:52:36.812 Video Rect left: 0, top: 0, width: 720, height: 576, aspect: 1.77778 2009-08-30 03:52:36.812 VDP: LoadBestPreferences?(720x576, 60) 2009-08-30 03:52:36.812 Display Rect left: 0, top: 112, width: 1440, height: 675, aspect: 1.33333 2009-08-30 03:52:36.812 Video Rect left: 0, top: 0, width: 720, height: 576, aspect: 1.77778 2009-08-30 03:52:36.813 VideoOutput?: Pixel dimensions: Screen 1440x900, window 1440x900 2009-08-30 03:52:36.813 VideoOutput?: Actual display dimensions: 616x263 mm Aspect: 2.34221 2009-08-30 03:52:36.813 VideoOutput?: Estimated window dimensions: 616x263 mm Aspect: 2.34221 2009-08-30 03:52:36.813 VideoOutputXv?: InitSetupBuffers?() render: xv-blit, allowed: xv-blit,xshm,xlib 2009-08-30 03:52:36.816 VDP: Accepting: cmp(> 720 576) dec(vdpau) cpus(2) rend(vdpau) osd(vdpau) osdfade(enabled) deint(vdpauadvanced,none) filt()

However backing out change 21135 (and a couple of others to resolve conflicts) my recordings look fine.

Attachments (3)

squashed-playback (19.3 KB) - added by anonymous 10 years ago.
mythfrontend -v playback,extra with squashed output
xorg.conf (2.0 KB) - added by anonymous 10 years ago.
normal-playback (21.6 KB) - added by anonymous 10 years ago.
mythfrontend -v playback,extra with normal output

Download all attachments as: .zip

Change History (16)

comment:1 Changed 10 years ago by markk

Owner: changed from Janne Grunau to markk
Status: newaccepted

Can you please attach the full output of mythfrontend -v playback (i.e. from startup).

thanks.

comment:2 Changed 10 years ago by anonymous

It turns out that I'd managed to disable xinerama somehow just before pulling out change 21135 hence it worked, and it's just as broken with that change taken out.

comment:3 Changed 10 years ago by markk

Status: acceptedinfoneeded

Can you please attach a new log with the latest trunk version and with Xinerama enabled. thanks

comment:4 Changed 10 years ago by anonymous

New log file with the latest trunk version (still squashed)

comment:5 Changed 10 years ago by markk

Finally found some time to dig into this.

Firstly, while testing I've noticed some strange behaviour when using nvidia-settings to change the screen setup. When switching between xinerama/twinview setups, the screen dimensions are often not reset until X is restarted. As a result the screen dimensions can be wildly inaccurate and I have reproduced the squashed video effect you've described.

  • can you please confirm exactly how you're setting up xinerama. from your description it sounds as if you may be adjusting dynamically. if so, can you try restarting X and seeing if that fixes it (you may need to run sudo nvidia-settings).

Secondly, there appear to be some issues with how Qt deals with multi-screen setups. I don't know if this is new to Qt4.5 but under certain setups it gets it all wrong.

  • can you please attach an updated log of 'mythfrontend -v playback,extra'. That extra debug will give some additional xinerama detail when mythfrontend is started.

thnks, Mark

Changed 10 years ago by anonymous

Attachment: squashed-playback added

mythfrontend -v playback,extra with squashed output

Changed 10 years ago by anonymous

Attachment: xorg.conf added

Changed 10 years ago by anonymous

Attachment: normal-playback added

mythfrontend -v playback,extra with normal output

comment:6 Changed 10 years ago by anonymous

I have noticed something interesting, now that I have my tv back and plugged in.

With the tv disconnected (and no s-video cable plugged in) the video playback appears squashed. With the tv plugged in (and s-video cable plugged in) the video playback on the monitor looks normal!

Incidentally on both occasions "mplayer -vo vdpau" looks fine.

BTW, I've also attached my /etc/X11/xorg.conf file.

comment:7 Changed 10 years ago by markk

Thanks for the update.

You didn't say whether you're restarting X after connecting/disconnecting the tv, which is probably the crucial detail.

I'll try and recreate again here, but based on those logs, mythfrontend is behaving as I would expect.

When it's working normally, it is told by X that there are 2 screens, adjusts the aspect ratio of that screen to 16:10 (per the frontend setting) and everything is good. When the playback is squashed, it's told there is only one screen available, hence does not try and override the aspect ratio and is told by X that the screen has some interesting dimensions (VideoOutput?: Actual display dimensions: 616x263 mm Aspect: 2.34221). As a result you get the squashed video.

comment:8 Changed 10 years ago by anonymous

Between taking the s-video cable out I'm powering down the computer... so yes, it's also restarting the X-server :-)

comment:9 Changed 10 years ago by markk

Milestone: 0.220.23
Status: infoneededassigned

I can't honestly decide whether this is a driver bug or not:)

I can reproduce the issue here. It seems to be a specific problem (maybe restricted to nvidia) when the primary display has the smaller resolution and it is the primary display that is unavailable. In that situation, the driver reports an incorrect display size for the remaining, active display. As I mentioned previously, I believe mythfrontend is making the correct decisions and calculations on the basis of the information available to it.

That said, both Qt and X report maximum screen sizes/resolutions consistent with both displays being available. While this may provide the necessary information to adjust the aspect ratio correctly, it seems counter intuitive to me that either should be reporting total resolutions that aren't available - that second screen simply isn't plugged in. Regardless, I'm not going to start tinkering with that code so close to 0.22 release, hence pushing back to 0.23 so I can have a more detailed look when time permits. There is still every likelihood that I won't change the code to try and fix what is, at the end of the day, an edge case.

In the meantime, there are 2 possible workarounds:-

  • try swapping the displays around, so that the tv is the second display. This fixed it for me.
  • override the display size settings when running on the lcd tv using 'mythfrontend -O DisplaySizeWidth?=421 -O DisplaySizeHeight?=263'.

comment:10 Changed 10 years ago by markk

Status: assignedaccepted

comment:11 Changed 10 years ago by anonymous

Oh, thanks for that! I had forgotten I'd made the tv the primary display (in an effort to eliminate tearing... which didn't make much difference at the time). I'll swap them around.

comment:12 Changed 10 years ago by markk

Milestone: 0.230.24

I've not found the time to check this again so pushing back to 0.24.

comment:13 Changed 9 years ago by markk

Resolution: worksforme
Status: acceptedclosed

I can no longer reproduce this issue.

Note: See TracTickets for help on using tickets.