LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices



Reply
 
Search this Thread
Old 04-28-2006, 02:26 PM   #1
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Rep: Reputation: 15
High Def Video Bottleneck: Where?


Hey... Anyone want to give suggestions as to where the bottleneck is in my system? I'm trying to play high definition video (720i DivX and 1080p H.264) and it constantly comes out grainy.

My Rig:
Processor: AMD Athlon 3000+ Venice
Motherboard: Giga-Byte GA-K8N Pro-SLI (F9 Bios)
Video Card: Leadtek PX6800TDH Geforce 6800 256MB (Nvidia)
Monitor: Sony SDM-S71 Set at 1280x1024.
RAM: Kingston HyperX 512MB (2x256MB) -- Dual Channel Mode
Software: SuSe 10 (32 bit) with Kernel 2.6.13-15.8-default, Nvidia Drivers and Mplayer Codec Pack installed.


I've tried both Kaffeine and mplayer to play these videos, but still looks like 640x480.

Can anybody think of a specific bottleneck that I could fix?

thanks
 
Old 04-30-2006, 01:01 AM   #2
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
Hard drives are always the bottleneck when dealing with video files. Try setting up tmpfs to handle the space of the high definition video. By placing the video clip in memory, the hard drive will not be the bottleneck. Your RAM should send at least one gigabyte per second.
 
Old 04-30-2006, 04:01 PM   #3
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Original Poster
Rep: Reputation: 15
eh?

When playing the files, I notice about 1 blink per second or so on the hard drive indicator light.

Anyway... How do I setup a tmpfs?

Gess I'm more of a newb to linux than I thought

Last edited by Simdude90015; 04-30-2006 at 04:04 PM.
 
Old 04-30-2006, 04:22 PM   #4
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
Add the following in /etc/fstab.
Code:
none            /dev/shm        tmpfs   defaults     0 0
 
Old 04-30-2006, 04:43 PM   #5
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Original Poster
Rep: Reputation: 15
ok. I copied the videos into /dev/shm as root, played them with mplayer -fs as root, and they still come out grainy. Maybe it's my video card (generic) or screen (from 2002)?
 
Old 05-01-2006, 12:38 AM   #6
maroonbaboon
Senior Member
 
Registered: Aug 2003
Location: Sydney
Distribution: debian
Posts: 1,495

Rep: Reputation: 48
If it's not CPU or disk I guess it looks like a video problem. Do you know what codec and video driver mplayer is using? You should get this info when mplayer starts up from the command line e.g.

Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)

and

VO: [xv] 688x400 => 688x400 Planar YV12

for the driver. 'mplayer -vo help' will show you the drivers available.

You can also run 'ps aux' to check how much CPU/RAM the mplayer process is using. There are big differences between the different software video drivers that mplayer can use.
 
Old 05-02-2006, 02:54 AM   #7
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
YV12 is only 12 bit of color (4 bit for red, 4 bit for green, and 4 bit for blue). If you include "-vf yuy2" when running mplayer, the quality of the picture quality can double. YUY2 provides about 16 bit color or 15 bits for the effective color for 16 bits (5 bits for red, 5 bits for green, and 5 bits for blue). Also it will use the video card to accellerate the video clip. You could include "-nosound" to mplayer to decrease the bandwidth or increase the video performance.

You can try to use sdl as the video output device, but run mplayer in verbose mode to make sure it does not do any downsampling to keep the 24 bit or 32 bit of color.
 
Old 05-02-2006, 11:01 PM   #8
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Original Poster
Rep: Reputation: 15
Post

When I try to play the videos, I get this in the terminal output:

720i File (cellfactor_hd.avi):
Code:
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm:ffmpeg (FFmpeg MPEG-4)
Code:
VO: [xv] 1280x720 => 1280x720 Planar YV12
... and the ps aux line for mplayer...
Code:
jim       8094  5.6  4.4  41812 23120 pts/1    S+   22:45   0:00 mplayer cellfactor_hd.avi
(5.6% CPU and 4.4% RAM)

1080p File (macbreak20060424-002s-1080p-h264.mov):
Code:
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm:ffmpeg (FFmpeg H.264)
Code:
VO: [xv] 1920x1080 => 1920x1080 Planar YV12
... and the ps aux line for mplayer...
Code:
jim       8054 89.7  7.6  57848 39272 pts/1    S+   22:45   0:26 mplayer macbreak20060424-002s-1080p-h264.mov
(89.7% CPU and 7.6% RAM)


Here's the output of mplayer -vo help:

