Press "Enter" to skip to content

Posts tagged as “nikon”

Nikon Z8/Z9 HLG Deepdive | HLG 详解 VS N-LOG

网上关于HLG的资料相对来说还是比较匮乏的,更别说是针对Nikon Z系列了。之前做过一期简单的HLG直出视频,但是没人感兴趣…

首先HLG是一条用于交付的Gamma曲线,向下兼容SDR内容,这也就注定了它的上限比较低,这也是为什么大部分人对它不感兴趣的原因(另一个原因是它是HDR)。HLG的动态范围(尤其高光)比不过N-LOG,更别说Slog3了。暗部表现则比其他LOG曲线要好一些。它最大的优点就是所见即所得,不需要LUT还原,也(基本)不需要向右曝光,特别适合HDR直出。不过如果你只做SDR的话,还是选N-LOG吧。只是2025年了,拍N-LOG/NRAW获得12+档动态范围,然后再压缩到8档,我只能说历史的包袱太沉重了。可以参见:再谈苹果XDR显示器与HDR之殇

响应曲线

我在Z8上实测响应曲线,测试方法:调整曝光,记录不同曝光值下中灰的IRE,并和理论值做对比。为了统一起见,我将中灰(Stop 0)都曝光到36%。Note: HLG中灰的理论值应该是38%,不过差别不大,大概0.2档左右。结果实测N-LOG的时候,同样用了95 (37.2%)的斑马线,最后得到的曝光是38%,不管了,差不多就行了。

Z8 HLG实测曲线和理论曲线在[-7, +3]的范围内贴合的非常不错。实测的HLG底噪大约是3%,。两者在高光部分差别比较大,HLG中灰以上一档就开始变成对数曲线,和Stops应该是线性关系,但实测下来,Nikon对+3档以上的高光做了一些保护,曲线非常平滑,因此也比理论多了1档的高光,中灰以上5.3档才会完全过曝。 但比起N-LOG还是差了一档多。另外HLG模式下,IRE最大值不是100,而是97左右,斑马线需要设置在245才会有效果。

N-LOG的曲线大致上贴合的还是不错的。noise floor,13%左右。-7档开始就贴着了。只有在+1档到+2档的附近有点波动。高光部分的斜率还是太大了,竟然比理论值还大一些。中灰以上6档就过曝了。只比HLG好了不到1档。

名义ISO

众所周知,N-LOG的基础ISO是800,第二档则是ISO 4000。HLG的基础ISO是400,第二档是ISO 2000。无论是N-LOG还是HLG,它们的ISO都是名义ISO,或者说等效ISO。在相同照度下,我使用相同的参数(1/400s F/4 ISO800)拍摄灰卡,N-LOG和HLG的IRE是36%左右,SDR则为52%。三者还原之后中灰的亮度大体上相同(SDR稍微亮了一点),证实了”名义”ISO。但实际上传感器使用的ISO是多少呢?其实都是ISO 100左右,如何证明呢?拍摄同样的白卡,记录刚刚过曝时的曝光参数。
N-LOG: 1/30s F/4 ISO 800
HLG: 1/30s F/4 ISO 400
SDR: 1/30s F/4 ISO 80 (NL profile, Active D-lighting off)
进光量相同,传感器同时过曝了,表明实际ISO是相同的。
等效ISO也可以这么理解:
N-LOG拍摄时欠曝3档,后期还原时把中灰提亮3档,以起到保护高光的目的。
HLG拍摄时欠曝2档,后期还原时把中灰提亮2档,以起到保护高光的目的。
这也就是为什么按照标准曝光(将中灰曝到36% IRE),N-LOG暗部噪点爆炸,需要使用向右曝光的原因之一。
HLG则相当于找了一个平衡点,欠曝2档,等效于使用ISO 400拍视频,对于全画幅来说勉强可以接受吧。

HLG quality 设置

由于是面向直出的交付曲线,只有H.265编码支持HLG。虽然Nikon贴心的提供了HLG质量选项,但这里有个坑,在默认的设置下,相机是会对HLG的画面进行锐化的,导致使用超级锐的Z卡扣镜头时会产生过度锐化的情况。需要将Quick Sharp设置成-1才能获得未锐化的画面。有需要的话,也可以将对比度和饱和度也降低一些,推荐-1。

不同Quick Sharp模式下的波形图

调整对比度

调整饱和度

Nikon Z8 HLG / N-Log Stops vs IRE

Recently I switched from N-RAW to H.265 / HLG for quicker HDR workflow in Final Cut Pro, basically just drop the clips in a HLG timeline and that’s it, just like the iPhone’s Dolby Vision (HLG HDR) footage.

I did some test about IRE vs stops in HLG mode and compared that to the theoretical N-Log curve.

Setup: I expouse the 18% midgray to 36% IRE in HLG mode to match that with N-Log. Adjust the exposure time first then aperture, ISO to over and under expose the midgray for IRE readings.

Note: Techincally, you should expose midgray to 38% IRE in HLG mode (ref), diffuse white will be around 75% IRE, 75%+ is for specular highlights (0~3 stops over diffuse white).

Stops vs IRE

