Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Best video play back configuration for amd64
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64
View previous topic :: View next topic  
Author Message
hvengel
Guru
Guru


Joined: 19 Sep 2004
Posts: 515

PostPosted: Sat Mar 26, 2005 7:40 pm    Post subject: Best video play back configuration for amd64 Reply with quote

I have been trying to get my multimedia video play back working as good as I think it should. I currently have it working with both xine and mplayer but not as well as I think it should. I have looked through these forums and I find little snipits of information but I have not found anything that documents how this should be configured to work at it's best on an amd64 machine.

What I am seeing is that in mplayer my playback is smooth but I can not get it to play the video full screen or any size other than default. With Kaffeine and xine the playback gets very choppy at any size larger than the default size. In both cases there is very high CPU utilization even with the playback window at a small size.

So what I am looking for is a resource that has information on how to get an optimum video playback configuration. Can anyone point me to a resource with this information or give me a low down on how this should be setup?
Back to top
View user's profile Send private message
borkdox
Tux's lil' helper
Tux's lil' helper


Joined: 16 Jan 2004
Posts: 123

PostPosted: Sat Mar 26, 2005 10:54 pm    Post subject: Reply with quote

I use gxine 0.4.2, ebuild is here: https://bugs.gentoo.org/show_bug.cgi?id=86344. I recommend alsa-lib and alsa-headers 1.0.7, instead of 1.0.8 since 1.0.8 is producing segfaults with xine and other apps. gxine works pretty good for me, I suppose xine-ui or its kde couterpart should work nicely too...

Regards
Back to top
View user's profile Send private message
omschaub
Tux's lil' helper
Tux's lil' helper


Joined: 03 Sep 2004
Posts: 132
Location: Roanoke, VA

PostPosted: Sat Mar 26, 2005 11:28 pm    Post subject: Re: Best video play back configuration for amd64 Reply with quote

hvengel wrote:
In both cases there is very high CPU utilization even with the playback window at a small size.


Oh.. I second this! I cannot believe that on my windows machine, playing any avi takes less than 5% of my crappy cpu, but on my AMD64 with a gig of high speed ram and a 128MB Nvidia card, it takes a whopping 40-100%.. with constant peaks above that which result in choppy output..

I use the xine/xine-ui and or mplayer/gmplayer with alsa and xv video driver and let us not talk about mplayer32 which has never played a file in its life with me without skipping.. This is, by far, the worst area of linux.. bar none..worse than any other area.. no exceptions IMO

I know this is supposed to be sort of an emulation based on hacked codecs, but still.. I think that it is sad that a Via cpu can decode these better at 600 MHz in windows than a frieking 64bit supercomputer.. but, I vent, so I will stop ;)
_________________
Support bacteria -- it's the only culture some people have!
Back to top
View user's profile Send private message
hvengel
Guru
Guru


Joined: 19 Sep 2004
Posts: 515

PostPosted: Sat Mar 26, 2005 11:38 pm    Post subject: Reply with quote

I don't think this is a front end issue. I have tried Kaffeine (several versions) and xine-ui with xine. Kmplayer and Kaffeine with mplayer and various codecs and versions of these codecs (ffmpeg and xvid) and my video play back is choppy at any size other than the default play back size and uses way too much CPU with all of these. What I was wondering about was what codecs to install, what my use statement in make.conf should have in it and what versions of player, codec and front end I should be using. Also 32 bit or 64 bit? This is not documented any where. I suppose because this is a moving target at this time.

On my old Athlon XP 1800 machine I could play these same videos full screen and I would use maybe 70% CPU. With my 3500 Winchester machine even using only about 1/8 of my screen for the play back window I am seeing CPU close to 100%.
Back to top
View user's profile Send private message
robnotts
Guru
Guru


Joined: 15 Mar 2004
Posts: 405
Location: Nottingham, UK

PostPosted: Sun Mar 27, 2005 7:27 am    Post subject: Reply with quote

In all seriousness, have you tried the latest version of mplayer that uses the mmx/3dnow/sse extensions on the processor? This will dramatically bring down your cpu usage when using mplayer.

Add the following to /etc/portage/package.keywords

Code:
# MPlayer with AMD64 Optimisations
=media-video/mplayer-1.0_pre6-r1        ~amd64


