Why encoding videos to .mp4 containers using h.264 codecs takes time?


Recommended Posts

Hello,

Please I'd like to know why encoding videos to .mp4 containers using h.264 codecs takes a lot of time to do the encoding!?

I've tried a lot of tools and found two types of encoders, 1st type is the encoders do converting to various containers like WinAVI, AnyVideoConverter, ...etc

2nd type is the dedicated encoder to only encode to .mp4 like VidCoder, Handbrake ...etc

I used to use WinAVI to do the encoding but the encoded file quality was not good as VidCoder and file size for WinAVI was big and not that small as VidCoder. This is the only reason for my questions, it is mandatory important to have a very fast time for encoding, but even using core i7 2600k with nvidia gtx geforce 550 ti 2 gb with 16 gb ram ddr3 can not make the encoding time fast.

Please advise and help smile.gif

Encoding always takes a long time. If you want to wrestle some additional performance out of your machine, encoding wise, you can look for software that supports using the Intel HD graphics chip on your CPU, if your board supports this.

See: http://www.lucidlogix.com/product-virtu-gpu.html

  • Like 2

It takes time because H.264 is a very complex standard, with several options that will make your video smaller at the cost of time spent encoding (think zip, fast but bad compression, vs. 7zip, better compression but slower), and it takes a lot of computing power.

To get an idea of how complex, look at the supported options (command line switches) for the "x264 encoder", the open-source H.264 encoder used by Handbrake and several other mp4/H.264 exclusive encoders. There are tons. There are even presets for making the encoding UltraFast, Slow, VerySlow, etc at the cost of quality. Handbrake is... probably using the UltraFast option. But I might be wrong.

  On 21/08/2012 at 13:02, Frazell Thomas said:

Encoding always takes a long time. If you want to wrestle some additional performance out of your machine, encoding wise, you can look for software that supports using the Intel HD graphics chip on your CPU, if your board supports this.

See: http://www.lucidlogi...-virtu-gpu.html

Any software like that out there? I'd give it a try, with the new i5 cpu of mine.

  On 21/08/2012 at 13:08, Pupik said:

Any software like that out there? I'd give it a try, with the new i5 cpu of mine.

That software, Virtu, is the official solution and you can install and use it now. The license is paid for by your motherboard maker so you may or may not be able to use it in a paid fashion. You might also only be able to use d-Mode (Display connected to dedicated GPU) if your machine lacks a monitor port for the Intel HD graphics (i-Mode requires you to be connected to the Integrated GPU directly).

But you can download the application from that site I linked you to.

  On 21/08/2012 at 13:02, Frazell Thomas said:

Encoding always takes a long time. If you want to wrestle some additional performance out of your machine, encoding wise, you can look for software that supports using the Intel HD graphics chip on your CPU, if your board supports this.

See: http://www.lucidlogi...-virtu-gpu.html

It is my 1st time to ever know about such a thing, Even google was not a friend because I do nto know what keywords to use to search for it, so please if you may help with that that would be awesome.
  On 21/08/2012 at 13:02, billyea said:

It takes time because H.264 is a very complex standard, with several options that will make your video smaller at the cost of time spent encoding (think zip, fast but bad compression, vs. 7zip, better compression but slower), and it takes a lot of computing power.

To get an idea of how complex, look at the supported options (command line switches) for the "x264 encoder", the open-source H.264 encoder used by Handbrake and several other mp4/H.264 exclusive encoders. There are tons. There are even presets for making the encoding UltraFast, Slow, VerySlow, etc at the cost of quality. Handbrake is... probably using the UltraFast option. But I might be wrong.

I tried both of VidCoder and HandBrake and almost both of them consume the same amount of time to encode the same file with the same settings. Except that VidCoder is a bit better regarding saving custome presets.
  On 21/08/2012 at 13:08, Pupik said:

Any software like that out there? I'd give it a try, with the new i5 cpu of mine.

Yes me too and I hope the i7 26k sandy bridge do any better.

  On 21/08/2012 at 13:13, Frazell Thomas said:

That software, Virtu, is the official solution and you can install and use it now. The license is paid for by your motherboard maker so you may or may not be able to use it in a paid fashion. You might also only be able to use d-Mode (Display connected to dedicated GPU) if your machine lacks a monitor port for the Intel HD graphics (i-Mode requires you to be connected to the Integrated GPU directly).

But you can download the application from that site I linked you to.

I am using Gigabyte z-68 motherboard.

VidCoder and Handbrake take about the same amount of time because VidCoder uses the Handbrake engine. I believe Handbrake is ffmpeg.

It's slow because the encoder has to analyze the video in order to compress it. It looks like people are trying to work on a GPU-accelerated ffmpeg but I don't think it exists yet.

You could consider an OpenCL/Cuda app if you have the hardware for it.

ATI and nVidia graphics chips support the ability to offload computation to the GPU: http://www.mainconcept.com/products/sdks/gpu-acceleration/cuda-h264avc.html

