Log in

View Full Version : encoding/tools


Picaadi
27th December 2020, 13:51
Hello ,


I have the LOTR theatrical 4k version ( bluray)


I want to encode it using the settings posted down (these settings are from LOTR UHD extended already encoded version). I used media info to check encoding settings, but I don't have any similar encoding settings in Megui, do you know what tool was used?


Back in my time when I encoded I used Megui and x264, but I think for UHD and HDR, it is no longer valid.


Would appreciate the help who can assist/help me find the tool with which I can encode using the exact down settings.


cpuid=1111039 / frame-threads=4 / numa-pools=24 / wpp / no-pmode / no-pme / no-psnr / no-ssim / log-level=2 / input-csp=1 / input-res=3840x1608 / interlace=0 / total-frames=328432 / level-idc=0 / high-tier=1 / uhd-bd=0 / ref=4 / no-allow-non-conformance / repeat-headers / annexb / aud / no-hrd / info / hash=0 / no-temporal-layers / open-gop / min-keyint=23 / keyint=250 / gop-lookahead=0 / bframes=4 / b-adapt=2 / b-pyramid / bframe-bias=0 / rc-lookahead=40 / lookahead-slices=4 / scenecut=40 / hist-scenecut=0 / radl=0 / no-splice / no-intra-refresh / ctu=64 / min-cu-size=8 / no-rect / no-amp / max-tu-size=32 / tu-inter-depth=4 / tu-intra-depth=4 / limit-tu=4 / rdoq-level=2 / dynamic-rd=0.00 / no-ssim-rd / signhide / no-tskip / nr-intra=0 / nr-inter=0 / no-constrained-intra / strong-intra-smoothing / max-merge=4 / limit-refs=1 / limit-modes / me=3 / subme=5 / merange=57 / temporal-mvp / no-frame-dup / no-hme / weightp / no-weightb / no-analyze-src-pics / deblock=0:0 / no-sao / no-sao-non-deblock / rd=4 / selective-sao=0 / no-early-skip / rskip / rskip-edge-threshold=0.050000 / no-fast-intra / no-tskip-fast / no-cu-lossless / no-b-intra / no-splitrd-skip / rdpenalty=0 / psy-rd=2.00 / psy-rdoq=2.20 / no-rd-refine / no-lossless / cbqpoffs=-2 / crqpoffs=-2 / rc=crf / crf=18.1 / qcomp=0.60 / qpstep=4 / stats-write=0 / stats-read=0 / ipratio=1.40 / pbratio=1.30 / aq-mode=4 / aq-strength=0.85 / no-cutree / zone-count=0 / no-strict-cbr / qg-size=32 / no-rc-grain / qpmax=69 / qpmin=0 / no-const-vbv / sar=0 / overscan=0 / videoformat=5 / range=0 / colorprim=9 / transfer=16 / colormatrix=9 / chromaloc=1 / chromaloc-top=2 / chromaloc-bottom=2 / display-window=0 / master-display=G(13250,34500)B(7500,3000)R(34000,16000)WP (15635,16450)L(40000000,50) / cll=602,184 / min-luma=0 / max-luma=1023 / log2-max-poc-lsb=8 / vui-timing-info / vui-hrd-info / slices=1 / no-opt-qp-pps / no-opt-ref-list-length-pps / no-multi-pass-opt-rps / scenecut-bias=0.05 / hist-threshold=0.03 / no-opt-cu-delta-qp / no-aq-motion / hdr10 / hdr10-opt / no-dhdr10-opt / no-idr-recovery-sei / analysis-reuse-level=0 / analysis-save-reuse-level=0 / analysis-load-reuse-level=0 / scale-factor=0 / refine-intra=0 / refine-inter=0 / refine-mv=1 / refine-ctu-distortion=0 / no-limit-sao / ctu-info=0 / no-lowpass-dct / refine-analysis-type=0 / copy-pic=1 / max-ausize-factor=1.0 / no-dynamic-refine / no-single-sei / no-hevc-aq / no-svt / no-field / qp-adaptation-range=1.00 / no-scenecut-aware-qpconformance-window-offsets / right=0 / bottom=0 / decoder-max-rate=0 / no-vbv-live-multi-pass

VoodooFX
27th December 2020, 14:57
MeGUI and x265. In x265 configuration dialog press "Misc" and add there settings you want.

Picaadi
27th December 2020, 16:14
MeGUI and x265. In x265 configuration dialog press "Misc" and add there settings you want.



Hello, I dont think it was done with megui , I tried to insert the script there but it always fails.

