Log in

View Full Version : Understanding x264 stats


egrimisu
3rd February 2011, 16:39
First of all Thanks God doom9 is up again, i was so anxious in the las couple of days.
My question is regarding the encode stats, i have encoded the same clip with 3 diferent settings at the same bitrate, how do i know with was the best for my source? whith setting kept more detail. what do i have to compare?
Thanks i advance.


[B]encode1:

[Information] Standard error stream
-[NoImage] raw [info]: 712x480p 1:1 @ 24000/1001 fps (cfr)
-[NoImage] x264 [info]: using SAR=1/1
-[NoImage] x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
-[NoImage] x264 [info]: profile High, level 4.1
-[NoImage] x264 [info]: cabac=1 ref=16 deblock=1:-2:-2 analyse=0x3:0x133 me=tesa subme=10 psy=1 fade_compensate=0.00 psy_rd=1.00:0.00 mixed_ref=1 me_range=64 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=-2 threads=12 sliced_threads=0 nr=0 decimate=0 interlaced=0 constrained_intra=0 bframes=16 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=240 keyint_min=24 scenecut=40 intra_refresh=0 rc=2pass mbtree=0 bitrate=1000 ratetol=1.0 qcomp=0.80 qpmin=0 qpmax=69 qpstep=4 cplxblur=20.0 qblur=0.5 ip_ratio=1.10 pb_ratio=1.10 aq=1:0.70
-[NoImage] x264 [info]: started at Thu Feb 03 12:19:10 2011
-[NoImage]
-[NoImage] x264 [info]: frame I:31 Avg QP:20.30 size: 46540
-[NoImage] x264 [info]: frame P:726 Avg QP:21.99 size: 11213
-[NoImage] x264 [info]: frame B:2443 Avg QP:22.21 size: 2901
-[NoImage] x264 [info]: consecutive B-frames: 3.0% 6.3% 7.9% 12.8% 14.4% 41.3% 10.1% 1.5% 1.4% 0.3% 0.0% 1.1% 0.0% 0.0% 0.0% 0.0% 0.0%
-[NoImage] x264 [info]: mb I I16..4: 3.4% 71.7% 24.9%
-[NoImage] x264 [info]: mb P I16..4: 0.4% 3.4% 0.9% P16..4: 61.6% 22.5% 6.1% 0.3% 0.2% skip: 4.6%
-[NoImage] x264 [info]: mb B I16..4: 0.0% 0.1% 0.0% B16..8: 33.1% 6.5% 1.6% direct: 5.2% skip:53.4% L0:40.9% L1:48.1% BI:11.0%
-[NoImage] x264 [info]: 8x8 transform intra:72.2% inter:57.7%
-[NoImage] x264 [info]: direct mvs spatial:98.2% temporal:1.8%
-[NoImage] x264 [info]: coded y,uvDC,uvAC intra: 92.6% 83.8% 55.7% inter: 20.3% 16.7% 4.3%
-[NoImage] x264 [info]: i16 v,h,dc,p: 16% 24% 13% 47%
-[NoImage] x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 5% 13% 5% 11% 14% 10% 15% 10% 19%
-[NoImage] x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 6% 10% 3% 11% 14% 11% 15% 11% 18%
-[NoImage] x264 [info]: i8c dc,h,v,p: 37% 34% 15% 14%
-[NoImage] x264 [info]: Weighted P-Frames: Y:19.7% UV:6.2%
-[NoImage] x264 [info]: ref P L0: 47.9% 18.4% 14.8% 5.8% 3.7% 2.5% 2.0% 1.1% 0.9% 0.7% 0.6% 0.5% 0.4% 0.3% 0.3% 0.2%
-[NoImage] x264 [info]: ref B L0: 71.5% 15.9% 5.2% 2.2% 1.5% 1.1% 0.8% 0.4% 0.3% 0.3% 0.2% 0.2% 0.1% 0.1% 0.0%
-[NoImage] x264 [info]: ref B L1: 92.7% 7.3%
-[NoImage] x264 [info]: kb/s:999.22
-[NoImage] encoded 3200 frames, 2.39 fps, 999.26 kb/s
-[NoImage] x264 [info]: ended at Thu Feb 03 12:41:32 2011
-[NoImage] x264 [info]: encoding duration 0:22:22

