X264 settings. Slow or slower?

vankedisiTV

New Member
I realised with ref=1 setting i can go slower!

But I'm torn between 2 options here (even 3)

Slower preset:
Threads 0
Rc-lookahead 120
Trellis 2
Subme 5
Partitions all
Direct pred temporal
Aq mode 3
Ref 2
Bframes 2

Or

Slow preset

Threads 0

Rc-lookahead 120

Trellis 2

Subme 5

Partitions all

Direct pred temporal

Aq mode 3

Ref 1

Me=tesa

Bframes 4

The difference is me tesa, ref, preset and bframes.
 

vankedisiTV

New Member
This is an example vod with aforementioned slow settings (me tesa etc) https://m.twitch.tv/videos/1219358016


I'm really not sure if should remove ref and me tesa flags. Me tesa eats cpu away. So that i can actually go slower with ref=2

Or i can remove ref and me settings at stay at slow no issues.

Does me=tesa really help with the steaming?
 

koala

Active Member
Honestly, you are wasting your time. The work has already been done, and the result are the x264 presets. CPU consuming options are the ones who improve compression/quality. If you change an option to make it less cpu-intensive, just to be able to use one "slower" preset, you're changing what the "slower" option defines to be better. Essentially, you have the same quality as some faster preset. So use the faster preset (with its options unchanged) in the first place.

You cannot also judge the resulting quality by just watching a video. There's too much bias in your brain. The only objective judge for this is the computer. If you must fiddle with these options, use ffmpeg with the psnr option to find out the psnr (a logarithmic measure for the reciprocal of the difference between the raw video and the encoded version) and find settings with the highest. This is what you want to optimize: find the highest psnr.
Or here for a more professional text: https://websites.fraunhofer.de/video-dev/calculating-vmaf-and-psnr-with-ffmpeg/
The article gives an example how to get the psnr from a given raw and encoded video. You can also directly get the psnr by using the -tune psnr -psnr options during encoding.
 

vankedisiTV

New Member
Honestly, you are wasting your time. The work has already been done, and the result are the x264 presets. CPU consuming options are the ones who improve compression/quality. If you change an option to make it less cpu-intensive, just to be able to use one "slower" preset, you're changing what the "slower" option defines to be better. Essentially, you have the same quality as some faster preset. So use the faster preset (with its options unchanged) in the first place.

You cannot also judge the resulting quality by just watching a video. There's too much bias in your brain. The only objective judge for this is the computer. If you must fiddle with these options, use ffmpeg with the psnr option to find out the psnr (a logarithmic measure for the reciprocal of the difference between the raw video and the encoded version) and find settings with the highest. This is what you want to optimize: find the highest psnr.
Or here for a more professional text: https://websites.fraunhofer.de/video-dev/calculating-vmaf-and-psnr-with-ffmpeg/
The article gives an example how to get the psnr from a given raw and encoded video. You can also directly get the psnr by using the -tune psnr -psnr options during encoding.
Hi

I can run slow with no flags. I was just trying these settings prior to x264 perfection posts i found.

Me=tesa makes my cpu usage goes very high. Higher than slow preset in default.

That's why i was confused.

Should i fall back in ref= to get better me=

Since you put it that way i will delete me= and ref= from my custom settings.

I'm just trying to get more from my cpu to better compress images as i am on 60fps. Maybe i should go down to 50fps for the superior image quality.

:s yes so many things going in my brain. Thanks for the analytical tool and guide for comparing x264 settings.

I wish i could do very slow and eat more electricity for my 3 distinguished viewers at my twitch channel.

What is your opinion on rc look ahead? Should i make it 120? Would it be better? I don't want ot have extra head room in my cpu since it's a dedicated streaming pc
 

vankedisiTV

New Member
Okay it looks like i will be streaming at 50fps for some time and deleted the ref me etc flags and running slow boneless. İ just added rc lookahead 120 because i heard it increases image quality. If not i will delete it too. Shame we can't tweak some stuff.

My cpu can't do slower but it does slow.
Only flag i use is threads 0

I want to increase some settings without a too much penalty.

Seems like its time to settle for 50fps.
 

koala

Active Member
I want to increase some settings without a too much penalty.
This is understandable, but it's in vain. Your time is better spent with creating great video content, not with esoteric encoding options. If there were any settings that could be improved without more CPU usage, they would be included in the standard settings a long time ago. You can rely on the standards - on the presets. If your machine is able to support one preset, but not the next slower preset, stick with the preset that works. Starting with the medium preset, visual changes to the next slower presets are so small, they are not really perceivable by the human brain, only by benchmarks. The slow preset might perhaps be perceivable if you spend an hour comparing, but beyond that - negligible. Irrespective to what you configure.
 

vankedisiTV

New Member
This is understandable, but it's in vain. Your time is better spent with creating great video content, not with esoteric encoding options. If there were any settings that could be improved without more CPU usage, they would be included in the standard settings a long time ago. You can rely on the standards - on the presets. If your machine is able to support one preset, but not the next slower preset, stick with the preset that works. Starting with the medium preset, visual changes to the next slower presets are so small, they are not really perceivable by the human brain, only by benchmarks. The slow preset might perhaps be perceivable if you spend an hour comparing, but beyond that - negligible. Irrespective to what you configure.
Makes sense. Diminishing returns.

I am fully stable no encoding lag or missed frames in slow at 936p 60fps

I will be streaming at x264 slow 936p 50fps for superior quality than 60fps

Thanks for your feedback. I was a bit obsessed with the encoding stuff trying everything. This cpu wasn't able to do slow until i did a negatif volt offset and pbo setting :p

I hope my channel can grow take care friend
 
Top