<p>First of all there is a bug in ffmpeg swscale that saves 16 bit per 3 component PNG, so use zscale instead.</p>
<p><a href="https://trac.ffmpeg.org/ticket/7978#comment:7" rel="nofollow noreferrer">https://trac.ffmpeg.org/ticket/7978#comment:7</a></p>
<p>ffmpeg -i PQ_HDR_file.mp4 -vf zscale=matrixin=2020_ncl,format=gbrp16le -an -frames:v 1 out_zscale.png</p>
<p>This will get you correct image (bt.2020-ncl matrix is removed correctly to R'G'B'). You still should present the file on HDR display since it will have PQ transfer (PQ is why you saw the gray image originally) and BT.2020 primaries. You may want to tag the file.</p>

CC BY-SA 4.0
2021-09-10T05:54:42.880Z
2021-09-10T05:54:42.880Z
Валерий Заподовников
<p>I tried both vlc and virtuadub2, they both save out washed out images. Both show and save out washed out images.</p>
<p>How can I save out these images so they look in proper HDR space?</p>

<ffmpeg><export><vlc><hdr>
How to save HDR 10 bit MKV videos as an image sequence?
Leon
# How to save HDR 10 bit MKV videos as an image sequence?

(Asked by: username_0 on 2020-10-03)

I tried both vlc and virtuadub2, they both save out washed out images. Both show and save out washed out images.

How can I save out these images so they look in proper HDR space?

**Tags:** ffmpeg, export, vlc, hdr


---

## 1 answers

### Answer by username_1 on 2021-09-10. Score: 0

First of all there is a bug in ffmpeg swscale that saves 16 bit per 3 component PNG, so use zscale instead.

<https://trac.ffmpeg.org/ticket/7978#comment:7>

ffmpeg -i PQ\_HDR\_file.mp4 -vf zscale=matrixin=2020\_ncl,format=gbrp16le -an -frames:v 1 out\_zscale.png

This will get you correct image (bt.2020-ncl matrix is removed correctly to R'G'B'). You still should present the file on HDR display since it will have PQ transfer (PQ is why you saw the gray image originally) and BT.2020 primaries. You may want to tag the file.


---

