Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-4 AVC / H.264

Reply
 
Thread Tools Search this Thread Display Modes
Old 2nd July 2009, 01:15   #1  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
x264 defaults changing

A lot of patches are going to be pushed soon. And among other things, the x264 defaults are changing. We will also be adding presets to the CLI interface (but not the library interface).

New defaults (suggestions welcome):

--subme 7 --bframes 3 --weightb --8x8dct --ref 3 --mixed-refs --trellis 1 --crf 23 --threads auto --no-psnr --no-ssim

Logic behind this change: x264 should be by default High Profile and generate relatively high quality, but not entirely max itself out; it should be a reasonable speed/quality tradeoff. UMH is probably a bit too costly speed-wise to set as the default.

Logic behind the CRF: x264 should, by default, encode with a reasonable quality that isn't overkill but isn't low quality. This means a user can generate a good encode simply by doing "x264 inputfile -o outputfile". Also, out of respect to goddess Eris of Discord.

The intention here is that you can simply use x264 with defaults and it will give Very Good Results that nobody can complain about.

I will announce quality/profile presets soon as well.

GUI designers: have fun

Last edited by Dark Shikari; 5th July 2009 at 21:44.
Dark Shikari is offline   Reply With Quote
Old 2nd July 2009, 01:28   #2  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by Dark Shikari View Post
A lot of patches are going to be pushed soon.
Now I'm curious. What patches? ^^

Quote:
Originally Posted by Dark Shikari View Post
New defaults (suggestions welcome):

--subme 7 --bframes 3 --weightb --8x8dct --ref 3 --mixed-refs --crf 23 --threads auto
Sounds like a great idea. But maybe CRF 23 is a bit too high. I'd prefer CRF 21

What about b-adapt 2? Still too slow at 3 b-frames? And what about b-pyramid?
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊
LoRd_MuldeR is offline   Reply With Quote
Old 2nd July 2009, 01:31   #3  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
Quote:
Originally Posted by LoRd_MuldeR View Post
What about b-adapt 2? Still too slow at 3 b-frames? And what about b-pyramid?
B-pyramid has a small enough benefit and large enough number of problems with some hardware devices that I don't want to deal with the bug reports.

B-adapt 2 is too slow, it'll be in a slower preset (which will also use me=umh).
Dark Shikari is offline   Reply With Quote
Old 2nd July 2009, 02:20   #4  |  Link
elguaxo
Registered User
 
elguaxo's Avatar
 
Join Date: Jun 2006
Posts: 260
Quote:
Originally Posted by lord_mulder View Post
sounds like a great idea. But maybe crf 23 is a bit too high. i'd prefer crf 21
+1
elguaxo is offline   Reply With Quote
Old 2nd July 2009, 03:07   #5  |  Link
Chengbin
Registered User
 
Join Date: Oct 2007
Posts: 1,060
How about some partitions set as default?
Chengbin is offline   Reply With Quote
Old 2nd July 2009, 03:27   #6  |  Link
Sagekilla
x264aholic
 
Join Date: Jul 2007
Location: New York
Posts: 1,752
It's implied that the old defaults hold true still except where specified up there:

Code:
--partitions <string>   Partitions to consider ["p8x8,b8x8,i8x8,i4x4"]
                                - p8x8, p4x4, b8x8, i8x8, i4x4
                                - none, all
The only thing disabled is p4x4, which is less useful than the other partitions. I wouldn't consider p4x4 for anything but one of slower profiles.
__________________
You can't call your encoding speed slow until you start measuring in seconds per frame.
Sagekilla is offline   Reply With Quote
Old 2nd July 2009, 04:31   #7  |  Link
linyx
Un-Registered User
 
linyx's Avatar
 
Join Date: Mar 2008
Location: Audio Stream - 0x80
Posts: 341
Quote:
--ref 3
Maybe 4 or even possibly 5? Or would it not be worth the loss in speed (for defaults of course)?
linyx is offline   Reply With Quote
Old 2nd July 2009, 05:39   #8  |  Link
Manao
Registered User
 