encode2:

[Information] Standard error stream
-[NoImage] raw [info]: 712x480p 1:1 @ 24000/1001 fps (cfr)
-[NoImage] x264 [info]: using SAR=1/1
-[NoImage] x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
-[NoImage] x264 [info]: profile High, level 4.1
-[NoImage] x264 [info]: cabac=1 ref=16 deblock=1:-2:-2 analyse=0x3:0x133 me=tesa subme=10 psy=1 fade_compensate=0.00 psy_rd=1.00:0.00 mixed_ref=1 me_range=64 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=-2 threads=12 sliced_threads=0 nr=0 decimate=0 interlaced=0 constrained_intra=0 bframes=16 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=240 keyint_min=24 scenecut=40 intra_refresh=0 rc=2pass mbtree=0 bitrate=1000 ratetol=1.0 qcomp=0.80 qpmin=0 qpmax=69 qpstep=4 cplxblur=20.0 qblur=0.5 ip_ratio=1.30 pb_ratio=1.30 aq=1:0.70
-[NoImage] x264 [info]: started at Thu Feb 03 13:30:20 2011
-[NoImage]
-[NoImage] x264 [info]: frame I:31 Avg QP:18.30 size: 58564
-[NoImage] x264 [info]: frame P:726 Avg QP:21.15 size: 13140
-[NoImage] x264 [info]: frame B:2443 Avg QP:23.06 size: 2176
-[NoImage] x264 [info]: consecutive B-frames: 3.0% 6.3% 7.9% 12.8% 14.4% 41.3% 10.1% 1.5% 1.4% 0.3% 0.0% 1.1% 0.0% 0.0% 0.0% 0.0% 0.0%
-[NoImage] x264 [info]: mb I I16..4: 1.7% 74.0% 24.3%
-[NoImage] x264 [info]: mb P I16..4: 0.3% 3.9% 0.9% P16..4: 58.9% 24.9% 6.8% 0.4% 0.3% skip: 3.6%
-[NoImage] x264 [info]: mb B I16..4: 0.0% 0.1% 0.0% B16..8: 33.6% 5.4% 1.4% direct: 3.4% skip:56.1% L0:40.9% L1:48.3% BI:10.8%
-[NoImage] x264 [info]: 8x8 transform intra:74.9% inter:58.1%
-[NoImage] x264 [info]: direct mvs spatial:98.4% temporal:1.6%
-[NoImage] x264 [info]: coded y,uvDC,uvAC intra: 94.6% 87.7% 65.1% inter: 18.4% 15.7% 5.4%
-[NoImage] x264 [info]: i16 v,h,dc,p: 14% 24% 15% 48%
-[NoImage] x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 6% 14% 6% 10% 13% 9% 14% 9% 19%
-[NoImage] x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 7% 11% 3% 11% 14% 11% 15% 11% 18%
-[NoImage] x264 [info]: i8c dc,h,v,p: 40% 32% 14% 14%
-[NoImage] x264 [info]: Weighted P-Frames: Y:19.7% UV:6.2%
-[NoImage] x264 [info]: ref P L0: 47.3% 18.3% 15.1% 6.0% 3.8% 2.6% 2.1% 1.1% 0.9% 0.7% 0.6% 0.5% 0.4% 0.3% 0.3% 0.1%
-[NoImage] x264 [info]: ref B L0: 72.5% 15.6% 5.1% 2.1% 1.4% 1.0% 0.8% 0.4% 0.3% 0.2% 0.2% 0.2% 0.1% 0.1% 0.0%
-[NoImage] x264 [info]: ref B L1: 93.2% 6.8%
-[NoImage] x264 [info]: kb/s:999.24
-[NoImage] encoded 3200 frames, 2.33 fps, 999.28 kb/s
-[NoImage] x264 [info]: ended at Thu Feb 03 13:53:14 2011
-[NoImage] x264 [info]: encoding duration 0:22:54

encode3:

