Log in

View Full Version : Question about F3KDB


AlucardSama04
10th September 2019, 20:01
Does anybody know why dither_algo=3 is ignored when output_depth=16?

sneaker_ger
10th September 2019, 21:40
I think you misread the documentation:
1: No dithering, LSB is truncated
2: Ordered dithering
3: Floyd-Steinberg dithering

Notes:

Visual quality of mode 3 is the best, but the debanded pixels may easily be destroyed by x264, you need to carefully tweak the settings to get better result.

Mode 1 and mode 2 don’t look the best, but if you are encoding at low bitrate, they may be better choice since the debanded pixels is easier to survive encoding, mode 3 may look worse than 1/2 after encoding in this situation.

(Thanks sneaker_ger @ doom9 for pointing this out!)

This parameter is ignored if output_depth = 16.

10bit x264 command-line example:

avs2yuv -raw "script.avs" -o - | x264-10bit --demuxer raw --input-depth 16 --input-res 1280x720 --fps 24 --output "out.mp4" -
Or compile x264 with the patch on https://gist.github.com/1117711, and specify the script directly:

x264-10bit --input-depth 16 --output "out.mp4" script.avs
Default: 3
https://f3kdb.readthedocs.io/en/latest/usage.html#cmdoption-arg-dither-algo

I.e. the third note says that "dither_algo" (ANY value) is ignored when output-depth is 16 bit. I assume that is because dithering is only needed when reducing the bitdepth and if f3kdb calculates in 16 bit (does it?) there is no reduction hence no dithering is applied. (Dithering and debanding are different things.)

MeteorRain
10th September 2019, 23:12
I answered that once before.
Dithering is only used when converting down from 16 bit to lower bit depth.
For 16 bit output there's nothing to dither down, and thus the parameter is ignored.

(And yes, its internal bit depth is 16 bit for all calculates.)