LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-02-2010, 12:01 AM   #1
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908
Blog Entries: 26

Rep: Reputation: 49
play brrip on Pentium3 CPU with 1GHz processor


I have windows xp.
I ran a blue ray rip on my P3 with following options

-lavdopts lowres=1:fast:skiploopfilter=all

-vf scale=640:272 (because my computer supports max resolution 1024x768 while original video is 1280x528)

Yet the video is slower than audio.
Can I do anything else to play this ?
Or
How can I convert the file to lower resolution video maintaining quality & small size using ffmpeg or mencoder?
here are file specifications
Code:
$ffmpeg -i /data/sumeet/video/hollywood/blood\ diamonds/blood\ diamonds-2006.mkv FFmpeg version git-1dbd813, Copyright (c) 2000-2010 the FFmpeg developers
  built on Oct  1 2010 19:28:12 with gcc 4.4.3
  configuration: '--enable-avfilter' '--enable-avfilter-lavf' '--enable-vdpau' '--enable-bzlib' '--enable-libgsm' '--enable-libschroedinger' '--enable-libspeex' '--enable-libtheora' '--enable-libvorbis' '--enable-pthreads' '--enable-zlib' '--disable-stripping' '--enable-runtime-cpudetect' '--enable-gpl' '--enable-postproc' '--enable-swscale' '--enable-x11grab' '--enable-libdc1394' '--disable-static' '--enable-libopencore-amrnb' '--enable-libopencore-amrwb' '--enable-version3' '--enable-libfaac' '--enable-nonfree' '--enable-libmp3lame' '--enable-libx264' '--enable-gpl' '--enable-libxvid' '--enable-static'
  libavutil     50.23. 0 / 50.23. 0
  libavcore      0. 1. 0 /  0. 1. 0
  libavcodec    52.84. 1 / 52.84. 1
  libavformat   52.77. 0 / 52.77. 0
  libavdevice   52. 2. 0 / 52. 2. 0
  libavfilter    1.26. 1 /  1.26. 1
  libswscale     0.11. 0 /  0.11. 0
  libpostproc   51. 2. 0 / 51. 2. 0
[matroska @ 0xaae8470] Estimating duration from bitrate, this may be inaccurate

Seems stream 0 codec frame rate differs from container frame rate: 47.95 (5000000/104271) -> 24.00 (24/1)
Input #0, matroska, from '/data/sumeet/video/hollywood/blood diamonds/blood diamonds-2006.mkv':
  Duration: 02:23:21.81, start: 0.000000, bitrate: N/A
    Stream #0.0: Video: h264, yuv420p, 1280x528 [PAR 1:1 DAR 80:33], 23.98 fps, 24 tbr, 1k tbn, 47.95 tbc
    Stream #0.1: Audio: aac, 48000 Hz, stereo, s16
At least one output file must be specified

Last edited by sumeet inani; 12-02-2010 at 07:33 AM.
 
Old 12-02-2010, 01:24 AM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
You aren't going to be playing a BD rip on a P3. My dual-core laptop can barely play HD video.

If you really wanted to, you could convert it to something like a 640x272 XviD, but it would probably take that machine days just to convert the video, and obviously the video quality would be nothing like the original.
 
Old 12-02-2010, 02:21 AM   #3
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
when I just ran
mplayer.exe video-file
I got error
Code:
FATAL: Cannot initialize video driver.

Too many buffered pts

Movie-Aspect is 2.35:1 - prescaling to correct movie aspect.

VO: [directx] 1280x544 => 1280x544 Planar YV12

<vo_directx><ERROR>invalid parameters

<vo_directx><FATAL ERROR>can't use overlay mode: please use -vo directx:noaccel
 
Old 12-02-2010, 05:49 AM   #4
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
On a core2 duo I did
Code:
ffmpeg -i rsvrdg.br_300mbfilms.com.mkv -s vga -vcodec libxvid  -acodec libmp3lame 640x480.mkv
In 50 minutes I got 640x480 resolution video of 231 MB compared to that 470MB BRRip . Can I make it better ?

Last edited by sumeet inani; 12-02-2010 at 05:50 AM.
 
Old 12-02-2010, 07:13 AM   #5
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Quote:
Originally Posted by MS3FGX View Post
You aren't going to be playing a BD rip on a P3. My dual-core laptop can barely play HD video.
Indeed, it's impossible.

As for converting the video, I recommend this guide I wrote:
http://draconishinobi.50webs.com/linux/encoding.html

Either one will result in very good quality.
 
Old 12-02-2010, 07:33 AM   #6
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
This time I tried (from man page of ffmpeg)
Code:
ffmpeg -i blood\ diamonds-2006.mkv  -s vga -f avi -vcodec mpeg4 -b 800k -g 300 -bf 2 -acodec libmp3lame -ab 128k snatch.avi
I am getting fantastic results with 1010MB file size.

Had I used my mind then I should try '-s 640x264' because original blue ray rip is 1280x528 , so that would be proportionate.
That would have taken less space .

Last edited by sumeet inani; 12-02-2010 at 07:52 AM.
 
Old 12-02-2010, 11:43 PM   #7
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Shockingly The file size difference between 640x480 and 640x264 is just 0.2MB.
 