[Information] Standard error stream
-[NoImage] raw [info]: 712x480p 1:1 @ 24000/1001 fps (cfr)
-[NoImage] x264 [info]: using SAR=1/1
-[NoImage] x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
-[NoImage] x264 [info]: profile High, level 4.1
-[NoImage] x264 [info]: cabac=1 ref=16 deblock=1:-2:-2 analyse=0x3:0x133 me=tesa subme=10 psy=1 fade_compensate=0.00 psy_rd=1.00:0.00 mixed_ref=1 me_range=64 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=-2 threads=12 sliced_threads=0 nr=0 decimate=0 interlaced=0 constrained_intra=0 bframes=16 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=240 keyint_min=24 scenecut=40 intra_refresh=0 rc=2pass mbtree=0 bitrate=1000 ratetol=1.0 qcomp=0.80 qpmin=0 qpmax=69 qpstep=4 cplxblur=20.0 qblur=0.5 ip_ratio=1.10 pb_ratio=1.10 aq=1:0.90
-[NoImage] x264 [info]: started at Thu Feb 03 14:50:53 2011
-[NoImage]
-[NoImage] x264 [info]: frame I:31 Avg QP:20.41 size: 45610
-[NoImage] x264 [info]: frame P:726 Avg QP:21.98 size: 11055
-[NoImage] x264 [info]: frame B:2443 Avg QP:21.78 size: 2961
-[NoImage] x264 [info]: consecutive B-frames: 3.0% 6.3% 7.9% 12.8% 14.4% 41.3% 10.1% 1.5% 1.4% 0.3% 0.0% 1.1% 0.0% 0.0% 0.0% 0.0% 0.0%
-[NoImage] x264 [info]: mb I I16..4: 2.8% 72.7% 24.5%
-[NoImage] x264 [info]: mb P I16..4: 0.3% 3.8% 0.9% P16..4: 60.7% 23.3% 5.7% 0.3% 0.2% skip: 4.8%
-[NoImage] x264 [info]: mb B I16..4: 0.0% 0.1% 0.0% B16..8: 33.5% 6.8% 1.7% direct: 5.1% skip:52.8% L0:41.4% L1:48.7% BI:10.0%
-[NoImage] x264 [info]: 8x8 transform intra:74.1% inter:57.8%
-[NoImage] x264 [info]: direct mvs spatial:97.5% temporal:2.5%
-[NoImage] x264 [info]: coded y,uvDC,uvAC intra: 93.3% 84.8% 57.4% inter: 20.3% 16.1% 4.2%
-[NoImage] x264 [info]: i16 v,h,dc,p: 13% 25% 13% 49%
-[NoImage] x264 [info]: i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 5% 13% 5% 10% 13% 10% 15% 10% 19%
-[NoImage] x264 [info]: i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 6% 10% 3% 11% 14% 11% 15% 11% 18%
-[NoImage] x264 [info]: i8c dc,h,v,p: 38% 33% 15% 14%
-[NoImage] x264 [info]: Weighted P-Frames: Y:19.7% UV:6.2%
-[NoImage] x264 [info]: ref P L0: 47.8% 18.3% 14.9% 5.8% 3.7% 2.6% 2.1% 1.1% 0.9% 0.7% 0.6% 0.5% 0.4% 0.3% 0.3% 0.2%
-[NoImage] x264 [info]: ref B L0: 71.6% 15.6% 5.3% 2.2% 1.5% 1.2% 0.9% 0.4% 0.3% 0.3% 0.2% 0.2% 0.1% 0.1% 0.0%
-[NoImage] x264 [info]: ref B L1: 92.8% 7.2%
-[NoImage] x264 [info]: kb/s:999.36
-[NoImage] encoded 3200 frames, 2.30 fps, 999.40 kb/s
-[NoImage] x264 [info]: ended at Thu Feb 03 15:14:03 2011
-[NoImage] x264 [info]: encoding duration 0:23:10

LoRd_MuldeR
3rd February 2011, 16:48
My question is regarding the encode stats, i have encoded the same clip with 3 diferent settings at the same bitrate, how do i know with was the best for my source?

...by looking at the output and deciding which encode looks most pleasing to your eyes. The stats (alone) can't help you to find the optimal settings for your source!

(The stats would have told you which encoded is the closest to the source with respect to PSNR or SSIM, if you had used "--ssim" or "--psnr". Not that PSNR/SSIM tells you much about the overall quality!)

nm
3rd February 2011, 16:48
i have encoded the same clip with 3 diferent settings at the same bitrate, how do i know with was the best for my source? whith setting kept more detail. what do i have to compare?

