nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   NVIDIA Linux (http://www.nvnews.net/vbulletin/forumdisplay.php?f=14)
-   -   mplayer OSD rendering using 100% CPU with VDPAU (http://www.nvnews.net/vbulletin/showthread.php?t=159662)

yxing 02-14-11 03:01 PM

mplayer OSD rendering using 100% CPU with VDPAU
 
2 Attachment(s)
I'm using the SVN version of mplayer (4.4.3) to play an H.264 TS file with VDPAU acceleration. The playback is flawless, but whenever mplayer renders the OSD, my CPU usage goes up to 100%.

I noticed it was the
Code:

VdpOutputSurfacePutBitsIndexed
call that causes the spike in CPU usage. It seems that mplayer uses that function to draw the OSD each frame, but also calls
Code:

VdpOutputSurfacePutBitsNative
each frame to draw the actual video image without causing any spikes in CPU usage.

The output log of mplayer and nvidia-bug-report.sh are attached. I will upload the TS when I figure out how to get on your FTP site, but I'm not sure it's critical because it's the OSD drawing that seems to be the problem.

Licaon 02-15-11 06:49 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
see this too: http://www.nvnews.net/vbulletin/showthread.php?t=157915

also, does this happen only after you suspend/wake ?

Stephen Warren 02-15-11 11:08 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Licaon, I'm not sure how that other thread is related to this one.

yxing, How did you isolate which call causes the CPU usage. For how long does the CPU usage last; there is some tiny amount of polling in that function, but it shouldn't be noticeable unless the GPU is slow, or the uploaded data is huge.

Yes, to investigate this, we will need the exact clip you're using (please post the filename here after upload). Also, can you supply the complete MPlayer command-line you're using, and any MPlayer configuration files if you use any, if that's not all in yxing_mplayer.log.bz2 already.

Thanks.

yxing 02-15-11 11:39 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Quote:

Originally Posted by Stephen Warren (Post 2392259)
How did you isolate which call causes the CPU usage.

I both commented out the function call and I called it once every 10 frames instead of every frame. In the former case, CPU usage was close to 0 but the OSD failed to draw correctly. In the latter case, CPU usage was 20-30% with the OSD running, updated with a slight delay, and occasionally produced artifacts.

Quote:

Originally Posted by Stephen Warren (Post 2392259)
For how long does the CPU usage last

The CPU usage is 100% as long as the OSD is updating.

Quote:

Originally Posted by Stephen Warren (Post 2392259)
Yes, to investigate this, we will need the exact clip you're using (please post the filename here after upload). Also, can you supply the complete MPlayer command-line you're using, and any MPlayer configuration files if you use any, if that's not all in yxing_mplayer.log.bz2 already.

I am trying to upload the video using sftp. The command I am using is
Code:

sftp vdpau@partners.ftp.nvidia.com
but it's complaining that the blank password I am entering is incorrect.

I am not running mplayer with any custom configuration files, but the command-line argument I am using is:
Code:

mplayer /home/oberon/yxing.ts -vo vdpau -demuxer +mpegts -vc +ffh264vdpau -nosound -osdlevel 3

Stephen Warren 02-15-11 11:49 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Sigh, the sftp site is having some issues. I thought they'd very recently been fixed, but it appears it's broken again. I'll try to find out why.

Licaon 02-16-11 03:42 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Quote:

Originally Posted by Stephen Warren (Post 2392259)
Licaon, I'm not sure how that other thread is related to this one.

mplayer.log: VDPAU nvidia: Error detected 1 426

Stephen Warren 02-16-11 10:51 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Licaon, that error message indicates the overlay presentation queue couldn't be created, which is unrelated to the CPU usage issue that is the subject of this thread.

Stephen Warren 02-16-11 11:08 AM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
FYI, I've filed internal problem report #793119 for this.

Can you please provide the exact MPlayer command-line you're using.

Just to be clear, when you say OSD you aren't referring to subtitle data within the media file, but OSD such as what MPlayer shows when volume/brightness/... is adjusted. If so, can you also state exactly how you're triggering that.

Did you build MPlayer yourself? If not, which package did you install? If so, can you state the exact SVN revision you built, and the configure command-line you used.

Thanks.

yxing 02-16-11 05:35 PM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
1 Attachment(s)
The exact command line I am using is:
Code:

mplayer /home/oberon/yxing.ts -vo vdpau -demuxer +mpegts -vc +ffh264vdpau -nosound -osdlevel 3 -quiet
No, I am not referring to the subtitles. The "-osdlevel 3" switch makes the MPlayer OSD display the play time and a "playing" icon.

Yes, I built MPlayer SVN revision 32882 and configured it with
Code:

./configure --enable-gui
I've attached the output of that command.

danix 04-08-11 02:36 PM

Re: mplayer OSD rendering using 100% CPU with VDPAU
 
Hi yxing, the SFTP site issue is (partially) resolved now. Can you please upload an affected video clip? (You may need to use sftp interactively.)


All times are GMT -5. The time now is 04:15 AM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.