excellentswordfight
27th December 2020, 17:21
Hello, I dont think it was done with megui , I tried to insert the script there but it always fails.
What script? The output from mediainfo is no script, it contains the settings, but the syntax wont work.

Without looking at it indepth it looks like prestet ”slower” is used as a baseline, together with crf 18 (or 18.1 to be exact), aq-mode 4, no-sao and a few other tweaks.

Not sure why its important to use the same settings... But just look up each syntax here if you wanna copy the settings https://x265.readthedocs.io/en/3.1/cli.html

The frontend (i.e megui) is not that important here, x265 is used, so any frontend using x265 as encoder that lets you parse custom commands will work

stax76
27th December 2020, 18:52
So any frontend using x265 as encoder that lets you parse custom commands will work.

In staxrip:

1. replace '/ ' with -- to get a command line
2. copy command line to clipboard
3. open x265 dialog
4. from the dropdown at the bottom of the dialog choose Import Command Line

Picaadi
27th December 2020, 19:32
Thank you stax76. trying now

Picaadi
27th December 2020, 19:56
I replaced '/ ' with -- (see also down)

But from where I can import the commands in the x265?

https://ibb.co/SJ2Qk88




cpuid=1111039 --frame-threads=4 --numa-pools=24 --wpp --no-pmode --no-pme --no-psnr --no-ssim --log-level=2 --input-csp=1 --input-res=3840x1608 --interlace=0 --total-frames=328432 --level-idc=0 --high-tier=1 --uhd-bd=0 --ref=4 --no-allow-non-conformance --repeat-headers --annexb --aud --no-hrd --info --hash=0 --no-temporal-layers --open-gop --min-keyint=23 --keyint=250 --gop-lookahead=0 --bframes=4 --b-adapt=2 --b-pyramid --bframe-bias=0 --rc-lookahead=40 --lookahead-slices=4 --scenecut=40 --hist-scenecut=0 --radl=0 --no-splice --no-intra-refresh --ctu=64 --min-cu-size=8 --no-rect --no-amp --max-tu-size=32 --tu-inter-depth=4 --tu-intra-depth=4 --limit-tu=4 --rdoq-level=2 --dynamic-rd=0.00 --no-ssim-rd --signhide --no-tskip --nr-intra=0 --nr-inter=0 --no-constrained-intra --strong-intra-smoothing --max-merge=4 --limit-refs=1 --limit-modes --me=3 --subme=5 --merange=57 --temporal-mvp --no-frame-dup --no-hme --weightp --no-weightb --no-analyze-src-pics --deblock=0:0 --no-sao --no-sao-non-deblock --rd=4 --selective-sao=0 --no-early-skip --rskip --rskip-edge-threshold=0.050000 --no-fast-intra --no-tskip-fast --no-cu-lossless --no-b-intra --no-splitrd-skip --rdpenalty=0 --psy-rd=2.00 --psy-rdoq=2.20 --no-rd-refine --no-lossless --cbqpoffs=-2 --crqpoffs=-2 --rc=crf --crf=18.1 --qcomp=0.60 --qpstep=4 --stats-write=0 --stats-read=0 --ipratio=1.40 --pbratio=1.30 --aq-mode=4 --aq-strength=0.85 --no-cutree --zone-count=0 --no-strict-cbr --qg-size=32 --no-rc-grain --qpmax=69 --qpmin=0 --no-const-vbv --sar=0 --overscan=0 --videoformat=5 --range=0 --colorprim=9 --transfer=16 --colormatrix=9 --chromaloc=1 --chromaloc-top=2 --chromaloc-bottom=2 --display-window=0 --master-display=G(13250,34500)B(7500,3000)R(34000,16000)WP(15635,16450)L(40000000,50) --cll=602,184 --min-luma=0 --max-luma=1023 --log2-max-poc-lsb=8 --vui-timing-info --vui-hrd-info --slices=1 --no-opt-qp-pps --no-opt-ref-list-length-pps --no-multi-pass-opt-rps --scenecut-bias=0.05 --hist-threshold=0.03 --no-opt-cu-delta-qp --no-aq-motion --hdr10 --hdr10-opt --no-dhdr10-opt --no-idr-recovery-sei --analysis-reuse-level=0 --analysis-save-reuse-level=0 --analysis-load-reuse-level=0 --scale-factor=0 --refine-intra=0 --refine-inter=0 --refine-mv=1 --refine-ctu-distortion=0 --no-limit-sao --ctu-info=0 --no-lowpass-dct --refine-analysis-type=0 --copy-pic=1 --max-ausize-factor=1.0 --no-dynamic-refine --no-single-sei --no-hevc-aq --no-svt --no-field --qp-adaptation-range=1.00 --no-scenecut-aware-qpconformance-window-offsets --right=0 --bottom=0 --decoder-max-rate=0 --no-vbv-live-multi-pass