Doing

Code:
bash-2.05b# emerge -vp mplayer

These are the packages that I would merge, in order:

Calculating dependencies ...done!
[ebuild   R   ] media-video/mplayer-1.0_pre6-r1  (-3dfx) (-3dnow) (-3dnowex) +X+aalib +alsa (-altivec) +arts -avi +bidi +cdparanoia -debug +dga -directfb +divx4linux +doc +dts +dv -dvb +dvd +dvdread +edl +encode +esd +fbcon +ggi +gif +gtk-i8x0 +ipv6 +jack -joystick +jpeg +libcaca -lirc +live +lzo +mad +matroska -matrox (-mmx) -mmxext +mpeg +mythtv +nas +nls -nvidia +oggvorbis +opengl +oss +png -real +rtc +samba +sdl (-sse) (-sse2) (-svga) +tga +theora +truetype +v4l +v4l2 +xanim -xinerama +xmms +xv +xvid +xvmc 0 kB


shows you what flags it will be compiled with. IMPORTANT: Don't use the avi flag when compiling mplayer.

Then emerge and off you go. I can watch a widescreen DVD format mpeg2 file with ~15% cpu utilisation, and and avi (divx) file with ~12% cpu utilitsation.

Rob.
_________________
---

Gentoo Phenom][ X4 955 on AMD790 + Geforce 220GT 8GB/1.75TB (Desktop)
+ MythTV (3xFreeview,1xFreesat HD) on 1080p
Gentoo Turion64 X2 Geforce 6150 2GB/120GB (Laptop)
Back to top
View user's profile Send private message
Lucifeer
Tux's lil' helper
Tux's lil' helper


Joined: 09 Jun 2004
Posts: 110
Location: Sweden

PostPosted: Sun Mar 27, 2005 8:51 am    Post subject: Reply with quote

I get 12-15% while watching an .avi thru gmplayer32 using the "xv"-driver and fullscreen :)
_________________
Amd64 3200+ 1024DDR - workstation
AmdXP 1800+ 512sdram - server
Celeron 1.2ghz 128sdram - laptop
AMD64 live-cd w/Reiser4-support http://livecd.todesmut.org/
Back to top
View user's profile Send private message
carlos-K
n00b
n00b


Joined: 23 May 2004
Posts: 5
Location: Leeds, England

PostPosted: Sun Mar 27, 2005 10:26 am    Post subject: Reply with quote

I've noticed on my system with the latest stable version of xine-ui/xine that there appears to be a memory leak; after half an our or so of playback all available memory (1024M) is taken and the system starts to thrash.

I've had no problem with gmplayer/mplayer, which plays back using 25-35% CPU.

It's a pity about xine, as it plays back with only 8% CPU utilisation.
Back to top
View user's profile Send private message
lbrtuk
l33t
l33t


Joined: 08 May 2003
Posts: 910

PostPosted: Sun Mar 27, 2005 3:20 pm    Post subject: Re: Best video play back configuration for amd64 Reply with quote

omschaub wrote:
This is, by far, the worst area of linux.. bar none..worse than any other area.. no exceptions IMO


This is not due to 'linux suckiness', it is because you are running an amd64 system. This stuff will happen when running an amd64 system because a huge amount of video codecs are still highly optimised only in ia32 assembler. You're probably having to fall back to the c implementation. It's going to be like this for a while unfortunately.
Back to top
View user's profile Send private message
aerogems
n00b
n00b


Joined: 19 Feb 2003
Posts: 30

PostPosted: Sun Mar 27, 2005 4:40 pm    Post subject: Reply with quote

Look at it this way. Yes, it's using more CPU power, but at the same time, overall system responsiveness is much higher. I can be compiling something like KDE while watching a video, and it never skips a beat. Try that with Windows. You start getting 80-90% CPU use there, and you're going to see negative effects on the video playback.

That being said, I can say that the Mplayer CVS code has all the SIMD stuff fixed for amd64. Though you do have to hack the ebuild to add the --enable-sse2 flag (or add it on the command line).

