OpenGL video performance
Andy Furniss
andyqos at ukfsn.org
Wed Apr 25 10:51:41 PDT 2012
Greg G. wrote:
> Hello,
>
> I've posted the following inquiry to the Phoronix forum already and was
> advised to post this to a more appropriate mailing list, such as this one.
>
> Upfront, I'm sorry if you feel I should better be posting to any of the
> mythtv lists. But I already did, and the fact of the matter is that 90%
> of the myth people are on NV hardware anyway (can't blame them, to be
> honest). So maybe this place is more appropriate.
>
> With that being said, here's my question: is there anything one can do
> to improve the real-time performance of opengl video? What would you try
> or check on my system?
>
> Background: for some time now I've repeatedly trying to get my HD3200
> equipped mythtv box to use the OpenGL renderer. While things have gotten
> *much* better in the course of the last 1.5 years, I still find that Xv
> rendering is much more "real-time", meaning that when I use a proper
> deinterlacer (hard requirement) with Xv I get smooth rendering with no
> judder at all. WithOpenGL it's pretty jerky. My test case is to play
> some piece of recording from a news channel with a horizontal scoll text
> (like stock prices), this way you see even slight hickups. Note I'm not
> even talking about h.264 output (which is, btw, also great on Xv), but
> merely SD material.
>
> I'm using Ubuntu and the fabulous oibaf drivers, and KMS. Myth is
> configured to use real-time priorities. "Top" shows that there is ample
> CPU time. Blanking method is DRM.
>
> The reason for wanting opengl output is simply that in the long run the
> mythtv devs plan on removing support for Xv. Also, the quality of the
> onscreen menu is much better with opengl.
>
> Any hints/tips/pointers appreciated!
I've never used myth so can't easily test what it's gl is like.
Some random thoughts/tests/questions in no particular order non of which
may help (maybe if you are using cpufreq try that first with myth).
If your desktop is using compositing try to disable it if you can.
Can you reproduce with mplayer, with this -
http://streams.videolan.org/samples/MPEG2/interlaced/burosch1.mpg
If you are running a 60Hz screen of course it's never going to be smooth
with this unless you force it to 30fps and double rate deinterlace.
mplayer -vf yadif=1 -vo gl -fps 30 burosch1.mpg
if you replace gl with xv add -nodouble but don't use it with gl.
On my box the gl won't be smooth unless I set my cpus to perf (and the
xv will only be nice fullscreen - but that's just a quirk of how vsync
works for xv and it doesn't affect gl).
This assumes you use cpufreq if -
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
says ondemand
then as root
echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
repeat replacing cpu0 with cpu1 etc. for how many cores you have, you
can change back with echo ondemand > .......
I don't always believe what top says when gl is involved - which doesn't
mean it's wrong for you of course.
What is your cpu and what res is the screen, are you using more than one
screen?
Does myth use vdpau if so does it allow software decode but still use
vdpau as you would gl or xv - I mean just csc and scaling rather than
full accelerated decode?
Andy.
More information about the xorg-driver-ati
mailing list