excellentswordfight
27th December 2020, 20:19
You should remove the following from that: cpuid=1111039 --frame-threads=4 --numa-pools=24 --total-frames=328432

Picaadi
27th December 2020, 20:34
thank you excellentswordfight, trying now , managed to import the parameters into the x265 dialog , but not all of my parameters are changed when encoding , so I gues possible because I have to remove `` cpuid=1111039 --frame-threads=4 --numa-pools=24 --total-frames=328432``

Come back after I try. thank you.

Picaadi
28th December 2020, 07:27
Thanks everyone, managed to solve this with staxrip with the help from you:
Down is the x265 encoding settings I`m encoding with , I have an i7 8700 so it will take somewhere around 48h max.

What do you thing about the encoding settings? And yes I want to retain as much quality as possible,the UHD resolution and HDR feature.





Video
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : SMPTE ST 2086, HDR10 compatible
Width : 3 840 pixels
Height : 1 608 pixels
Display aspect ratio : 2.40:1
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 1)
Bit depth : 10 bits
Writing library : x265 3.4+30-g6722fce:[Windows][GCC 9.3.0][64 bit] 10bit
Encoding settings : cpuid=1111039 / frame-threads=4 / numa-pools=24 / wpp / no-pmode / no-pme / no-psnr / no-ssim / log-level=2 / input-csp=1 / input-res=3840x1608 / interlace=0 / total-frames=256674 / level-idc=0 / high-tier=1 / uhd-bd=0 / ref=4 / no-allow-non-conformance / repeat-headers / annexb / aud / no-hrd / info / hash=0 / no-temporal-layers / open-gop / min-keyint=23 / keyint=250 / gop-lookahead=0 / bframes=4 / b-adapt=2 / b-pyramid / bframe-bias=0 / rc-lookahead=40 / lookahead-slices=4 / scenecut=40 / hist-scenecut=0 / radl=0 / no-splice / no-intra-refresh / ctu=64 / min-cu-size=8 / no-rect / no-amp / max-tu-size=32 / tu-inter-depth=4 / tu-intra-depth=4 / limit-tu=4 / rdoq-level=2 / dynamic-rd=0.00 / no-ssim-rd / signhide / no-tskip / nr-intra=0 / nr-inter=0 / no-constrained-intra / strong-intra-smoothing / max-merge=4 / limit-refs=1 / limit-modes / me=3 / subme=5 / merange=57 / temporal-mvp / no-frame-dup / no-hme / weightp / no-weightb / no-analyze-src-pics / deblock=0:0 / no-sao / no-sao-non-deblock / rd=4 / selective-sao=0 / no-early-skip / rskip / no-fast-intra / no-tskip-fast / no-cu-lossless / no-b-intra / no-splitrd-skip / rdpenalty=0 / psy-rd=2.00 / psy-rdoq=2.20 / no-rd-refine / no-lossless / cbqpoffs=-2 / crqpoffs=-2 / rc=crf / crf=18.1 / qcomp=0.60 / qpstep=4 / stats-write=0 / stats-read=0 / ipratio=1.40 / pbratio=1.30 / aq-mode=4 / aq-strength=0.85 / no-cutree / zone-count=0 / no-strict-cbr / qg-size=32 / no-rc-grain / qpmax=69 / qpmin=0 / no-const-vbv / sar=0 / overscan=0 / videoformat=5 / range=0 / colorprim=9 / transfer=16 / colormatrix=9 / chromaloc=1 / chromaloc-top=1 / chromaloc-bottom=1 / display-window=0 / master-display=G(13250,34500)B(7500,3000)R(34000,16000)WP(15635,16450)L(40000000,50) / cll=602,187 / min-luma=0 / max-luma=1023 / log2-max-poc-lsb=8 / vui-timing-info / vui-hrd-info / slices=1 / no-opt-qp-pps / no-opt-ref-list-length-pps / no-multi-pass-opt-rps / scenecut-bias=0.01 / hist-threshold=0.03 / no-opt-cu-delta-qp / no-aq-motion / hdr10 / hdr10-opt / no-dhdr10-opt / no-idr-recovery-sei / analysis-reuse-level=1 / analysis-save-reuse-level=0 / analysis-load-reuse-level=0 / scale-factor=0 / refine-intra=0 / refine-inter=0 / refine-mv=1 / refine-ctu-distortion=0 / no-limit-sao / ctu-info=0 / no-lowpass-dct / refine-analysis-type=0 / copy-pic=1 / max-ausize-factor=1.0 / no-dynamic-refine / no-single-sei / no-hevc-aq / no-svt / no-field / qp-adaptation-range=1.00 / no-scenecut-aware-qpconformance-window-offsets / right=0 / bottom=0 / decoder-max-rate=0 / no-vbv-live-multi-pass
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0050 cd/m2, max: 4000 cd/m2
Maximum Content Light Level : 602 cd/m2
Maximum Frame-Average Light Level : 187 cd/m2

stax76
28th December 2020, 15:48
What do you thing about the encoding settings?

Maybe post the command line as well.

In the settings of MediaInfo.NET (https://github.com/stax76/MediaInfo.NET) enable Show special presentation of encoding settings, it's more easy to read:


Rate Control
aq-mode=2 / no-aq-motion / aq-strength=1.00
cbqpoffs=0 / no-const-vbv / crf=18.0 / crqpoffs=0
cutree / ipratio=1.40 / no-lossless / nr-inter=0
nr-intra=0 / pbratio=1.30 / qcomp=0.60
qg-size=32 / qpmax=69 / qpmin=0 / qpstep=4
rc=crf / no-rc-grain / no-strict-cbr / zone-count=0

Analysis
no-amp / analysis-reuse-level=0 / no-b-intra
ctu=64 / no-cu-lossless / dynamic-rd=0.00
no-dynamic-refine / early-skip / fast-intra
no-hevc-aq / no-limit-modes / limit-refs=3
limit-tu=0 / max-tu-size=32 / min-cu-size=8
psy-rdoq=0.00 / qp-adaptation-range=1.00
rd=2 / rdoq-level=0 / rdpenalty=0 / no-rd-refine
no-rect / refine-ctu-distortion=0 / refine-inter=0
refine-intra=0 / refine-mv=1 / rskip / scale-factor=0
no-splitrd-skip / no-ssim-rd / no-tskip
no-tskip-fast / tu-inter-depth=1 / tu-intra-depth=1

Slice Decision
b-adapt=0 / bframe-bias=0 / bframes=4 / b-pyramid
ctu-info=0 / gop-lookahead=0 / no-intra-refresh
keyint=250 / lookahead-slices=4 / min-keyint=25
open-gop / radl=0 / rc-lookahead=15 / ref=2
refine-analysis-type=0 / scenecut=40 / scenecut-bias=0.05

Motion Search
no-analyze-src-pics / no-hme / max-merge=2
me=1 / merange=57 / subme=1 / temporal-mvp
no-weightb / weightp

Loop Filter
deblock=0:0 / no-limit-sao / sao / no-sao-non-deblock
selective-sao=4

VUI
chromaloc=0 / cll=0,0 / colormatrix=2 / colorprim=2
no-dhdr10-opt / display-window=0 / max-luma=255
min-luma=0 / overscan=0 / range=0 / sar=0
transfer=2 / videoformat=5

Bitstream
annexb / no-aud / hash=0 / no-hrd / no-idr-recovery-sei
info / log2-max-poc-lsb=8 / no-multi-pass-opt-rps
no-opt-cu-delta-qp / no-opt-qp-pps / no-opt-ref-list-length-pps
repeat-headers / no-single-sei / no-temporal-layers
vui-hrd-info / vui-timing-info

Input/Output
no-field / input-csp=1 / input-res=720x720
interlace=0 / total-frames=0

Performance
copy-pic=1 / frame-threads=2 / numa-pools=6
no-pme / no-pmode / slices=1 / wpp

Statistic
log-level=2 / no-psnr / no-ssim / stats-read=0
stats-write=0

Other
analysis-load-reuse-level=0 / analysis-save-reuse-level=0
bottom=0 / cpuid=1111039 / decoder-max-rate=0
high-tier=1 / hist-scenecut=0 / hist-threshold=0.03
level-idc=0 / max-ausize-factor=1.0 / no-allow-non-conformance
no-constrained-intra / no-frame-dup / no-hdr10
no-hdr10-opt / no-lowpass-dct / no-scenecut-aware-qpconformance-window-offsets
no-splice / no-svt / no-vbv-live-multi-pass
psy-rd=2.00 / right=0 / signhide / strong-intra-smoothing
uhd-bd=0

Picaadi
28th December 2020, 16:43
ok, found it , attached down stax76

Picaadi
28th December 2020, 16:45
Video

Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : SMPTE ST 2086, HDR10 compatible
Width : 3840 pixel
Height : 1608 pixel
Display aspect ratio : 2.40:1
Frame rate : 23.976 (24000/1001) fps
Color space : YUV
Chroma subsampling : 4:2:0 (Type 1)
Bit depth : 10 bit
Writing library : x265 3.4+30-g6722fce:[Windows][GCC 9.3.0][64 bit] 10bit
Encoding settings :

Rate Control
aq-mode=4 / no-aq-motion / aq-strength=0.85
cbqpoffs=-2 / no-const-vbv / crf=18.1 / crqpoffs=-2
no-cutree / ipratio=1.40 / no-lossless
nr-inter=0 / nr-intra=0 / pbratio=1.30
qcomp=0.60 / qg-size=32 / qpmax=69 / qpmin=0
qpstep=4 / rc=crf / no-rc-grain / no-strict-cbr
zone-count=0

Analysis
no-amp / analysis-reuse-level=1 / no-b-intra
ctu=64 / no-cu-lossless / dynamic-rd=0.00
no-dynamic-refine / no-early-skip / no-fast-intra
no-hevc-aq / limit-modes / limit-refs=1
limit-tu=4 / max-tu-size=32 / min-cu-size=8
psy-rdoq=2.20 / qp-adaptation-range=1.00
rd=4 / rdoq-level=2 / rdpenalty=0 / no-rd-refine
no-rect / refine-ctu-distortion=0 / refine-inter=0
refine-intra=0 / refine-mv=1 / rskip / scale-factor=0
no-splitrd-skip / no-ssim-rd / no-tskip
no-tskip-fast / tu-inter-depth=4 / tu-intra-depth=4

Slice Decision
b-adapt=2 / bframe-bias=0 / bframes=4 / b-pyramid
ctu-info=0 / gop-lookahead=0 / no-intra-refresh
keyint=250 / lookahead-slices=4 / min-keyint=23
open-gop / radl=0 / rc-lookahead=40 / ref=4
refine-analysis-type=0 / scenecut=40 / scenecut-bias=0.01

Motion Search
no-analyze-src-pics / no-hme / max-merge=4
me=3 / merange=57 / subme=5 / temporal-mvp
no-weightb / weightp

Loop Filter
deblock=0:0 / no-limit-sao / no-sao / no-sao-non-deblock
selective-sao=0

VUI
chromaloc=1 / cll=602,187 / colormatrix=9
colorprim=9 / no-dhdr10-opt / display-window=0
master-display=G(13250,34500)B(7500,3000)R(34000,16000)WP(15635,16450)L(40000000,50)
max-luma=1023 / min-luma=0 / overscan=0
range=0 / sar=0 / transfer=16 / videoformat=5

Bitstream
annexb / aud / hash=0 / no-hrd / no-idr-recovery-sei
info / log2-max-poc-lsb=8 / no-multi-pass-opt-rps
no-opt-cu-delta-qp / no-opt-qp-pps / no-opt-ref-list-length-pps
repeat-headers / no-single-sei / no-temporal-layers
vui-hrd-info / vui-timing-info

Input/Output
no-field / input-csp=1 / input-res=3840x1608
interlace=0 / total-frames=256674

Performance
copy-pic=1 / frame-threads=4 / numa-pools=24
no-pme / no-pmode / slices=1 / wpp

Statistic
log-level=2 / no-psnr / no-ssim / stats-read=0
stats-write=0

Other
analysis-load-reuse-level=0 / analysis-save-reuse-level=0
bottom=0 / chromaloc-bottom=1 / chromaloc-top=1
cpuid=1111039 / decoder-max-rate=0 / hdr10
hdr10-opt / high-tier=1 / hist-scenecut=0
hist-threshold=0.03 / level-idc=0 / max-ausize-factor=1.0
no-allow-non-conformance / no-constrained-intra
no-frame-dup / no-lowpass-dct / no-scenecut-aware-qpconformance-window-offsets
no-splice / no-svt / no-vbv-live-multi-pass
psy-rd=2.00 / right=0 / signhide / strong-intra-smoothing
uhd-bd=0

Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries: Display P3
Mastering display luminance : min: 0.0050 cd/m2, max: 4000 cd/m2
Maximum Content Light Level : 602 cd/m2
Maximum Frame-Average Light Level: 187 cd/m2