Depends on the hardware you have though.

  • Like 2
  On 21/08/2012 at 13:18, GreyWolf said:

VidCoder and Handbrake take about the same amount of time because VidCoder uses the Handbrake engine. I believe Handbrake is ffmpeg.

Yes you are ight.

  On 21/08/2012 at 13:18, GreyWolf said:
It's slow because the encoder has to analyze the video in order to compress it. It looks like people are trying to work on a GPU-accelerated ffmpeg but I don't think it exists yet.

I am afraid that I do not follow this part.
  On 21/08/2012 at 13:21, articuno1au said:

You could consider an OpenCL/Cuda app if you have the hardware for it.

ATI and nVidia graphics chips support the ability to offload computation to the GPU: http://www.mainconce...da-h264avc.html

Depends on the hardware you have though.

what details I should look for in my hardware to know if it is supporting or not?

when I use various encoders I used to see the option enabled for CUDA.

  On 21/08/2012 at 13:20, NoUserName said:

there are three products:

Virtu

Virtu Universal

Virtu MVP

which one you do refer to?

What board do you have? I will see if they list Virtu support directly. I was mentioning the Virtu product I linked to directly as that is the one that my Maximus IV Extreme-Z is licesed to use. I haven't use it myself as I don't encode video, but the claims are up to 6x the performance using Intel QuickSync compared to GPU acceleration using Nvidia or AMD GPUs. Not a bad gain if you can take advantage of it.

Be sure you have the Intel i-GPU enabled in your BIOS and the Intel drivers installed for the GPU prior to installing Virtu.

http://www.lucidlogix.com/driverdownloads-virtu.html

Its been covered elsewhere, but the quality when using CUDA/Intel HD etc suffers compared to using just the CPU

Seriously how much quicker do you want it to be with your i7?

I can remember it taking 16 hours to encode a video on my P4 i can do it in such a fraction of the time now, even on my lowly core 2 duo laptop

  On 21/08/2012 at 13:29, NoUserName said:

This is what I got when I installed the drivers:

post-292348-0-51058000-1345555677.png

As I mentioned in my last post, did you both ensure the Intel HD graphics chip is enabled in your BIOS and that the Intel HD graphics drivers are installed?

Also note, Lucid lists the following encoding applications as certified so they may offer the best performance.

CyberLink Media Espresso 6.5

ArcSoft Media converter 7

  On 21/08/2012 at 13:32, Frazell Thomas said:

As I mentioned in my last post, did you both ensure the Intel HD graphics chip is enabled in your BIOS and that the Intel HD graphics drivers are installed?

Please where can I find it in my bios as I restarted my computer and viewed the bios setup and did not found anything similar to that name, so how can i figure it out?

  On 21/08/2012 at 13:32, Frazell Thomas said:

Also note, Lucid lists the following encoding applications as certified so they may offer the best performance.

CyberLink Media Espresso 6.5

ArcSoft Media converter 7

Ok, I will try them both right now and feed you back.

  On 21/08/2012 at 13:32, Jdawg683 said:

probably got that message b/c youre only using your 550 Ti vs using the integrated graphics?

But there isn't any place in my motherboard to place the monitor cable except the PCI card I've, I mean the mother board is not like the older ones I used to have where I was able to connectt the monitor cable to the motherboard, I only have the nVidia pci card only to connect my monitor.
  On 21/08/2012 at 13:38, LaP said:

Check Avidemux it's a good open source software to encode video.

ok, will feed you back now abou ######.

h264 is computationally complex so it takes quite some time to encode assuming you are using good quality settings. You can use lower quality settings that will encode faster than xvid but will look better than xvid. x264 is getting OpenCL support soon so we might get a 10% or so boost in speed with an opencl capable gpu.

  On 21/08/2012 at 13:43, NoUserName said:

Please where can I find it in my bios as I restarted my computer and viewed the bios setup and did not found anything similar to that name, so how can i figure it out?

As I requested earlier, what motherboard do you have? Your board supports only d-Mode from what you described, but I can't help you any more than I have without knowing the board directly.

1. Your i7 2600K does not have GPU (Intel HD 4000) within the chip, so you don't have integrated graphics.

2. Your NVIDIA GPU supports CUDA, which is the hardware necessary to encode and decode videos. Though you'll find good performance out of this only with good professional software, like Adobe's Premiere Pro (and a little hacking).

3. Encoding takes time because the computer needs to analyse millions and millions, if not billions of pixes per second, compress them and generate a new file. It is not like a "Save as" command to convert a file. Also, if you edited the video then it takes even more time than you can imagine.

As you seem to be a noob, I think you should stick to the options you already have or you should consider diving deeper in the technicals of all this, which is not very easy, I can tell you. :)

  On 21/08/2012 at 13:52, Luis Mazza said:

1. Your i7 2600K does not have GPU (Intel HD 4000) within the chip, so you don't have integrated graphics.