Your eyes. Nothing in the stats tells much about visual quality one way or the other.

For checking non-obvious details, use AviSynth to interleave the streams and then play the script frame by frame.

egrimisu
3rd February 2011, 16:51
Your eyes. Nothing in the stats tells much about visual quality one way or the other.

For checking non-obvious details, use AviSynth to interleave the streams and then play the script frame by frame.

that is what i've done till now, but i was thinking that there is another way.

and then what's the reason of stats? developer usage?

poisondeathray
3rd February 2011, 16:52
But the stats do indicate you're wasting time. 16 b-frames was entered , but they only go up to 11 consecutive in use on that source with those settings used

egrimisu
3rd February 2011, 17:29
But the stats do indicate you're wasting time. 16 b-frames was entered , but they only go up to 11 consecutive in use on that source with those settings used

yes i use ref=16 ,why shall i use 11 instead?

poisondeathray
3rd February 2011, 17:42
yes i use ref=16 ,why shall i use 11 instead?

because you're not using anymore than that under these conditions. The number starts off with zero - so 0 bframes 3.0%, 1 bframe 6.3% etc.....


-[NoImage] x264 [info]: consecutive B-frames: 3.0% 6.3% 7.9% 12.8% 14.4% 41.3% 10.1% 1.5% 1.4% 0.3% 0.0% 1.1% 0.0% 0.0% 0.0% 0.0% 0.0%



You can read more about it here:
http://forum.doom9.org/showthread.php?t=129491
http://mewiki.project357.com/wiki/X264_Stats_Output

nm
3rd February 2011, 17:48
yes i use ref=16 ,why shall i use 11 instead?

Note that poisondeathray is talking about b-frames, not reference frames.

poisondeathray
3rd February 2011, 17:51
^yep thanks for clarification :)

laserfan
3rd February 2011, 18:02
For checking non-obvious details, use AviSynth to interleave the streams and then play the script frame by frame.
I wonder if you (or anyone) might share your method for doing this; by "interleaving" I assume you mean something different from just displaying different scripts side-by-side?

poisondeathray
3rd February 2011, 18:08
I wonder if you (or anyone) might share your method for doing this; by "interleaving" I assume you mean something different from just displaying different scripts side-by-side?

it alternates frames from 1 encode to the other. This way it's easy to compare in avsp or vdub, and step through frame by frame

it helps to label them e.g. using subtitle()

video a frame 0, video b frame 0, video a frame 1, video b frame 1, etc...

e.g.

a=ffvideosource("videoa.mkv").subtitle("a")
b=ffvideosource("videob.mkv").subtitle("b")
interleave(a,b)

nm
3rd February 2011, 18:09
I wonder if you (or anyone) might share your method for doing this; by "interleaving" I assume you mean something different from just displaying different scripts side-by-side?

Yep. I mean sequential interleaving, which makes it much easier to spot differences:


LoadPlugin("ffms2.dll")

clip1=FFVideoSource("video1.mp4")
clip2=FFVideoSource("video2.mp4")

# Add titles to see which frame comes from which source
clip1=clip1.subtitle("video1", size=32, align=9)
clip2=clip2.subtitle("video2", size=32, align=9)

interleave(clip1,clip2)

ajp_anton
3rd February 2011, 18:20
But the stats do indicate you're wasting time. 16 b-frames was entered , but they only go up to 11 consecutive in use on that source with those settings usedI'd say they only go up to 6. Above that it's all <2%, and 11 vs 10 is a much smaller difference than 7 vs 6.
Note that poisondeathray is talking about b-frames, not reference frames.Though he's also using an unnecessary amount of refs too.

That's the kind of info you get from the encoding stats - info about the actual encode process. Not about the quality of the result.

poisondeathray
3rd February 2011, 18:25
I'd say they only go up to 6. Above that it's all <2%, and 11 vs 10 is a much smaller difference than 7 vs 6.

Well they go up to 11, but I agree with what you trying to say. It's not worth it for a few % . But he's using "crazy" settings like 16 ref , me range 64, me tesa.

You could make that same argument for reference frames - not worth it IMO

laserfan
3rd February 2011, 19:12
Thanks a lot PDR and nm for the ideas about interleaving; verry inneresting, I will try it! :)

:thanks:

