Bug 39782 - [r300g] XvMC playback fails with MPEG2 video and RV350
Summary: [r300g] XvMC playback fails with MPEG2 video and RV350
Status: RESOLVED WONTFIX
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/Gallium/r300 (show other bugs)
Version: git
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-02 16:11 UTC by Chris Rankin
Modified: 2013-11-02 22:38 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Verbose output from mplayer (112.64 KB, text/plain)
2011-08-02 16:11 UTC, Chris Rankin
Details
Verbose output from mplayer with ffmpeg12mc (491.07 KB, text/plain)
2011-08-03 02:20 UTC, Chris Rankin
Details
xvmc log obtained via RADEON_DEBUG=all (327.29 KB, text/plain)
2012-02-20 04:50 UTC, 414N
Details
xvmc log obtained via RADEON_DEBUG=fp,vp on mesa-git @ 20120423 (340.80 KB, text/plain)
2012-04-23 02:53 UTC, 414N
Details
Possible fix for too many indirections on r400 (758 bytes, patch)
2012-04-23 17:56 UTC, Tom Stellard
Details | Splinter Review
fp,vp log on patched mesa-git @20120424 on R420 hardware (340.55 KB, text/plain)
2012-04-24 03:03 UTC, 414N
Details

Description Chris Rankin 2011-08-02 16:11:41 UTC
Created attachment 49853 [details]
Verbose output from mplayer

Trying to play captured DVB-T/MPEG2 data with mplayer gives the following error:

Unsupported PixelFormat 61
Unsupported PixelFormat 53
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.

Full output from the following command is attached:
$ MPLAYER_VERBOSE=1 mplayer -msglevel all=9 -nosound -vo xvmc <file>
Comment 1 Michel Dänzer 2011-08-02 23:21:47 UTC
Does your X driver have commit f59c3b294b0f715fc96e2bbe25893f2b31aa488b ('Register XvMC video decoding acceleration') required for XvMC?
Comment 2 Chris Rankin 2011-08-03 01:17:16 UTC
(In reply to comment #1)
> Does your X driver have commit f59c3b294b0f715fc96e2bbe25893f2b31aa488b
> ('Register XvMC video decoding acceleration') required for XvMC?

Yes:

[    54.139] (II)         Solid
[    54.139] (II)         Copy
[    54.139] (II)         Composite (RENDER acceleration)
[    54.139] (II)         UploadToScreen
[    54.139] (II)         DownloadFromScreen
[    54.140] (II) RADEON(0): Acceleration enabled
[    54.140] (**) RADEON(0): DPMS enabled
[    54.140] (==) RADEON(0): Silken mouse enabled
[    54.169] (II) RADEON(0): Set up textured video
[    54.169] (II) RADEON(0): [XvMC] Associated with Radeon Textured Video.
[    54.170] (II) RADEON(0): [XvMC] Extension initialized.

The latest commit in my X driver is:

commit 104b2d7c071f29266b1bc4184a74e9714d14febc
Author: Alex Deucher <alexander.deucher@amd.com>
Date:   Mon Aug 1 10:05:30 2011 -0400

    kms: fix possible leak in pageflip code
Comment 3 Michel Dänzer 2011-08-03 01:35:09 UTC
Does adding

 -vc ffmpeg12mc

to the mplayer command line help?
Comment 4 Chris Rankin 2011-08-03 02:17:04 UTC
(In reply to comment #3)
> Does adding
> 
>  -vc ffmpeg12mc
> 
> to the mplayer command line help?

Yes, in the sense that I now get a video window. Albeit an almost completely green one. New output log attached.
Comment 5 Chris Rankin 2011-08-03 02:20:00 UTC
Created attachment 49866 [details]
Verbose output from mplayer with ffmpeg12mc

This time, mplayer displayed a video window. However, the contents were unrecognisable. And green.

I stopped playback manually after a few seconds.
Comment 6 Chris Rankin 2011-08-03 02:31:07 UTC
(In reply to comment #3)
> Does adding
> 
>  -vc ffmpeg12mc
> 
> to the mplayer command line help?

I've just tried repeating this with my RV790, and using

$ mplayer -vo xvcm <file>

also fails in the exact same way as my RV350. However, *unlike* my RV350, adding

  -vc ffmpeg12mc

makes playback work with my RV790.

Since mplayer's XvMC support is obviously working correctly, I am now assuming the problems I am seeing with xine are due to bugs in xine itself.
Comment 7 Chris Rankin 2011-08-11 06:28:20 UTC
Also gives green and blobby playback with M66GL chip (RV535?) in my Lenovo T60p.
Comment 8 almos 2011-10-15 11:41:37 UTC
I think this is a duplicate of my report in bug 39309. I haven't tried xvmc yet, as vdpau is much easier to set up (and I'm lazy).
Comment 9 Chris Rankin 2012-01-04 15:35:06 UTC
The following commit does not resolve this bug:

commit 7b181d16c3b954bf567563e90e5e94bda833fab8
Author: Christian König <deathsimple@vodafone.de>
Date:   Wed Jan 4 15:59:29 2012 +0100

    vl/mpeg2: simple fix to get xine running again
    
    Otherwise xines xxmc plugin will just display green blocks.
    
    Signed-off-by: Christian König <deathsimple@vodafone.de>

xine is still showing a green video window with my RV350.

$ mplayer -vo xvmc -vc ffmpeg12mc <MPEG2 file>

isn't working here either.
Comment 10 414N 2012-02-20 04:50:04 UTC
Created attachment 57314 [details]
xvmc log obtained via RADEON_DEBUG=all

Having a similar problem on a R420.
When using mplayer -vo xvmc to play an MPEG-2 file (recorded from DVB) I can only see a window filled with a majority of green squares flashing.
On stderr, the following message is shown:

r300 FP: Compiler Error:
compiler/r300_fragprog_emit.c::begin_tex(): Too many texture indirections
Using a dummy shader instead.

I then played the same video setting the RADEON_DEBUG environment variable to "all", because I don't know what can be excluded. I then cut the lines following the error message from the log, assuming those where the lines regarding the dummy shader used as a failsafe by the r300 driver.
I'm using a self-compiled git snapshot of mesa obtained on 2012-02-15 on a Slackware64 13.37 running kernel 3.2.6.
Please tell me if more info are needed.
Comment 11 Tom Stellard 2012-04-22 18:10:00 UTC
(In reply to comment #10)
> Created attachment 57314 [details]
> xvmc log obtained via RADEON_DEBUG=all
> 
> Having a similar problem on a R420.
> When using mplayer -vo xvmc to play an MPEG-2 file (recorded from DVB) I can
> only see a window filled with a majority of green squares flashing.
> On stderr, the following message is shown:
> 
> r300 FP: Compiler Error:
> compiler/r300_fragprog_emit.c::begin_tex(): Too many texture indirections
> Using a dummy shader instead.
> 

Can you try the latest version of mesa from git?  I don't think xvmc playback works, but that error message should be fixed.  If you still see that error, please use the environment variable RADEON_DEBUG=fp,vp and post the output.
Comment 12 414N 2012-04-23 02:53:34 UTC
Created attachment 60474 [details]
xvmc log obtained via RADEON_DEBUG=fp,vp on mesa-git @ 20120423

(In reply to comment #11)
> Can you try the latest version of mesa from git?  I don't think xvmc playback
> works, but that error message should be fixed.  If you still see that error,
> please use the environment variable RADEON_DEBUG=fp,vp and post the output.

Still getting the same error message on a git snapshot taken a few hours ago. In the attached log I cut the text after that error message as in the first one.
Do you need more info to narrow down the issue?
Comment 13 Tom Stellard 2012-04-23 17:56:54 UTC
Created attachment 60501 [details] [review]
Possible fix for too many indirections on r400

Do you still see the error message with this patch?
Comment 14 414N 2012-04-24 03:03:58 UTC
Created attachment 60517 [details]
fp,vp log on patched mesa-git @20120424 on R420 hardware

(In reply to comment #13)
> Created attachment 60501 [details] [review] [review]
> Possible fix for too many indirections on r400
> 
> Do you still see the error message with this patch?

I now see an additional "too many textures indirections" error message while playing a file in mplayer with -vo xvmc, so I guess it's not working as expected.
Attached is an updated fp,vp log.
Comment 15 414N 2012-08-05 07:50:38 UTC
Still no clue of what could be going awry?
This is still happening on recent git checkouts, regardless of the previous patch.
Please do tell me if you need more information to narrow down the issue.
Comment 16 Marek Olšák 2013-11-02 22:38:46 UTC
XvMC support has been removed.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.