Quote:
MPlayer dev-CVS--3.4.3-20050110 (C) 2000-2005 MPlayer Team
CPU: Advanced Micro Devices (Family: 8, Stepping: 0)
Detected cache-line size is 64 bytes
CPUflags: MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled for x86 CPU with extensions: MMX MMX2 3DNow 3DNowEx SSE SSE2
Back to top
View user's profile Send private message
IVIikko
Tux's lil' helper
Tux's lil' helper


Joined: 07 Feb 2005
Posts: 99
Location: Helsinki, Finland

PostPosted: Sun Mar 27, 2005 4:47 pm    Post subject: Reply with quote

robnotts wrote:
IMPORTANT: Don't use the avi flag when compiling mplayer.
Rob.


Why? I've compiled it with avi use flag and it works great.
Back to top
View user's profile Send private message
robnotts
Guru
Guru


Joined: 15 Mar 2004
Posts: 405
Location: Nottingham, UK

PostPosted: Sun Mar 27, 2005 6:56 pm    Post subject: Reply with quote

It originally started pulling in win32 code via wine, which wasn't good. Maybe it is now fixed?
Rob.
_________________
---

Gentoo Phenom][ X4 955 on AMD790 + Geforce 220GT 8GB/1.75TB (Desktop)
+ MythTV (3xFreeview,1xFreesat HD) on 1080p
Gentoo Turion64 X2 Geforce 6150 2GB/120GB (Laptop)
Back to top
View user's profile Send private message
hvengel
Guru
Guru


Joined: 19 Sep 2004
Posts: 515

PostPosted: Sun Mar 27, 2005 8:52 pm    Post subject: Re: Best video play back configuration for amd64 Reply with quote

lbrtuk wrote:
omschaub wrote:
This is, by far, the worst area of linux.. bar none..worse than any other area.. no exceptions IMO


This is not due to 'linux suckiness', it is because you are running an amd64 system. This stuff will happen when running an amd64 system because a huge amount of video codecs are still highly optimised only in ia32 assembler. You're probably having to fall back to the c implementation. It's going to be like this for a while unfortunately.


I totaly agree that it is not a Linux issue and it is part of being on the bleeding edge by running amd64. Thus far I must say that this is the only significant area where running 64 bit has not been up to my expectations. My experience with this stuff on 32 bit Linux was very good. So I figured that there probably better ways to configure this then what I had. That is why I was asking what the best setup for this is. I don't expect to get this as good as it was in 32 bit at this time but I would like to at least get closer.

It would be nice if there was a document that covered this. But this is probably changing too fast right now for that. But perhaps a sticky thread would be a good idea. That way as others learn new things about how to make this work better they can post to that thread and everyone else will know where to look.

I am in the process of emerging mplayer-1.0_pre6-r1 to see how it does. If I get the results that others are reporting I will be a happy camper.

OK finished emerging before I finished writing this. These 64 bit machine are fast! It does appear to use way less CPU but I can not get a full screen display when using mplayer from kmplayer, Kaffeine 0.6 or mplayerplug-in. When I select fullscreen the window maximizes but the video stays the same size surrounded by a black screen. There must be a way to fix this as others have reported that it works. So I need to figure out how to fix this. begin edit - I figured out how to fix this - in /etc/mplayer.conf you need to set zoom=yes.

So after getting this to work fullscreen I can report the following. CPU with a non-zoomed (not full screen) video window is fairly low, on the order of 20%. This is a big improvement as before I was seeing 80% to 90% under the same conditions. When I go to full screen mode CPU usage goes to near 100%. But it does seem to keep up and I did not see any choppyness in the little testing I did. So this is a big improvment and it appears to be enough to be just usable. I tested with both mpg and avi files. end edit

I also installed mplayerplug-in-2.8 and this appears to be working at least with firefox 1.0.2.

I also have xvid 1.1.0_beta installed. This is supposed to have at least some hand optimized assembly code for the k8. But I am not sure if xine or mplayer use this or how I make them use this.
Back to top
View user's profile Send private message
Zarathustra[H]
Guru
Guru


Joined: 30 Dec 2002
Posts: 389
Location: Cambridge, MA, USA

PostPosted: Tue Apr 05, 2005 5:43 pm    Post subject: Reply with quote

So wait...


You guys are telling me you can play windows media in Xine?

I used to be able to on my 32 bit install, but since I run 64bit, the win32codecs don't seem to work...

How have you guys solved this?
_________________
----
Athlon 64 3000+ / 1Gb Kingston Hyperx PC3500 / MSI K8N Neo / Geforce 6800GT
----
Back to top
View user's profile Send private message
hvengel
Guru
Guru


Joined: 19 Sep 2004
Posts: 515

PostPosted: Wed Apr 06, 2005 8:55 pm    Post subject: Reply with quote

The very latest beta versions of mplayer are a huge improvement for amd64 machines and are very usable. The only thing I can't play with it is realplayer stuff. I still have 32 bit realplayer installed. Everything else works although it still uses more CPU than it should.

Xine also will play these if you have the right libraries installed but at this point not as well as mplayer.
Back to top
View user's profile Send private message
VValdo
Guru
Guru


Joined: 08 Jan 2005
Posts: 395

PostPosted: Wed Apr 06, 2005 11:22 pm    Post subject: Reply with quote

Right now I'm watching a DVD on the Totem movie player that comes with GNOME 2.10...

Works fine, full screen too. CPU between 21% and 36% Haven't played with it too much, but I've had success w/mplayer, vlc and xine as well.

Using ALSA.. sound was always the trickiest, but I did get it working. It worked by default in Totem. Another thing that sucks is the screensaver coming on in MPlayer's fullscreen mode. Dunno if it's turned off w/Totem.

W
Back to top
View user's profile Send private message
desktopfan
Tux's lil' helper
Tux's lil' helper


Joined: 06 Mar 2004
Posts: 134
Location: Scotland

PostPosted: Thu Apr 14, 2005 11:06 am    Post subject: Reply with quote

Are you running the 'xv' video out driver?
Back to top
View user's profile Send private message
hvengel
Guru
Guru


Joined: 19 Sep 2004
Posts: 515

PostPosted: Fri Apr 15, 2005 4:08 am    Post subject: Reply with quote

I am running a Matrox G450. This is not a very powerful video card and I think this is one of the reasons that my CPU utilization is so high. I went into the config file for mplayer and set it up to use the mga driver extensions. This did help. I would imagine that if you have an Nvidia card the using xv would be even better even with an older card.
Back to top
View user's profile Send private message
RiverRat
n00b
n00b


Joined: 07 Oct 2004
Posts: 65
Location: Colorado

PostPosted: Sun Apr 17, 2005 10:53 pm    Post subject: Video on AMD64 Reply with quote

I can watch a DVD with about 5% with an AMD64 3500+. I say this because other people are posting their CPU utilizations. These will vary depending on the CPU and other things that the system is doing. I finally got my video system to work for most videos but to make it work I had to install a 32 bit binary version of mplayer. (Here: http://sh.nu/download/ebuilds/mplayer/) we should all thank Primer for this. Please read his page as there are issue with both the video driver (-vo xv) and the audio driver (-ao oss).

Thanks again Primer.
_________________
RiverRat
Back to top
View user's profile Send private message
sanmartin
Tux's lil' helper
Tux's lil' helper


Joined: 10 Aug 2005
Posts: 138
Location: Massachusetts

PostPosted: Wed Oct 26, 2005 3:11 pm    Post subject: Reply with quote

I realize this thread has been dead for a while, but I have something that might be interesting to everyone.

I was checking mplayer and xine-ui to see what the cpu usage was in each and found that gmplayer was 4-12% and xine-ui was 20-25%. As I was going through the settings for each I realized what seems to be the problem: xine-ui defaults "MPEG-4 postprocessing quality" to 3 while gmplayer has it off completely. When you turn it off in xine-ui the cpu usage is identical to gmplayer.

Does anyone know how to make gmplayer retain the video's aspect ratio when you resize the window? That is the sole reason I use xine-ui. That's the worst bug/feature/flaw/gift I've ever seen.
Back to top
View user's profile Send private message
RiverRat
n00b
n00b


Joined: 07 Oct 2004
Posts: 65
Location: Colorado

PostPosted: Wed Oct 26, 2005 8:32 pm    Post subject: Reply with quote

It has to do with the video driver. Some of them will enable dynamically changing the aspect ratios and some won't. You should investigate the man page for mplayer and search for aspect to find out how to turn it off. I don't really like that feature that much either. I think it should be off by default and enabled only for those that ask for it.
_________________
RiverRat
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64 All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum