H.264 Encoding - Superb Codec, But CPU Hungry

Posted:
in General Discussion edited January 2014
So just to report, I encoded DVD-Rip of UrbanLegends2:FinalCut (look, the actual movie is not important, yeah?) ...Anyways about 688x288 resolution, ~2.35:1 aspect ratio, and the following tools: RipIt4Me, DVDDecrypter, StaxRip, and "Sharktooth's Profiles" (easily Googled).



On the Mac side DVDs to Xvid is pretty smooth and easy with FFMpegX, although I don't have enough time with the iBook to let it sit and encode to the demanding H.264(x264).



So I managed to get 90minutes down to ~850mb (Video bitrate target was about 1100kbps) H.264(x264), mp4 container, 160kbps mp3 stereo audio. The "Sharktooth** Profile" I used (all the B-frames, CABAC, muti-hex whatever settings etc etc.) was "HighQuality-Slow". 2-pass.



There's a setting (alpha-beta deblocking or something like that*) was set to be a bit sharper than Xvids which normally look a bit too "smoothed" out.



Believe it or not at first I thought it was artifacts but I looked at the final mp4 encode, and given the DVD is a few years old, and I was able to see the film noise - mainly those little dust and scratches...!!



So that's my encoding adventure over the past two days, it took about 12 hours for that encode on my borrowed Pentium-4-M-2.0ghz 512mb RAM and what I am convinced is a 4200rpm not 5400rpm drive.



Definitely x264 H.264 encoding is really very powerful, but intensely CPU hungry. My main point was that it's powerful enough to encode even high complex scenes like ripples on the river, even keep the "film scratch and dust", all depending on time and multipass and settings in x264.



I'm going to try some stuff with BattlestarGalactica:Season2 DVDs, but set the (alpha-beta deblocking or something like that*) to smooth it out. The BSG:Season2 DVD has a lot of film grain and general video noise. So I'll try the encode with a higher loop filter alpha-beta to smooth things out more, because HighQuality-Slow Sharktooth** is set so sharp it preserves the original DVD "video noise" in the final H.264 encode, even with bitrates down to 1000kbps.



It is interesting that after a while looking at DVD-rips, the actual MPEG2 video when enlarged to fullscreen on your say 1280x1024 or 1440x900 monitor, you can see the "noise" in it. I have personally thought that MPEG2 compression on DVDs is such a brilliant invention for its time, because the MPEG2 "noise" actually melds very well with the natural "film grain/ unevenness" of theatre prints. It's funny though, now we expect digitally-remastered and the latest HDTV content and so on to have virtually no dust and scratches and only "artistic" film grain in there.



Almost like going into the next 10 years, we are willing to put up with a lot of blockiness (eg. YouTube, SDTV viewing on large LCD TV screens) but film scratches and noise are like, "eeewww..". I have read on these forums, people that saw StarWars3 on digital (2k or 4k in theatres) were much happier with it than the film print version in theatres.





*Called the "loop filter" alpha-beta setting (http://www.digital-digest.com/articl...ons_page3.html)

**He's the big kahuna on http://www.doom9.org/

Comments

  • Reply 1 of 11
    In general though at the 1000 to 2000kbps mark for DVD-resolution material, there is still some blockiness in areas of very tight shades (dark colour tones close together, especially in fast moving scenes, like clouds whipping by in a close external shot of a plane flying)... Nonetheless, to whack a 6-7GB file down to 900mb is a great evolution in video codec technology.



    Following an earlier debate, On2VP6/VP7 (On2VP6 used in Flash 8/9 video eg. YouTube) will dominate in the online/ low bitrate region, while H.264 is a clear winner in the DVD-quality and HDTV space. Real and WMV can go frack themselves. 8)
  • Reply 2 of 11
    You need to upgrade to a Core Duo. Those encoding times will go way down.
  • Reply 3 of 11
    Quote:
    Originally Posted by k squared View Post


    You need to upgrade to a Core Duo. Those encoding times will go way down.



    Tell me about it. \ Core2Duo 2+ghz OC'ed easy to 3ghz. With the encoding tools you can split it into 2-4 threads. (kinda splicing up the encoding job to 4 sections of the final file, technically not multicore but it works, I think).....



    I'd probably be able to do a solid DVDRip to MP4-h.264(x624) within 2.5-3 hours.



    The multitasking handling and hard disk memory pagefile swapping is pretty dodgy on even WinXP2pro. Using FFMpegX on the ol' iBook G4 933mhz 640mb RAM 5400rpm HDD, the CPU may be loaded 100% for hella long time but handling other tasks like Safari, Pages, iPhoto, switching between two users, the "system load balancing" as a whole as handled by 10.3.9 is really really good.



    Definitely if I get around to it and finances open up, I would use a MacIntel Core2Duo as the core system for general apps, life organising stuff, web chillin', etc. and fully-loaded 24/7 encoding, downloading, etc. Just because of the responsiveness and, what I expect with Leopard 10.5.x, excellent system load balancing, and Time Machine, so that I can just fire-and-forget with my backups and stuff. I'd use maybe a redundant two-separate backup HDs for Time Machine (ie, sync with one every few nights/ weeks and sync with the other every few nights/ weeks.)



    That way my AMD64 rig [as I mentioned probably too many times, next upgrade is add 1GB to go to 2GB, 7200rpm drive for 2x80gb nVidia onboard RAID, RAID 0 setting] will be pure and clean and free for just gaming, and I won't load it down with tons of apps which are messy to uninstall, and impossible to run encoding/ downloading in the background while trying to play a demanding latest PC game.



    Sort of my AMD64 becomes my console. With upgradeable graphics, RAM, and HardDisk speed unlike consoles!! Interestingly, for any mid-end AMD64 singlecore bought in 2005, going into 2007 and 2008, for PC-gaming "PC as the gaming console", the AMD singlecore will hold up through the end of 2008 -- RAM, HD, and mainly GPU are the bottlenecks. As long as one is reasonable about game settings (a few that affect CPU bust very mostly GPU), NOT install WinVista -- keep to WinXP2pro, and have minimal anti-virus anti-everything apps running in the background.
  • Reply 4 of 11
    stoostoo Posts: 1,490member
    Quote:

    Interestingly, for any mid-end AMD64 singlecore bought in 2005, going into 2007 and 2008, for PC-gaming "PC as the gaming console", the AMD singlecore will hold up through the end of 2008



    3700+ for ever! (Cheapest Athlon 64 (single) with 1MB cache ).
  • Reply 5 of 11
    3000+ Venice Best Overclocker !!!
  • Reply 6 of 11
    H.264 2-pass encoding at an average 1200 bitrate takes about 3 hours on my first generation black MacBook (1.25 GB RAM). I use an external FireWire HD, where the source and destination files reside. Overall system system responsiveness is excellent and Activity Monitor shows HandBrake using 180% of processor load. I'm quite happy with the move to Intel.
  • Reply 7 of 11
    aquaticaquatic Posts: 5,602member
    holy geez. Sounds like it's actually good I didn't get a SuperDrive on my C2D MacBook. Sounds like the quality on DIVX these days is as good as DVD, and only takes a few hours and the machine stays responsive. I'll have to field test this. Sounds like HandBrake is the way to go. Or whatever does x264, that sounds like where it's at. If handbrake doesn't do it I guess I'll use FFmpgex. last time I tried that app though I was quite put off by the complexity of it.
  • Reply 8 of 11
    Quote:
    Originally Posted by Aquatic View Post


    holy geez. Sounds like it's actually good I didn't get a SuperDrive on my C2D MacBook. Sounds like the quality on DIVX these days is as good as DVD, and only takes a few hours and the machine stays responsive. I'll have to field test this. Sounds like HandBrake is the way to go. Or whatever does x264, that sounds like where it's at. If handbrake doesn't do it I guess I'll use FFmpgex. last time I tried that app though I was quite put off by the complexity of it.



    Hi Aquatic and kSquared, here's an interesting discussion I found:

    http://www.mybroadband.co.za/vb/showthread.php?t=58972



    I haven't used HandBrake in a while so I'll have to look up what it's doing nowadayz...
  • Reply 9 of 11
    Quote:
    Originally Posted by k squared View Post


    H.264 2-pass encoding at an average 1200 bitrate takes about 3 hours on my first generation black MacBook (1.25 GB RAM). I use an external FireWire HD, where the source and destination files reside. Overall system system responsiveness is excellent and Activity Monitor shows HandBrake using 180% of processor load. I'm quite happy with the move to Intel.



    That's bloody excellent I guess you're talking about a DVDrip of about 1.5 hours? Two-pass H.264 (is it x264 or mencoder H.264(?)) at 1200 bitrate and 3 hours is pretty good for 1st gen Core Duo (Yonah).
  • Reply 10 of 11
    Quote:
    Originally Posted by Aquatic View Post


    holy geez. Sounds like it's actually good I didn't get a SuperDrive on my C2D MacBook. Sounds like the quality on DIVX these days is as good as DVD, and only takes a few hours and the machine stays responsive. I'll have to field test this. Sounds like HandBrake is the way to go. Or whatever does x264, that sounds like where it's at. If handbrake doesn't do it I guess I'll use FFmpgex. last time I tried that app though I was quite put off by the complexity of it.



    Forget about Divx and Xvid 8) Your Core2Duo MacBook can handle H.264 encoding, trust me, it's worth the extra time. FFMpegX is a bit complex, offers more options, I think, but is pretty decent. I'm not sure if FFMpegX can do multicore, whereas sounds like HandBrake can. You'll have to play with it, and yeah HandBrake was last updated in Feb 2006. FFMpegX Oct 2006 release has the latest X264 encoder which is faster+better than mEncoder H.264, HandBrake's H.264 encoder, and Quicktime7's H.264 encoder...
  • Reply 11 of 11
    Quote:
    Originally Posted by Aquatic View Post


    holy geez. Sounds like it's actually good I didn't get a SuperDrive on my C2D MacBook. Sounds like the quality on DIVX these days is as good as DVD, and only takes a few hours and the machine stays responsive. I'll have to field test this. Sounds like HandBrake is the way to go. Or whatever does x264, that sounds like where it's at. If handbrake doesn't do it I guess I'll use FFmpgex. last time I tried that app though I was quite put off by the complexity of it.



    You can probably push 2.5hours for about slightly less than 1000kbps video rate, 2 pass H.264 encoding on your machine, for a 90 minute DVD, to whack the whole movie down into a 700mb CD. 8) Otherwise if you're storing on your hard disk, or external drive, I think going for about 1800kbps to 2000kbps is a nice quality for a 1.5-2gb final video file. A decent cut-down from a 5-7+gb DVD with all the extra stuff and what not.
Sign In or Register to comment.