Log in

View Full Version : 3 pass settings and tune


juGGaKNot
17th July 2009, 11:01
Im taking advantage of the automated fast first pass to move to 3 pass encoding and i have a question :

This is an important setting for 2pass encoding. It controls what x264 will do with the stats file. It has three settings:

* 1: Create a new stats file. Use this on the first pass.
* 2: Read the stats file. Use this on the final pass.
* 3: Read the stats file, and update it as well.

Should it be
--pass 1, --pass 3, --pass 2
or the megui default
--pass 1, --pass 3, --pass 3 ?

What is the point of updating the stats on the 3'rd pass if the second one updated it already ?

Second thing :
* touhou:

Optimize for Touhou captures: ref (double default reference count if greater than 1), deblock -1:-1, psy-rd 1:0.2, ipratio 2.1, aq-strength 1.3, partitions (add p4x4 if p8x8 is enabled)

Why is this preset here ? never heard of "touhou".

Keiyakusha
17th July 2009, 13:47
Why is this preset here ? never heard of "touhou".

:eek: There is some touhou preset? Cool! Does anyone knows if it suits for Scarlet Weather Rhapsody too?

nurbs
17th July 2009, 13:57
It should be pass 1/3/2 if you do a three pass encode. The point of updating the stats on the third pass is that you can make a fourth pass.

Also: Touhou (http://mirror05.x264.nl/Dark/Flash/indexflash.html)

juGGaKNot
17th July 2009, 14:17
It should be pass 1/3/2 if you do a three pass encode. The point of updating the stats on the third pass is that you can make a fourth pass.

Also: Touhou (http://mirror05.x264.nl/Dark/Flash/indexflash.html)

Well thats what i was thinking but megui has -1 -3 -3 ..

anyway thnx 1/3/2 it is.

kei http://mewiki.project357.com/wiki/X264_Settings

tune

Default: Not Set

Tune options to further optimise them for your input content. If you specify a tuning, the changes will be applied after preset but before all other parameters.

* film:

Optimize for film content: deblock -1:-1, psy-rd 1:0.15

* animation:

Optimize for animated content: ref (double default reference count if greater than 1), deblock 1:1, psy-rd 0.4:0, aq-strength 0.6, bframes (add 2 bframes to the default)

* grain:

Optimize for grainy content: deblock -2:-2, psy-rd 1:0.25, no-dct-decimate, ipratio 1.1, pbratio 1.1, aq-strength 0.5, deadzone-intra 6, deadzone-inter 6, qcomp 0.8

* psnr:

Optimize for PSNR: psy-rd 0:0, aq-mode 0

* ssim:

Optimize for SSIM: psy-rd 0:0

* touhou:

Optimize for Touhou captures: ref (double default reference count if greater than 1), deblock -1:-1, psy-rd 1:0.2, ipratio 2.1, aq-strength 1.3, partitions (add p4x4 if p8x8 is enabled)

nurbs
17th July 2009, 14:22
Doesn't matter. The only difference (if the same settings are used) between 1/3/3 and 1/3/2 is that the former allows you to do a fourth pass.

juGGaKNot
17th July 2009, 14:26
--preset placebo --tune animation --bframes 4 --bitrate 6000

4 passes big nono

thnx, close thread.

nurbs
17th July 2009, 14:35
Well, placebo is a waste of time, so is three-pass encoding. A two-pass encode with --preset slower and --slow-firstpass will probably be faster and give the same or better quality than what you do now.

juGGaKNot
17th July 2009, 15:54
3 pass with fast first pass is not that slow

how will 2 slow passes with lower setting be better quality then 2 and a fast one with better settings ?

nurbs
17th July 2009, 17:55
I thought with 3-pass the first and the second are fast. If the second and third are slow, why are you doing the first pass at all? Aren't you able to hit the target filesize with two passes? A fast and two slow passes won't give you anything quality-wise over just two slow passes.

juGGaKNot
17th July 2009, 18:27
I thought with 3-pass the first and the second are fast. If the second and third are slow, why are you doing the first pass at all? Aren't you able to hit the target filesize with two passes? A fast and two slow passes won't give you anything quality-wise over just two slow passes.

Just for hitting the bitrate, no other extra quality if the stats are made in a fast pass and tuned in a slow pass over stats being made on a full pass ?

nurbs
17th July 2009, 18:44
Look, I don't know exactly how x264 works in three pass. In two-pass mode frametype decision is done in first pass. If you do a three pass encode and the decision isn't repeated in second pass then you are sacrificing quality because some encoding options (at least --subme) influence the b-frame placement. If that's the case you are deciding where to place your b-frames with --subme 2 while you could decide with --subme 9 if you just did two slow passes. (Your second pass should have about the same speed as your third if the frametype decision isn't updated).
Even if that's not the case there is no reason to use 3-pass unless you miss the target filesize. The stats your first pass creates are made with completely different options and therefore inferior to the stats the second pass creates, so why even bother?

juGGaKNot
17th July 2009, 19:27
k, i just wanted to take advantage of the automated fast first pass but i guess 2 is k

BTW do you know anything about deadzones ? trellis 2 or 0 does not change anything on my source, would deadzone 8/8 help ?

nurbs
17th July 2009, 21:50
Never played around with deadzones, sorry.

Kurtnoise
21st July 2009, 05:07
Well thats what i was thinking but megui has -1 -3 -3 ..
no...it's tweaked internally.

Dark Shikari
21st July 2009, 05:27
:eek: There is some touhou preset? Cool! Does anyone knows if it suits for Scarlet Weather Rhapsody too?Probably not, I tuned it for the real Touhou games. ;)

Scarlet Weather Rhapsody doesn't have enough bullets to be a real Touhou game.