Join Date: Jan 2002
Location: France
Posts: 2,856
Quote:
B-pyramid has a small enough benefit and large enough number of problems with some hardware devices that I don't want to deal with the bug reports.
Do note however that the problems lay in x264, not in the hardware devices.
Quote:
Maybe 4 or even possibly 5?
4 would break level 4.1 for 1080p streams. So either the default ref number depends on resolution (and then the users will never understand how it is set), or it stay at 3.
__________________
Manao is offline   Reply With Quote
Old 2nd July 2009, 06:05   #9  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
Quote:
Originally Posted by Manao View Post
Do note however that the problems lay in x264, not in the hardware devices.
Unrelated; even before we lowered the dpb by 1, the problem still existed with some devices and players (perhaps not as many). This is probably due to the fact that b-pyramid requires a delay of 2 frames.

If the issue is ever fixed, I'll make it default.
Quote:
Originally Posted by Manao View Post
4 would break level 4.1 for 1080p streams. So either the default ref number depends on resolution (and then the users will never understand how it is set), or it stay at 3.
x264 (with the changes announced in the presets thread) automatically changes ref to match level as long as you don't force --ref yourself.
Dark Shikari is offline   Reply With Quote
Old 2nd July 2009, 06:17   #10  |  Link
juGGaKNot
Registered User
 
juGGaKNot's Avatar
 
Join Date: Feb 2008
Posts: 733
K, so lets go.

Autovaq and open gop will be added ?

Quote:
with the changes announced in the presets thread) automatically changes ref to match level as long as you don't force --ref yourself.
To match level ? not resolution ? so there will be no difference if i usa 800x600 or 1920x1080 at 4.0 ?

Last edited by juGGaKNot; 2nd July 2009 at 06:19.
juGGaKNot is offline   Reply With Quote
Old 2nd July 2009, 06:26   #11  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
Quote:
Originally Posted by juGGaKNot View Post
To match level ? not resolution ? so there will be no difference if i usa 800x600 or 1920x1080 at 4.0 ?
"To match level" has an inherent, implicit dependence on resolution.
Dark Shikari is offline   Reply With Quote
Old 2nd July 2009, 06:35   #12  |  Link
juGGaKNot
Registered User
 
juGGaKNot's Avatar
 
Join Date: Feb 2008
Posts: 733
Quote:
Originally Posted by Dark Shikari View Post
"To match level" has an inherent, implicit dependence on resolution.
Ah, so no more setting the level ?

So it will be 3.2 up to 1280, 4.0 up to 1920 ?
juGGaKNot is offline   Reply With Quote
Old 2nd July 2009, 07:20   #13  |  Link
Manao
Registered User
 
Join Date: Jan 2002
Location: France
Posts: 2,856
Quote:
x264 (with the changes announced in the presets thread) automatically changes ref to match level as long as you don't force --ref yourself.
I know that, but I don't think it's good that default settings on 1080p content would lead to a default level of 4.2 or 5.0 if --ref was bumped up.
__________________
Manao is offline   Reply With Quote
Old 2nd July 2009, 07:43   #14  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
Quote:
Originally Posted by Manao View Post
I know that, but I don't think it's good that default settings on 1080p content would lead to a default level of 4.2 or 5.0 if --ref was bumped up.
If someone wants level 4.1 they should specify it.
Dark Shikari is offline   Reply With Quote
Old 2nd July 2009, 07:51   #15  |  Link
Gabriel_Bouvigne
L.A.M.E. developer
 
Gabriel_Bouvigne's Avatar
 
Join Date: Dec 2001
Location: Paris - France
Posts: 276
Instead of --option/--no-option, what about "--option boolean", with boolean allowed to be 0/false/off-1/true/on ?
Gabriel_Bouvigne is offline   Reply With Quote
Old 2nd July 2009, 08:12   #16  |  Link
greath
Registered User
 