Old 12-07-2010, 01:45 AM   #8
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Also I played brrip though with aberrations on my pentium3 via
(1)extract sound using ffmpeg
(2)mplayer video_file -audiofile sound.mp3 -vf scale=width:height -framedrop
Here width , height is fraction of original.
By giving sound file as input , we are saving effort of processor to decode audio from brrip stream.

Last edited by sumeet inani; 12-07-2010 at 09:21 AM.
 
Old 03-07-2011, 12:32 AM   #9
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
CONCEPT
formula to calculate video bitrate
Code:
bitrate = (target_size_in_Mbytes - sound_size_in_Mbytes) * 1024 * 1.024 * 8 / length_in_secs
sound_size is obtained from
Code:
mencoder INPUT_video_file -of rawaudio -oac mp3lame -ovc copy  -o sound_size.mp3
Other than
Code:
ffmpeg -i Input_video_file  -s widthxheight -f avi -vcodec mpeg4 -b from_formula -g 300 -bf 2 -acodec libmp3lame -ab 96k dvdrip.avi
you can also make dvdrip using mencoder.

I use it when my ffmpeg gives 'segmentation error' or 'cannot resample 5.1 surround sound to 2 channels'
Code:
mencoder INPUT_video_file   -ovc lavc -lavcopts vcodec=mpeg4:vhq:vbitrate=from_formula -vf scale -zoom  -oac mp3lame -lameopts br=96 -xy width_desired -o dvdrip.avi

Last edited by sumeet inani; 03-07-2011 at 01:04 AM.
 
Old 03-07-2011, 03:06 AM   #10
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Using qscale produces a smaller and higher quality file. As for the seg fault on resampling, you should extract the audio, resample with another program, then merge it back in.
 
Old 03-07-2011, 09:58 PM   #11
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
I thought you can convert any video to 700MB without discernable distortion.
Then , I noticed that file encoded with 530kb/s shows blocks when scene changes fastly.
I read that
Code:
-qscale <1-31>for ffmpeg
-vqscale <0-31> for mencoder
value above 13 is unacceptable
5 is best . 11 is good .
In case of audio we can have
Code:
-aq 8 (variable bit rate)
Now I know that you cannot encode any 2hour video to 700MB in one pass. For same quality some will take less space & some more.

Last edited by sumeet inani; 03-07-2011 at 10:09 PM.
 
Old 03-07-2011, 10:53 PM   #12
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
to H_TeXMeX_H
I think , you meant
Code:
ffmpeg -i input_video  -i sound_size.mp3 output.avi

Last edited by sumeet inani; 03-07-2011 at 11:47 PM.
 
Old 03-07-2011, 11:35 PM   #13
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Quote:
3.11 Which are good parameters for encoding high quality MPEG-4?
'-mbd rd -flags +mv4+aic -trellis 2 -cmp 2 -subcmp 2 -g 300 -pass 1/2', things to try: '-bf 2', '-flags qprd', '-flags mv0', '-flags skiprd'.
from http://www.ffmpeg.org/faq.html#SEC23

If you have time then you can do two pass as follows
Code:
ffmpeg -i INPUT -vcodec libx264 -vpre max -threads 0 -b BITRATE(like 800k) -pass 1 -f mp4 -y /dev/null 
quality can be max,hq(preferable),normal

ffmpeg -i INPUT -vcodec libx264 -vpre max -threads 0 -b 2100k -pass 2 OUTPUT.mp4

Last edited by sumeet inani; 03-15-2011 at 01:33 AM.
 
Old 03-08-2011, 07:06 AM   #14
cascade9
Senior Member
 
Registered: Mar 2011
Location: Brisneyland
Distribution: Debian, aptosid
Posts: 3,753

Rep: Reputation: 935Reputation: 935Reputation: 935Reputation: 935Reputation: 935Reputation: 935Reputation: 935Reputation: 935
Quote:
Originally Posted by sumeet inani View Post
Shockingly The file size difference between 640x480 and 640x264 is just 0.2MB.
Not shocking at all really.

1280:528 = 2.4242 aspect ratio
640:264 = 2.4242 aspect ratio

640:480 will just give you the old 'black bars' at the top and the bottom of the frame. Because its not really encoding any more information, the filesize is pretty much the same.
 
Old 03-09-2011, 12:25 AM   #15
sumeet inani
Member
 
Registered: Oct 2008
Posts: 908

Original Poster
Blog Entries: 26

Rep: Reputation: 49
Yeah , i forgot that .
ffmpeg will add black bands at top & bottom to maintain aspect ratio so 640x480 frame is same as 640x264 one except additional border.

Last edited by sumeet inani; 03-09-2011 at 12:26 AM.
 
  


Reply


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
2.1GHz Quad Core Barcelona CPU was recognized as 1.3GHz Quad Core libin88 Linux - Hardware 6 11-03-2008 02:08 PM
How to setup FC6 box to use cpuspeed (CPU stuck at 1Ghz)? terence8888 Linux - Software 3 07-01-2007 09:30 AM
X server 100% cpu usage on AMD Athlon 1.1GHz johngreenwood Slackware 9 03-15-2007 03:16 PM
old Athlon 1Ghz processor wont boot up dirtybird04 Linux - Hardware 7 01-07-2005 03:06 PM
PIII 800 vs. VIA 1ghz C3 Nehemiah CPU dwaldie Linux - Laptop and Netbook 3 04-22-2004 06:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:58 AM.

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
Open Source Consulting | Domain Registration