News for hackers. Stuff that matters.
Re:Support HDR images in your app [video] by crazygringo on Friday October 06, 2023 @02:21PM (#37794259)
Not just monitors but video players too.

Trying to play HDR content on a regular SDR screen is a mess.

If you rip an HDR version of a movie:

- VLC does nothing. It shows it as so dark it's unwatchable

- IINA shows it as brightness comparable to an SDR version of the movie, but with a weird green tint

- QuickTime is weirdly in-between, brighter than VLC but not as bright as an SDR version

- Infuse got fixed this year so that it plays HDR content to visually match the SDR version of the same content on a SDR screen (the only player I've found that can on Macs)

And if you want to convert your file in ffmpeg, good luck. I still haven't found the magic settings that reverses whatever entertainment studios are doing to translate their SDR into HDR. (The magic settings that Infuse has somehow figured out.) There's no flag or setting for it -- you have to input a bunch of custom values.

Re:Support HDR images in your app [video] by zimpenfish on Friday October 06, 2023 @02:40PM (#37794530)
I can't remember where I found this but it's what I've been using to downscale and convert the occasional 10bit downloads (using the nvenc GPU acceleration.)

    ffmpeg -hide_banner -y -probesize 100M -i "$file" -map 0:v:0 -c:v h264_nvenc -x264-params b_pyramid=2:ref=4:vbv-maxrate=30000:vbv-bufsize=15000 -refs 4
 -crf 17 -preset:v fast -profile:v high -b_strategy 2 -rc-lookahead 900 -level 4.1 -pix_fmt yuv420p -color_range 1 -colorspace 1 -color_primaries bt709 -color_trc bt709 -subq 10 -vf zscale=tin=smpte2084:min=bt2020nc:pin=bt2020:rin=tv:t=smpte2084:m=bt2020nc:p=bt2020:r=tv,zscale=t=linear,format=gbrpf32le,zscale=p=bt709,tonemap=tonemap=hable:desat=0,zscale=t=bt709:m=bt709:r=tv,format=yuv420p,zscale=s=1280x720 -c:a copy output.mkv
Re:Support HDR images in your app [video] by PaulBGD_ on Friday October 06, 2023 @02:36PM (#37794467)
Plex does a fairly good conversion too, iirc using ffmpeg.
Re:Support HDR images in your app [video] by lldb on Friday October 06, 2023 @02:29PM (#37794384)
mpv with --tone-mapping=bt.2446a (or whichever you like from https://mpv.io/manual/stable/#options-tone-mapping), --hdr-compute-peak=yes, and --target-peak=SDR monitor nits, does the best I've seen yet.
Re:Support HDR images in your app [video] by radicality on Friday October 06, 2023 @07:29PM (#37797634)
I haven’t tried it yet (since it’s quite expensive at $99 for a video player), but I read good things about Screen. https://videovillage.com/screen/