Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Niklas Haas <ffmpeg@haasn.xyz>
To: Sarthak Indurkhya via ffmpeg-devel <ffmpeg-devel@ffmpeg.org>,
	FFmpeg development discussions and patches
	<ffmpeg-devel@ffmpeg.org>
Cc: Sarthak Indurkhya <sindurkhya@adobe.com>
Subject: Re: [FFmpeg-devel] [PATCH] avfilter: add inverse tone mapping
Date: Wed, 23 Jul 2025 11:41:32 +0200
Message-ID: <20250723114132.GB12433@haasn.xyz> (raw)
In-Reply-To: <BN0PR02MB78872FAD1678F4CF1B3C84A0D45FA@BN0PR02MB7887.namprd02.prod.outlook.com>

On Wed, 23 Jul 2025 05:30:57 +0000 Sarthak Indurkhya via ffmpeg-devel <ffmpeg-devel@ffmpeg.org> wrote:
> Thank you for the thoughtful feedback.
>
> Advantages over vf_libplacebo’s inverse tone mapping:
>
>   1.  Algorithmic Differentiation:
> My filter is based on a novel local adaptation + inverse tone mapping strategy specifically tailored to enhance perceptual brightness while preserving spatial detail.
>
>        My implementation uses:
>
>      *   Local bilateral filtering over luminance for content-adaptive scaling.
>      *   Dynamic inverse tone mapping via (R / (1 - R))^1/n style reparameterization.
>      *   Chromatic scaling to preserve original hues during dynamic range expansion.
>   1.  Color Fidelity & HDR Metadata:
>      *   The filter performs color space conversion from BT.709 to BT.2020 explicitly and integrates PQ transfer function encoding with full support for mastering metadata (mastering_display_primaries, content_light_level, etc.).
>      *   It incorporates localized tone curve shaping, white balance, and chroma boosting that target HDR presentation aesthetics more directly.
>   2.  Customizability:
>      *   Parameters like sigma_spatial, sigma_range, n, and hdr_max allow users to tailor the HDR expansion according to scene content or output requirements.

None of that sounds different from what vf_libplacebo is doing. Do you have
an example output somewhere that we could compare?

>
> I agree that a GPU-based real-time implementation would be valuable. The algorithm I've used is highly parallelizable and very well-suited for implementation as a GPU shader
>
>
> Get Outlook for Mac <https://aka.ms/GetOutlookForMac>
>
> From: ffmpeg-devel <ffmpeg-devel-bounces@ffmpeg.org> on behalf of Kacper Michajlow <kasper93@gmail.com>
> Date: Saturday, 19 July 2025 at 8:18 PM
> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH] avfilter: add inverse tone mapping
> EXTERNAL: Use caution when clicking on links or opening attachments.
>
>
> On Sat, 19 Jul 2025 at 16:13, Sarthak Indurkhya via ffmpeg-devel <
> ffmpeg-devel@ffmpeg.org> wrote:
>
> > Hello FFmpeg developers,
> > This patch introduces a new video filter called inversetonemap for FFmpeg.
> > The filter performs SDR to HDR conversion by mapping SDR BT.709 video to
> > HDR BT.2020 PQ, using local adaptation and inverse tone mapping. The goal
> > is to provide a simple, flexible tool for upconverting SDR content for HDR
> > displays, with local adaptation, tone curve sensitivity, and chroma
> > processing.
> >
> > Please review.
> > Thanks,
> > Sarthak
> >
> >
> >
> Interesting. Could you describe what are the advantages of the new filter,
> compared to existing solutions like vf_libplacebo inverse tone mapping?
> Additionally if there is a big gap in libplacebo's inverse tone mapping
> quality would you be interested in improving the libplacebo implementation
> in addition to this filter? I think there would be a gain in having real
> time gpu implementation too.
>
> - Kacper
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fffmpeg.org%2Fmailman%2Flistinfo%2Fffmpeg-devel&data=05%7C02%7Csindurkhya%40adobe.com%7Cae51c0c89a19441126c408ddc6d348ef%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C638885332956664603%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=c7Ot4ow8uXKRfk%2F05O9B5bCkxjynTUwg90S%2Bf5uJeYU%3D&reserved=0<https://ffmpeg.org/mailman/listinfo/ffmpeg-devel>
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

  reply	other threads:[~2025-07-23  9:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-19 14:13 Sarthak Indurkhya via ffmpeg-devel
2025-07-19 14:47 ` Kacper Michajlow
2025-07-23  5:30   ` Sarthak Indurkhya via ffmpeg-devel
2025-07-23  9:41     ` Niklas Haas [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-07-05 18:20 Sarthak Indurkhya via ffmpeg-devel
2025-07-08  1:06 ` Michael Niedermayer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250723114132.GB12433@haasn.xyz \
    --to=ffmpeg@haasn.xyz \
    --cc=ffmpeg-devel@ffmpeg.org \
    --cc=sindurkhya@adobe.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git