Kodi Community Forum

Full Version: x265/HEVC settings in Handbrake (or alternative converter)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Probably has been answered already, but my search-fu isn't strong enough to get helpful results.

I tried my first x265 conversion with Handbrake, but unfortunately, I picked some settings that Kodi can't run through hardware encoding and my CPU isn't strong enough to handle it.

Are there any recommended HEVC settings in Handbrake that Kodi (17.6) can handle? Or another tool that can create x265 rips that will use hardware encoding in Kodi?
I usually do not have any problems with x265 ever since I upgraded my GPU to a gtx1050, but my rip only runs in software mode.

Thanks a lot!
(2018-12-21, 07:12)mechaichezilla Wrote: [ -> ]I picked some settings that Kodi can't run through hardware encoding
What sort of settings are we talking about? Most decent HEVC-capable GPUs can play pretty much every HEVC. The GTX1050 can also do HEVC encoding and speed things up 50-150 fold depending on the source video. So Handbrake should be able to trigger the GTX1050 encoding. I use ffmpeg myself, it's eventually easier when converting multiple files.

Converting videos can be a lengthy process in the beginning. It's probably best to start with default settings on a short video. Tweak settings after that, compare and adjust accordingly. The problem/challenge is that most videos are different, so they each could require different settings for the optimal result.
(2018-12-21, 13:25)Klojum Wrote: [ -> ]
(2018-12-21, 07:12)mechaichezilla Wrote: [ -> ]I picked some settings that Kodi can't run through hardware encoding
What sort of settings are we talking about? Most decent HEVC-capable GPUs can play pretty much every HEVC. The GTX1050 can also do HEVC encoding and speed things up 50-150 fold depending on the source video. So Handbrake should be able to trigger the GTX1050 encoding. I use ffmpeg myself, it's eventually easier when converting multiple files.

Converting videos can be a lengthy process in the beginning. It's probably best to start with default settings on a short video. Tweak settings after that, compare and adjust accordingly. The problem/challenge is that most videos are different, so they each could require different settings for the optimal result.  


Typically, x265 settings (like for x264) pertain to the complexity/duration of the encoding. So, you can choose settings that will take an hour for a full re-encode, to a few days even. Decoding-speed, however, is not (or extremely little) affected by your encoding settings; except for settings that affect bitrate, of course. So. if you allow Handbrake to exceed the maximum level-appropriate bitrate (a whopping 160MB/sec for 5.1, iirc), then stuttering could occur. Otherwise his H265 compliant device should be able to play 4K just fine.

Perhaps he could insert something like --vbv-maxrate in the command-line options, to limit the max rate (in CRF mode).
He should try out the GTX1050 hevc encoder. It will convert the video not with 10 fps but with with 180-250fps.

I doubt there will be much difference with a software conversion, but there will be results much-much quicker, and you will also save a bit on your electricity bill.
(2018-12-21, 15:31)Klojum Wrote: [ -> ]He should try out the GTX1050 hevc encoder. It will convert the video not with 10 fps but with with 180-250fps.

I doubt there will be much difference with a software conversion, but there will be results much-much quicker, and you will also save a bit on your electricity bill.

I heard the opposite. Smile The speed of NVEnc is phenomenal, of course, but the quality is only so-so (compared to x265). I'm going to give it another try today, for fun, and see what it does today, though.
(2018-12-21, 18:43)meimeiriver Wrote: [ -> ]but the quality is only so-so
It's usually comes downs to one thing: everyone has their own perception of what looks better, and/or sounds better.

I converted a number of tv show episodes, but I didn't put the hevc conversion to the maximum. I consider them 'fast food', and file size and quick conversions were more important than video quality.
Movies are a different matter. Those were done with better selected settings per movie. Tweaking takes time, but it pays off per movie.

Some videos can be compressed by 90% without a real quality loss. All depends on the video source quality.
Sorry, if that wasn't clear, I was not talking about encoding speed, but playback in Kodi (I assume decoding would have been the right word here). Kodi switched to softwaremode for my encoded file, making the movie stutter.

But, since encoding speed was an issue as well, I researched HW encoding for Handbrake and downloaded the latest nightly build which supports HW encoding. Now everything is fine, Handbrake is a lot faster as expected and the resulting file runs in hardware mode in Kodi as well.
Thread marked solved.