Where do you get the information that the i7-2600K lacks an i-GPU? Of course, it lacks the HD 4K as that is exclusive to the 3rd Generation i7 chips (i7-3K chips), but it does have HD 3K integrated graphics (depending on the variation)...

Source: Intel: http://ark.intel.com/products/family/59136/2nd-Generation-Intel-Core-i7-Processors/desktop

  On 21/08/2012 at 14:01, Frazell Thomas said:

Where do you get the information that the i7-2600K lacks an i-GPU? Of course, it lacks the HD 4K as that is exclusive to the 3rd Generation i7 chips (i7-3K chips), but it does have HD 3K integrated graphics (depending on the variation)...

Source: Intel: http://ark.intel.com...cessors/desktop

Yes, I'm sorry, it is the 3K, but anyway, it is hardware-disabled. :)

I think you must have a motherboard that supports the iGPU, so you can enable it.

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Microsoft isn't happy you're using unsupported Exchange versions, announces final deadline by Usama Jawad Earlier this month, Microsoft announced Exchange Server Subscription Edition (SE), which is the official transition of the product to the Modern Lifecycle Policy, where software is continuously serviced without an end-of-life date, as long as you keep it updated. It also revealed surprising, but brief, Extended Security Updates (ESUs) for Exchange 2016 and 2019. As it winds down support for these products, the company has expressed some displeasure that some customers are using even older and, obviously, unsupported versions of Exchange. In a blog post, the company has noted that it currently offers migration tools that enable the migration of public folders from on-premise Exchange 2013 or older versions to Exchange Online. This is by design, but Microsoft is now changing its tune on the topic. Starting from October 1, 2025, customers leveraging Exchange 2010 or older versions of the software will not be allowed to use Microsoft's tools to migrate their public folders to Exchange Online. Microsoft believes that this deprecation will reduce reliance on legacy systems and enhance "long-term service reliability". Any migrations that are attempted after the aforementioned date will fail, so Microsoft has urged customers to complete their migrations as soon as possible. If customers want to move their data to Exchange Online after October 1, they will first have to upgrade to a newer Exchange version, which is Exchange 2013, but it is important to keep in mind that supported versions are 2016 and 2019. Microsoft has emphasized in a rather stern tone that it does not encourage using unsupported versions of Exchange Server at all, and it has just put out this advisory because it is aware that public folder migrations from legacy systems are currently active, even though they shouldn't be. Needless to say, customers should upgrade to Exchange Server 2016 or 2019 as quickly as possible, but ideally, they should consider moving to Exchange Server SE at this point, considering that the other two versions are running out of support soon, too.
    • A little bit, yeah, if you ask me. Granted, he has the right to be upset with this jerk user that attacked him, but why drop the entire project just because of ONE person? Seems a little exaggerated.
    • Xbox July Update brings PC app cloud upgrades and Rewards support by Pulasthi Ariyasinghe The Xbox team at Microsoft has another major series of updates hitting its platforms. The Xbox July Update is primarily bringing new features to the PC application, while cloud gaming services are also being upgraded. A lot of these additions were a part of Insider testing sessions previously, but now they are ready for prime time. First off, Game Pass Ultimate members can now stream supported games over the cloud, as long as they own a copy on the Xbox store. The Stream Your Own Game feature can be accessed via the Cloud Gaming section on the Xbox PC app. The feature now boasts over 250 supported games too, with recent additions including classic Assassin's Creed titles, LEGO games, and the Saints Row series. Upcoming games to the lineup include RoboCop: Rogue City – Unfinished Business, Tetris Effect Connected, Wo Long Fallen Dynasty, and more. Check here to get a full list of games. Don't forget that cross-device play histories on the app also landed for Xbox Insiders earlier this month, letting players see what games they have been playing regardless of console, PC, or cloud Xbox platform being used. Another new feature announced today as landing on the PC app this month is Rewards with Xbox. Only available in select markets and only for those above 18, Rewards can now be found in the Home section with easy access to checking out how to get more points, track progress, and more. The Xbox and Antstream Arcade joint venture, the Retro Classics app, is gaining seven more games too. These are Caesar, Conquests of Camelot: The Search for the Grail, Gabriel Knight: Sins of the Fathers, Hard Head, Okie Dokie, Skate Boardin’, and Skeleton+. Lastly, mouse and keyboard as well as touch controls continue to roll out for more games, with Police Simulator: Patrol Officers getting support for the former while South of Midnight has gained the latter.
  • Recent Achievements

    • Week One Done
      NeoWeen earned a badge
      Week One Done
    • One Month Later
      BA the Curmudgeon earned a badge
      One Month Later
    • First Post
      Doreen768 earned a badge
      First Post
    • One Month Later
      James_kobe earned a badge
      One Month Later
    • Week One Done
      James_kobe earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      660
    2. 2
      ATLien_0
      251
    3. 3
      Xenon
      164
    4. 4
      neufuse
      144
    5. 5
      +FloatingFatMan
      117
  • Tell a friend

    Love Neowin? Tell a friend!