First of all, we can see that HLG curve is more contrastive than N-Log. Highlights will be clipped after 5 stops over midgray which I think is OK for a lot of scences. N-Log retains more infornation in the highlights (if not over-exposed) up to 6.3 stops at the cost of noiser shadows. HLG has more detials in the shadow area, noise floor is about 2% at ISO 400 (12.5% for N-Log).

Another thing intresting is that the HLG curve is very steep from -1 to +3 stops but quickly saturated afterwards (non-linear anymore), highlights are compressed and will clipped around 96% IRE, making sure to set the high zebra to 245 when shooting HLG.

Base ISO for HLG and N-Log

Nikon Z8’s HLG has a “nominal” base ISO 400. Under the hood, the sensor is working at ISO 100, shadows will be boosted by 2 stops while highlights will be intact, bascially you are shooting at ISO 100 with 2 stops under to protect highlights.

N-Log has a “nominal” base ISO 800. Same as HLG, the sensor is working at ISO 100, shadows will be boosted by 3 stops while highlights will be intact, bascially you are shooting at ISO 100 with 3 stops under to protect highlights. However, you will see a lot of noise in shadow area due to insufficient light and 1.3 ~ 1.7 stops “over-exposure” is usually needed to compensate that to get clean image.

Consolution

HLG has a pretty good balance between highlights and shadows, very user friendly for HDR workflow. Unlike N-Log, there is no need to over-expose (even 1 stop under looks good to me), no camera LUT needed for restoration, zero or minimum color grading needed. Another advantage of HLG over N-Log is monitoring, most of the time you can rely on the screen/viewfinder (with zebra on) to adjust the exposure and only open the waveform if needed.

Nikon Z8/Z9 Video Format / Bitrate / Compression ratio | NRAW | ProRes | ProRes RAW | H.265

The Nikon official site didn’t provide the birate for ProRes / ProRes RAW, I did some test my self, here’re the results. I only tested fullframe (FX) in ~4K resolution.

ProRes Raw 12Bit

Resolution / FPSBitrate (Mbps)Compression Ratio
4140 x 2330 60p33501.977
4140 x 2330 50p28101.964
4140 x 2330 30p16202.044
4140 x 2330 25p13602.029
4140 x 2330 24p12802.070

ProRes Raw has a very low compression ratio of 2, which suggests that it might be lossless compressed, which takes more spaces than Nikon’s lossy N-RAW, 2.5x of the high quality and 4.5x of the normal quality!

ProRes HQ 422 10Bit

Resolution / FPSBitrate (Mbps)Compression Ratio
3840 x 2160 60p18005.273
3840 x 2160 50p15005.273
3840 x 2160 30p9105.215
3840 x 2160 25p7605.204
3840 x 2160 24p7305.201

With compression ratio of 5.2, ProRes is still 2x the size of the normal quality n-raw! Though the former one has 1.5x number of pixels to deal with (YUV422 vs Bayer).

I hope Nikon could provide more options for ProRes via firmware updates. A 10x~12x compression ratio version (ProRes LT 422) will be very useful to balance between quality and disk space.

H.265 420 10 bit

Resolution / FPSBitrate (Mbps)Compression Ratio
7680 x 4320 30p40047.461
7680 x 4320 25p40039.551
7680 x 4320 24p40037.969
3840 x 2160 120p40047.461
3840 x 2160 100p40039.551
3840 x 2160 60p34027.918
3840 x 2160 50p34023.265
3840 x 2160 30p19024.979
3840 x 2160 25p19020.816
3840 x 2160 24p19019.984

For H.265, there is no option for all-intra, and only in 420. Compression ratio is much higher given long GOP. One thing to note, that bitrate is variable depend on the content, i.e. very dark scene will have a much lower bitrate (<100Mbps for 4K60).

NRAW High Quality 12 bit

Resolution / FPSBitrate (Mbps)Compression Ratio
8256 x 4644 60p57804.555
8256 x 4644 50p48104.561
8256 x 4644 30p28904.555
8256 x 4644 25p24104.552
8256 x 4644 24p23104.559
4128 x 2322 120p38403.428
4128 x 2322 100p29003.783
4128 x 2322 60p17403.783
4128 x 2322 50p14503.783
4128 x 2322 30p8703.783
4128 x 2322 25p7303.757
4128 x 2322 24p7003.761

First of all, given 4.5 compression ratio, NRAW is definitely a lossy codec. Interesting thing is that 8K’s compression ratio is higher than 4K’s. 4.5 vs 3.7.

NRAW Normal Quality 12 bit

Resolution / FPSBitrate (Mbps)Compression Ratio
8256 x 4644 60p34707.587
8256 x 4644 50p28907.591
8256 x 4644 30p17407.565
8256 x 4644 25p14507.565
8256 x 4644 24p13907.576
4128 x 2322 120p17507.522
4128 x 2322 100p14607.513
4128 x 2322 60p8807.479
4128 x 2322 50p7307.513
4128 x 2322 30p4407.479
4128 x 2322 25p3707.412
4128 x 2322 24p3507.522

For normal quality, the compression ratio is even higher, reaching 7.5:1 which is not bad for all-intra.