Join Date: Aug 2004
Posts: 65
Quote:
Originally Posted by Dark Shikari View Post

I will announce quality/profile presets soon as well.
I was wondering if you could give quality profiles for both first pass and second pass encoding? I am always confisued about which settings have an effect on each pass and which you can specifiy values for that speed up the first pass encoding but have an effect on second pass. I think that first pass is just to determine the frame types, so I assume that settings that can affect this are ones that must be present in both passes, but things like estimating the motion vectors are not important in the first pass?

Thanks.
greath is offline   Reply With Quote
Old 2nd July 2009, 08:52   #17  |  Link
buzzqw
HDConvertToX author
 
Join Date: Nov 2003
Location: Cesena,Italy
Posts: 6,552
would by handy a "--turbo" switch that will disable/lower some values (subme/ref/...)
so users will be using a standard "slow" profile in two pass mode, BUT simply adding "--turbo" (and not removing other options) to first pass string , will got a huge first pass speed boost (as xvid option)

about preset: you surely know x264 better (and a lot!) then me, but you could take a look at HDConvertToX or MeGui profiles

in hdc i have build profiles based on your suggestions

last one: +1 for crf 21

BHH
__________________
HDConvertToX: your tool for BD backup
MultiX264: The quick gui for x264
AutoMen: The Mencoder GUI
AutoWebM: supporting WebM/VP8
buzzqw is offline   Reply With Quote
Old 2nd July 2009, 09:24   #18  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,806
I would suggest something like this:
Code:
--crf 22 --aud --ref 3 --mixed-refs --bframes 3 --b-adapt 1 --weightb --direct auto --subme 7 --trellis 1 --partitions all --8x8dct --me umh --threads auto --thread-input --progress --no-psnr --no-ssim
Atak_Snajpera is offline   Reply With Quote
Old 2nd July 2009, 09:27   #19  |  Link
juGGaKNot
Registered User
 
juGGaKNot's Avatar
 
Join Date: Feb 2008
Posts: 733
Quote:
Originally Posted by buzzqw View Post
would by handy a "--turbo" switch that will disable/lower some values (subme/ref/...)
so users will be using a standard "slow" profile in two pass mode, BUT simply adding "--turbo" (and not removing other options) to first pass string , will got a huge first pass speed boost (as xvid option)

about preset: you surely know x264 better (and a lot!) then me, but you could take a look at HDConvertToX or MeGui profiles

in hdc i have build profiles based on your suggestions

last one: +1 for crf 21

BHH
Well its turbo by default and only setting --slowetcetc makes it full

+1 for default profile 3 pass

Quote:
--bframes 16 --b-adapt 2 --b-pyramid --weightb --direct auto --subme 9 --trellis 2 --psy-rd 1.5:1.5 --partitions all --8x8dct --me tesa --merange 128 --qcomp 1 --threads auto --aq-mode 1 --aq-strength 1.0
Kidding ofc.

Why is

--no-mixed-refs replaces --mixed-refs
--no-8x8dct replaces --8x8dct
--no-weightb replaces --weightb

Replaced ? enabled by default now ?

Quote:
Originally Posted by Atak_Snajpera View Post
I would suggest something like this:
Code:
--crf 22 --aud --ref 3 --mixed-refs --bframes 3 --b-adapt 1 --weightb --direct auto --subme 7 --trellis 1 --partitions all --8x8dct --me umh --threads auto --thread-input --progress --no-psnr --no-ssim
Doesn't that add huge encoding time vs default megui partitions ? with maximum 0.5% compression gain ?

Last edited by juGGaKNot; 2nd July 2009 at 09:31.
juGGaKNot is offline   Reply With Quote
Old 2nd July 2009, 09:33   #20  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,806
Quote:
Doesn't that add huge encoding time vs default megui partitions ? with maximum 0.5% compression gain ?
And who says that? The guy who uses crazy placebo settings
Atak_Snajpera is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 10:30.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.