Code:
MPlayer SuSE Linux 10.0 (i686)-Packman-4.0.2 (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 with runtime CPU detection - WARNING - this is not optimal!
To get best performance, recompile MPlayer with --disable-runtime-cpudetection.


Available video output drivers:
	xv	X11/Xv
	x11	X11 ( XImage/Shm )
	xover	General X11 driver for overlay capable video output drivers
	gl	X11 (OpenGL)
	gl2	X11 (OpenGL) - multiple textures version
	dga	DGA ( Direct Graphic Access V2.0 )
	sdl	SDL YUV/RGB/BGR renderer (SDL v1.1.7+ only!)
	fbdev	Framebuffer Device
	fbdev2	Framebuffer Device
	aa	AAlib
	zr	Zoran ZR360[56]7/ZR36060 Driver (DC10(+)/buz/lml33/MatroxRR)
	zr2	Zoran ZR360[56]7/ZR36060 Driver (DC10(+)/buz/lml33/MatroxRR)
	bl	Blinkenlights driver: http://www.blinkenlights.de
	vesa	VESA VBE 2.0 video output
	directfb	Direct Framebuffer Device
	dfbmga	DirectFB / Matrox G200/G400/G450/G550
	xvidix	X11 (VIDIX)
	cvidix	console VIDIX
	null	Null video output
	mpegpes	Mpeg-PES to DVB card
	yuv4mpeg	yuv4mpeg output for mjpegtools
	png	PNG file
	jpeg	JPEG file
	gif89a	animated GIF output
	tga	Targa output
	pnm	PPM/PGM/PGMYUV file
	md5sum	md5sum of each frame
I tried using SDL and/or -vf yuy2 like electro suggested, no luck... exact same thing.

-Simdude

P.S. Sorry for the delay in my response, my internet connection was down.
 
Old 05-03-2006, 07:54 AM   #9
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
Both files that you posted are using lossy compression. Lossy compression will be blocky or also known as pixelated. The blockiness will only get worst when there is too much content. There are two things that video lossy compression use to compress. One is bit rate and the other is quantizer.

The cellfactor video has poor quality because the bitrate is not high enough to handle the content. The content of the cellfactor video is a lot and hard for the DiVx codec to get good compression ratios. Probably xViD will do a better job than DiVx. The cellfactor video is blocky not grainy. The term grainy is the video looks like colorful sand. The macbreak video is corrupted so there is no point to describe the quality.

You can try using the following commands when playing the cellfactor video.

mplayer -quiet -vf scale=-1:-1,pp=de,yuy2 cellfactor_hd.avi

The de video filter of pp includes verticle and horizontal deringing. It actually softens the video.

I suggest looking at the HD movie trailers at a apple.com. Use mplayerplug-in to download it, but manually use mplayer to play the movie trailers. You will have to include the -nosound option because FAAD2 codec will crash mplayer.
 
Old 05-03-2006, 04:26 PM   #10
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Original Poster
Rep: Reputation: 15
Ok... I've torrented and uploaded a fresh copy of the macbreak video to my server, now in a compressed archive.

macbreak20060424-002s-1080p-h264.mov:
MD5SUM: 0826c140622bf15dbafbd9711caf872f
SHA1SUM:6868e2d19505a528733684287fdd946867ef3f22

macbreak20060424-002s-1080p-h264.mov.tar.bz2:
MD5SUM: 9fe45a45ca040f32bd8c834c49112329
SHA1SUM: beb10ed34ea1741a22b808e8fabdb5219e7ba38b

If the file is still corrupt, the torrent I'm using to get the file is
here.

I'm pretty sure that the file isn't corrupt on the torrent, since it's a popular mac vidcast -- if there were a problem it would have been fixed by the authors.
 
Old 05-03-2006, 08:26 PM   #11
Electro
Guru
 
Registered: Jan 2002
Posts: 6,042

Rep: Reputation: Disabled
What I mean corrupted, I mean that the frames break up at the lower half of the video. Probably, it is a problem with the open source H.264 project or it is encyrpted. I assume that it works with the Apple's Quicktime Player.

If you want to see want I mean, click here. 264 KB

No, it is not a corrupted ping (png) file. What you see from the PNG image, is what mplayer outputs. I first output to a targa (tga) with mplayer and use Gimp to resize and save the image.

BTW, did you understand what I mean by lossy compression.
 
Old 05-03-2006, 09:10 PM   #12
Simdude90015
Member
 
Registered: Jun 2004
Location: Pittsburgh, PA area
Distribution: Debian 3.1 (or variant... depends on which machine)
Posts: 72

Original Poster
Rep: Reputation: 15
That screencap is exactly what I see-- definitely not encrypted... the group that produces this makes fun of DRM etc all the time.

I guess I'm stuck untill the H.264 project deals with high def video.

Yes, I do understand lossy compression: Big File (High quality) goes in, Smaller file with unneccesarily lower quality comes out.

Thanks for all the help!
 
  


Reply

Tags
cli, guide, mplayer, video


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
No sound on Intel High Def Audio on Fedora Core 3 ck1125 Linux - Hardware 2 06-06-2005 09:45 PM
High def TV tuner w/remote cs-cam Linux - General 1 02-09-2005 07:01 PM
Video Set Too High in X11 Frank Zappa Suse/Novell 3 11-11-2004 09:53 PM
Is there any app to convert emacs's syntax highlight def. file to vim's def. file ? cyu021 Linux - Software 0 10-06-2004 12:02 AM
Why do I have a High System CPU Usage Bottleneck linuxboy69 Linux - Software 3 09-02-2004 04:55 PM


All times are GMT -5. The time now is 06:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration