xv is not working on intel when using compiz

Bug #201596 reported by sibidiba
6
Affects Status Importance Assigned to Milestone
xf86-video-intel
Invalid
Medium
xserver-xorg-video-intel (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: xserver-xorg-video-intel

Running Hardy, using xserver-xorg-video-intel version 2:2.2.1-1ubuntu4 , xvideo output is not available when enabling compiz.

Video controller:
lspci
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
lspci -nvvvv
00:02.0 0300: 8086:2a02 (rev 0c) (prog-if 00 [VGA controller])
        Subsystem: 17aa:20b5
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Latency: 0
        Interrupt: pin A routed to IRQ 20
        Region 0: Memory at f8100000 (64-bit, non-prefetchable) [size=1M]
        Region 2: Memory at e0000000 (64-bit, prefetchable) [size=256M]
        Region 4: I/O ports at 1800 [size=8]
        Capabilities: [90] Message Signalled Interrupts: Mask- 64bit- Queue=0/0 Enable-
                Address: 00000000 Data: 0000
        Capabilities: [d0] Power Management version 3
                Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 PME-Enable- DSel=0 DScale=0 PME-
                Bridge: PM- B3+

With the latest update for the driver hardware overlay was introduced and texture video disabled, but brought no change on this.

Using XAA, the video does not show up, instead an error message appears on the console:

X11 error: BadAlloc (insufficient resources for operation)

Using the default EXA acceleration, the video playback starts, but is balls-achingly slow.

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hm, I'm not convinced since I have the same chip and everything is fine with EXA. If you want to use XAA then you need to set the option TexturedVideo true.

attach your xorg.conf and Xorg.0.log when using EXA.

Changed in xserver-xorg-video-intel:
status: New → Incomplete
Revision history for this message
Chris Jones (cmsj) wrote :

I am unable to reproduce this.

00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller [8086:2a02] (rev 0c) (prog-if 00 [VGA controller])
        Subsystem: Lenovo Unknown device [17aa:20b5]
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Latency: 0
        Interrupt: pin A routed to IRQ 20
        Region 0: Memory at fa000000 (64-bit, non-prefetchable) [size=1M]
        Region 2: Memory at e0000000 (64-bit, prefetchable) [size=256M]
        Region 4: I/O ports at 1800 [size=8]
        Capabilities: [90] Message Signalled Interrupts: Mask- 64bit- Queue=0/0 Enable-
                Address: 00000000 Data: 0000
        Capabilities: [d0] Power Management version 3
                Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 PME-Enable- DSel=0 DScale=0 PME-
                Bridge: PM- B3+

Revision history for this message
sibidiba (sibidiba) wrote :

Hmm.. That sounds interesting. AFAIK this is a well known deficiency of the intel driver: http://www.phoronix.com/forums/showthread.php?t=6006 .

Do you use Xgl as suggested in this thread (http://ubuntuforums.org/showthread.php?t=707473) ?
I use plain X, as suggested for Hardy.
I do not have any preferences for the acceleration method.

Everything else works fine, only Xv is unusable (both with XAA and EXA), but only if compiz is enabled.
Are you sure, you use the xv output in your player (not X11, nor gl, nor any compiz video output plugin)?

Please also try it with a HD or a high resolution video. Low resolution videos may just be laggy and cause high CPU load.

If it is still working for you, could you please attach your xorg.conf?

xorg.conf follows, Xorg.0.log attached:

Section "InputDevice"
 Identifier "Generic Keyboard"
 Driver "kbd"
 Option "XkbRules" "xorg"
 Option "XkbModel" "pc105"
 Option "XkbLayout" "hu"
 Option "XkbVariant" "102_qwertz_dot_nodead"
 Option "XkbOptions" "lv3:ralt_switch"
EndSection

Section "InputDevice"
 Identifier "Configured Mouse"
 Driver "mouse"
EndSection

Section "Device"
 Identifier "Configured Video Device"
EndSection

Section "Monitor"
 Identifier "Configured Monitor"
EndSection

Section "Screen"
 Identifier "Default Screen"
 Monitor "Configured Monitor"
 DefaultDepth 24
 SubSection "Display"
  Depth 24
  Virtual 2048 2048
 EndSubSection
EndSection

Section "InputDevice"
 Identifier "Synaptics Touchpad"
 Driver "synaptics"
 Option "SHMConfig" "on"
 Option "HorizEdgeScroll" "0"
EndSection

Section "ServerLayout"
 Identifier "Default Layout"
 Screen "Default Screen"
 InputDevice "Generic Keyboard"
 InputDevice "Synaptics Touchpad"
EndSection

Section "ServerFlags"
    Option "AllowNonLocalModInDev"
    Option "AllowMouseOpenFail" "true"
    Option "AllowDeactivateGrabs" "true"
    Option "AllowCloseDownGrabs" "true"
EndSection

Revision history for this message
Chris Jones (cmsj) wrote :

Hmm yes, playing something HD (720p) is slow with Xv and compiz. It returns to normal speed either by disabling compiz or using a simple X shm video output driver.

Revision history for this message
sibidiba (sibidiba) wrote :

I tried (as suggested) to use xserver-xgl, but brought no change on the issue.

I'm using an external monitor (with 1680x1050 resolution). Putting even a low resolution video to full-screen results in a playback with approx. 0.5 FPS.

If compiz is disabled Xv playback is (as it should) smooth and flawless.

Changed in xserver-xorg-video-intel:
status: Incomplete → Confirmed
Revision history for this message
In , Sibidiba-gmail (sibidiba-gmail) wrote :
Download full text (3.3 KiB)

Running Ubuntu Hardy (with kernel 2.6.24-11-generic), using xserver-xorg-video-intel version 2:2.2.1-1ubuntu4 , xvideo output is not available when enabling compiz.

Video controller:
lspci
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
lspci -nvvvv
00:02.0 0300: 8086:2a02 (rev 0c) (prog-if 00 [VGA controller])
        Subsystem: 17aa:20b5
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Latency: 0
        Interrupt: pin A routed to IRQ 20
        Region 0: Memory at f8100000 (64-bit, non-prefetchable) [size=1M]
        Region 2: Memory at e0000000 (64-bit, prefetchable) [size=256M]
        Region 4: I/O ports at 1800 [size=8]
        Capabilities: [90] Message Signalled Interrupts: Mask- 64bit- Queue=0/0 Enable-
                Address: 00000000 Data: 0000
        Capabilities: [d0] Power Management version 3
                Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 PME-Enable- DSel=0 DScale=0 PME-
                Bridge: PM- B3+

With the latest update for the driver hardware overlay was introduced and texture video disabled, but brought no change on this.

Using XAA, the video does not show up, instead an error message appears on the console:

X11 error: BadAlloc (insufficient resources for operation)

Using the default EXA acceleration, the video playback starts, but is balls-achingly slow.

Using a low resolution video you may not notice this bug at first on a laptop panel, it will be just laggy and cause a high CPU load.
I'm using an external monitor (with 1680x1050 resolution). Putting even a low resolution video to full-screen results in a playback with approx. 0.5 FPS.

I tried (as suggested here: http://ubuntuforums.org/showthread.php?t=707473) to use xserver-xgl, but brought no change on the issue.

Section "InputDevice"
 Identifier "Generic Keyboard"
 Driver "kbd"
 Option "XkbRules" "xorg"
 Option "XkbModel" "pc105"
 Option "XkbLayout" "hu"
 Option "XkbVariant" "102_qwertz_dot_nodead"
 Option "XkbOptions" "lv3:ralt_switch"
EndSection

Section "InputDevice"
 Identifier "Configured Mouse"
 Driver "mouse"
EndSection

Section "Device"
 Identifier "Configured Video Device"
EndSection

Section "Monitor"
 Identifier "Configured Monitor"
EndSection

Section "Screen"
 Identifier "Default Screen"
 Monitor "Configured Monitor"
 DefaultDepth 24
 SubSection "Display"
  Depth 24
  Virtual 2048 2048
 EndSubSection
EndSection

Section "InputDevice"
 Identifier "Synaptics Touchpad"
 Driver "synaptics"
 Option "SHMConfig" "on"
 Option "HorizEdgeScroll" "0"
EndSection

Section "ServerLayout"
 Identifier "Default Layout"
 Screen "Default Screen"
 InputDevice "Generic Keyboard"
 InputDevice "Synaptics Touchpad"
EndSection

Section "ServerFlags"
    Option "AllowNonLocalModInDev"
    Option "AllowMouseOpenFail" "true"
    Option "AllowDeactivateGrabs" "true"
    Option "AllowCloseDownGrabs" "true"
EndSection

Everything else works fine, only Xv is unusable (both with XA...

Read more...

Revision history for this message
In , Sibidiba-gmail (sibidiba-gmail) wrote :

Created an attachment (id=15087)
Xorg.0.log

Revision history for this message
Francois Rigaut (francois.rigaut) wrote : Re: xv is not working on intel 965 (x3100) when using compiz

+1
I experience the same thing on a 945, with compiz, using EXA and MigrationHeuristic greedy. xv used to work with these settings some days ago. Now, same as you: it starts but uses 100%cpu and it is super slow. More system info available upon request.

Revision history for this message
In , Sibidiba-gmail (sibidiba-gmail) wrote :

According to the changelog, in the latest xserver-xorg-video-intel patches were added to enable hardware overlay for i965, and textured video was disabled by default.

But the solution was to set 'Option "TexturedVideo" "false"'.

TexturedVideo is not disabled (to enable HardwareOverlay) by default. Using (the now still default texturedvideo) the bug remains.

Revision history for this message
unggnu (unggnu) wrote : Re: xv is not working on intel 965 (x3100) when using compiz

I can confirm it partly. Overlay for video output isn't used anymore in current Hardy with my i915 chipset since compiz widgets like sound increase show parts of the video under transparency and the compiz effect shift + alt + cursor up show the video in the reduced window.
Video output seems to be slower but it seems to work in full screen at least for standard videos after a short test. It lags very much if Totem shows the progress bar or the right mouse button is pressed.
The other point is that I am afraid that Bug #129025 appears again. I currently couldn't test it with this external monitor.

Revision history for this message
sibidiba (sibidiba) wrote :

@unggnu: What do you mean by "Overlay for video output isn't used anymore in current Hardy"?

I guess your video is not played via xv, but via X11/shm. Please try mplayer -vo xv file.avi . Video rendering should go trough xv. All other video output methods consume either too much CPU (X11/shm) or could interference with other applications (gl output breaks games, compiz).

Although I agree with you, that actually, using the intel driver, video playback is smooth with x11 output compared to xv with compiz enabled.

Revision history for this message
unggnu (unggnu) wrote :

I am using xv. ([00000341] main video output debug: using video output module "xvideo")
http://en.wikipedia.org/wiki/Hardware_overlay

Revision history for this message
unggnu (unggnu) wrote :

Btw. I am pretty sure that your report is a duplicate of Bug #152206 which should be fixed through activating Overlay which obviously doesn't work for you.

Revision history for this message
sibidiba (sibidiba) wrote :

This is not a duplicate. Bug #152206 is about general video tearing and poor performance. That bug is more a duplicate of #177492 , which was solved by forcing MigrationHeurisitc "greedy" for all chipsets and setting the env. variable INTEL_BATCH=1 .

I had only problems with xv video playback, but if and only compiz was enabled.

Now I played with the options in xorg.conf, and got it working! :)

According to the changelog, in the latest xserver-xorg-video-intel (2:2.2.1-1ubuntu4) patches were added to enable hardware overlay for i965, and textured video was disabled by default.

But the solution was to set 'Option "TexturedVideo" "false"'.

So using the current intel driver (with default accel method EXA and greedy migration heuristic), xv works with compiz.
But TexturedVideo is not disabled (to enable HardwareOverlay) by default. Using (the now still default texturedvideo) the bug remains.

Revision history for this message
In , Timo Aaltonen (tjaalton) wrote :

This bug is about the overlay patch in the Ubuntu package, so there's no point in reporting it here.

Revision history for this message
In , Sibidiba-gmail (sibidiba-gmail) wrote :

You are right, I thought hardware overlay was introduced upstream.

Although it would be great to have the now working hardware overlay available and set by default, because texture overlay (the current overlay method for 965) contains the reported bug.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package xserver-xorg-video-intel - 2:2.2.1-1ubuntu5

---------------
xserver-xorg-video-intel (2:2.2.1-1ubuntu5) hardy; urgency=low

  * Fix the overlay patch to really disable TexturedVideo by default.
    (LP: #201596)

 -- Timo Aaltonen <email address hidden> Fri, 14 Mar 2008 11:01:09 +0200

Changed in xserver-xorg-video-intel:
status: Confirmed → Fix Released
Revision history for this message
unggnu (unggnu) wrote :

@Timo Aaltonen
Does your Patch only disable TexturedVideo for i965 or all other cards? It seems that TexturedVideo is enabled for i915 too and most likely for several other ones. The workaround with the xorg.conf device option works for me too.
TexturedVideo works but it is still very slow and I guess more worse on bigger screens.

Changed in xserver-xorg-video-intel:
status: Unknown → Invalid
Revision history for this message
unggnu (unggnu) wrote :

I am using the 2:2.2.1-1ubuntu6 Intel driver and Overlay seems to be used per default again.

Changed in xserver-xorg-video-intel:
importance: Unknown → Medium
Changed in xserver-xorg-video-intel:
importance: Medium → Unknown
Changed in xserver-xorg-video-intel:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.