egrimisu
3rd February 2011, 21:43
since you guys say that it does not worth it, ill try lowering the settings, anyway a dvd resolution film with ivtc is encoding at 2 fps with my above x264 settings, so that's not that bad :)

Well they go up to 11, but I agree with what you trying to say. It's not worth it for a few % . But he's using "crazy" settings like 16 ref , me range 64, me tesa.

You could make that same argument for reference frames - not worth it IMO

egrimisu
3rd February 2011, 21:46
another thing , it is better to use converttoyv12() in the avisynth script if encoding with x264? or it does not matter

LoRd_MuldeR
3rd February 2011, 21:55
another thing , it is better to use converttoyv12() in the avisynth script if encoding with x264? or it does not matter

x264 exclusively supports YUV 4:2:0 (YV12).

If your source already is YUV 4:2:0, then ConvertToYV12() is a NOP. Otherwise it does the conversion that is unavoidably anyway.

You can feed x264 with RGB32 or YUY2 (YUV 4:2:2), but then it will do the required conversion to YV12 internally...

egrimisu
5th February 2011, 14:39
Well that's strange, i encoded a clip with x264 and was 333mb and then again but i added ConvertToYV12() at the end and that one was 330mb. how's that? is the Convertert built in x264 diferent than the one in avisynth?

x264 exclusively supports YUV 4:2:0 (YV12).

If your source already is YUV 4:2:0, then ConvertToYV12() is a NOP. Otherwise it does the conversion that is unavoidably anyway.

You can feed x264 with RGB32 or YUY2 (YUV 4:2:2), but then it will do the required conversion to YV12 internally...

LoRd_MuldeR
5th February 2011, 15:20
If you used either VBV or the "--non-deterministic" option, then x264 isn't deterministic (http://forum.doom9.org/showpost.php?p=1385217&postcount=303) anyway!

This means that you won't get the 100% identical results from several runs, even if all the settings and the input (source) were 100% identical on each run.

(After all the difference in size of your second encode is less than 1% compared to the first encode, which might very well be explained that way)

egrimisu
6th February 2011, 10:36
well, that's strager now, i remember making 2 encodes using your encoding tool, with the same settings, and i wasn't using no exotic settings. the resulting 2 files were perfectly identical.

If you used either VBV or the "--non-deterministic" option, then x264 isn't deterministic (http://forum.doom9.org/showpost.php?p=1385217&postcount=303) anyway!

This means that you won't get the 100% identical results from several runs, even if all the settings and the input (source) were 100% identical on each run.

(After all the difference in size of your second encode is less than 1% compared to the first encode, which might very well be explained that way)

nm
6th February 2011, 10:52
well, that's strager now, i remember making 2 encodes using your encoding tool, with the same settings, and i wasn't using no exotic settings. the resulting 2 files were perfectly identical.

With VBV?

is the Convertert built in x264 diferent than the one in avisynth?

There may be small differences between libswscale and AviSynth output.

Blue_MiSfit
6th February 2011, 11:39
I'd suggest doing the YV12 conversion in AviSynth. It's a bit faster in my experience. Take that with a grain of salt, though ;)

At the very least, doing ConvertToYV12 lets you specify the matrix used.

Derek

LoRd_MuldeR
6th February 2011, 14:54
well, that's strager now, i remember making 2 encodes using your encoding tool, with the same settings, and i wasn't using no exotic settings. the resulting 2 files were perfectly identical.

If you didn't explicitly add "--vbv-maxrate" and "--vbv-buffsize" then you didn't use VBV and thus x264 was deterministic (unless you explicitly specified "--non-deterministic").

Moreover if a software is non-deterministic, then this doesn't mean that you'll necessarily get different output from each run. It just means that you aren't guaranteed to get identical output from each run.

So if you do get identical output from several runs, this might just have happened by chance. And therefore you can't rely on this behavior for future runs...

egrimisu
6th February 2011, 23:50
if i usualy compres dvd's to i need to specific any matrixes? colors paletes, color lovels and uisually colors are things that are beyond me, i just don't have the eyes for it ;)

Shall i use converttoyv2() at the beginig of the script or at the botom, if the filteres used can handle yv12 (when i say handle it means that it does not return any error)


I'd suggest doing the YV12 conversion in AviSynth. It's a bit faster in my experience. Take that with a grain of salt, though ;)

At the very least, doing ConvertToYV12 lets you specify the matrix used.

Derek

nm
7th February 2011, 12:19
if i usualy compres dvd's to i need to specific any matrixes?

You may want to convert to Rec.601 if you encode to SD resolutions, or at least flag the output correctly. DVDs use different matrices and the correct one is flagged in the stream. Use ColorMatrix (http://avisynth.org.ru/docs/english/externalfilters/colormatrix.htm) for conversions.

DVDs are already YV12, so you don't need ConvertToYV12.

egrimisu
11th February 2011, 22:05
So this is whaty i'm after ?
ColorMatrix(hints=true, interlaced=true)

How do i know if the dvd is rec601 or rec709?

You may want to convert to Rec.601 if you encode to SD resolutions, or at least flag the output correctly. DVDs use different matrices and the correct one is flagged in the stream. Use ColorMatrix (http://avisynth.org.ru/docs/english/externalfilters/colormatrix.htm) for conversions.

DVDs are already YV12, so you don't need ConvertToYV12.

nm
11th February 2011, 22:29
How do i know if the dvd is rec601 or rec709?
Read the documentation through, especially the part about the hints parameter. It suggest using Mpeg2Source("input.d2v", info=3) for automatic detection. Some DVDs could be flagged wrong though.

egrimisu
12th February 2011, 00:50
and what if i use dgsource? looked trough manuak there's no setting for colormetry.

LoRd_MuldeR
12th February 2011, 01:38
and what if i use dgsource? looked trough manuak there's no setting for colormetry.

http://img16.imageshack.us/img16/8074/clipboard30q.th.png (http://img16.imageshack.us/img16/8074/clipboard30q.png)

egrimisu
12th February 2011, 02:04
http://img16.imageshack.us/img16/8074/clipboard30q.th.png (http://img16.imageshack.us/img16/8074/clipboard30q.png)

Thanks lord, now what ? :D

http://img15.imageshack.us/img15/2642/colormetry.jpg

nm
12th February 2011, 11:55
Thanks lord, now what ? :D

No need to to do anything for that stream but flag the final encoded output as Rec.601.

BT.601 is an update to BT.470-2 and they have the same colorimetry.

egrimisu
12th February 2011, 13:05
Thanks nm, how exaclty to flag? i have read the colormatrix documentation but it does not containt any "flag" word. My english is not that good and i don't understand what do you want to say by flaging! Thanks

No need to to do anything for that stream but flag the final encoded output as Rec.601.

BT.601 is an update to BT.470-2 and they have the same colorimetry.

LoRd_MuldeR
12th February 2011, 13:10
You don't need to apply the ColorMatrix() function. This would be a way to convert the colorimetry.

However you can just keep the colorimetry "as-is" and simply flag the encoded H.264 stream as BT.601 (BT.470). That's it!

It's just a meta information ("flag"), which will tell the decoder the correct colorimetry of the stream...

egrimisu
12th February 2011, 13:17
you mean by addin --colormatrix bt470bg to the x264 encode parameters?

You don't need to apply the ColorMatrix() function. This would be a way to convert the colorimetry.

However you can just keep the colorimetry "as-is" and simply flag the encoded H.264 stream as BT.601 (BT.470). That's it!

It's just a meta information ("flag"), which will tell the decoder the correct colorimetry of the stream...

LoRd_MuldeR
12th February 2011, 13:22
you mean by addin --colormatrix bt470bg to the x264 encode parameters?

I think so. But actually I'm not quite sure what the difference between "--colorprim", "--transfer" and "--colormatrix" is. The BluRay guide recommend setting all three parameters though.

egrimisu
13th February 2011, 12:50
Anyone have an ideea how to propely flag the colomatrix?

I think so. But actually I'm not quite sure what the difference between "--colorprim", "--transfer" and "--colormatrix" is. The BluRay guide recommend setting all three parameters though.

nm
13th February 2011, 13:07
Anyone have an ideea how to propely flag the colomatrix?

I think you can safely set all three parameters to the same value: smpte170m for NTSC or bt470bg for PAL. This is what the Blu-ray guide (http://sites.google.com/site/x264bluray/home) suggests too.

Also see this thread: http://forum.doom9.org/showthread.php?p=1450343#post1450343