From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: "Borah, Chaitanya Kumar" <chaitanya.kumar.borah@intel.com>
Cc: Pekka Paalanen <pekka.paalanen@collabora.com>,
Alex Hung <alex.hung@amd.com>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>,
"amd-gfx@lists.freedesktop.org" <amd-gfx@lists.freedesktop.org>,
"wayland-devel@lists.freedesktop.org"
<wayland-devel@lists.freedesktop.org>,
"harry.wentland@amd.com" <harry.wentland@amd.com>,
"leo.liu@amd.com" <leo.liu@amd.com>,
"mwen@igalia.com" <mwen@igalia.com>,
"jadahl@redhat.com" <jadahl@redhat.com>,
"sebastian.wick@redhat.com" <sebastian.wick@redhat.com>,
"shashank.sharma@amd.com" <shashank.sharma@amd.com>,
"agoins@nvidia.com" <agoins@nvidia.com>,
"joshua@froggi.es" <joshua@froggi.es>,
"mdaenzer@redhat.com" <mdaenzer@redhat.com>,
"aleixpol@kde.org" <aleixpol@kde.org>,
"xaver.hugl@gmail.com" <xaver.hugl@gmail.com>,
"victoria@system76.com" <victoria@system76.com>,
"daniel@ffwll.ch" <daniel@ffwll.ch>,
"Shankar, Uma" <uma.shankar@intel.com>,
"quic_naseer@quicinc.com" <quic_naseer@quicinc.com>,
"quic_cbraga@quicinc.com" <quic_cbraga@quicinc.com>,
"quic_abhinavk@quicinc.com" <quic_abhinavk@quicinc.com>,
"marcan@marcan.st" <marcan@marcan.st>,
"Liviu.Dudau@arm.com" <Liviu.Dudau@arm.com>,
"sashamcintosh@google.com" <sashamcintosh@google.com>,
"louis.chauvet@bootlin.com" <louis.chauvet@bootlin.com>,
Daniel Stone <daniels@collabora.com>
Subject: Re: [PATCH V9 16/43] drm/colorop: Add 3x4 CTM type
Date: Tue, 17 Jun 2025 18:25:30 +0300 [thread overview]
Message-ID: <aFGI6rPrV9OVJCZ9@intel.com> (raw)
In-Reply-To: <SJ1PR11MB6129FDD1CBAA6FBFD978054FB973A@SJ1PR11MB6129.namprd11.prod.outlook.com>
On Tue, Jun 17, 2025 at 05:33:20AM +0000, Borah, Chaitanya Kumar wrote:
>
>
> > -----Original Message-----
> > From: Pekka Paalanen <pekka.paalanen@collabora.com>
> > Sent: Monday, June 16, 2025 7:02 PM
> > To: Borah, Chaitanya Kumar <chaitanya.kumar.borah@intel.com>
> > Cc: Alex Hung <alex.hung@amd.com>; dri-devel@lists.freedesktop.org; amd-
> > gfx@lists.freedesktop.org; wayland-devel@lists.freedesktop.org;
> > harry.wentland@amd.com; leo.liu@amd.com; ville.syrjala@linux.intel.com;
> > mwen@igalia.com; jadahl@redhat.com; sebastian.wick@redhat.com;
> > shashank.sharma@amd.com; agoins@nvidia.com; joshua@froggi.es;
> > mdaenzer@redhat.com; aleixpol@kde.org; xaver.hugl@gmail.com;
> > victoria@system76.com; daniel@ffwll.ch; Shankar, Uma
> > <uma.shankar@intel.com>; quic_naseer@quicinc.com;
> > quic_cbraga@quicinc.com; quic_abhinavk@quicinc.com; marcan@marcan.st;
> > Liviu.Dudau@arm.com; sashamcintosh@google.com;
> > louis.chauvet@bootlin.com; Daniel Stone <daniels@collabora.com>
> > Subject: Re: [PATCH V9 16/43] drm/colorop: Add 3x4 CTM type
> >
> > On Mon, 16 Jun 2025 11:30:23 +0000
> > "Borah, Chaitanya Kumar" <chaitanya.kumar.borah@intel.com> wrote:
> >
> > > > -----Original Message-----
> > > > From: Alex Hung <alex.hung@amd.com>
> > > > Sent: Wednesday, April 30, 2025 6:41 AM
> > > > To: dri-devel@lists.freedesktop.org; amd-gfx@lists.freedesktop.org
> > > > Cc: wayland-devel@lists.freedesktop.org; harry.wentland@amd.com;
> > > > alex.hung@amd.com; leo.liu@amd.com; ville.syrjala@linux.intel.com;
> > > > pekka.paalanen@collabora.com; contact@emersion.fr; mwen@igalia.com;
> > > > jadahl@redhat.com; sebastian.wick@redhat.com;
> > > > shashank.sharma@amd.com; agoins@nvidia.com; joshua@froggi.es;
> > > > mdaenzer@redhat.com; aleixpol@kde.org; xaver.hugl@gmail.com;
> > > > victoria@system76.com; daniel@ffwll.ch; Shankar, Uma
> > > > <uma.shankar@intel.com>; quic_naseer@quicinc.com;
> > > > quic_cbraga@quicinc.com; quic_abhinavk@quicinc.com;
> > > > marcan@marcan.st; Liviu.Dudau@arm.com; sashamcintosh@google.com;
> > > > Borah, Chaitanya Kumar <chaitanya.kumar.borah@intel.com>;
> > > > louis.chauvet@bootlin.com; Daniel Stone <daniels@collabora.com>
> > > > Subject: [PATCH V9 16/43] drm/colorop: Add 3x4 CTM type
> > > >
> > > > From: Harry Wentland <harry.wentland@amd.com>
> > > >
> > > > This type is used to support a 3x4 matrix in colorops. A 3x4 matrix
> > > > uses the last column as a "bias" column. Some HW exposes support for
> > > > 3x4. The calculation looks like:
> > > >
> > > > out matrix in
> > > > |R| |0 1 2 3 | | R |
> > > > |G| = |4 5 6 7 | x | G |
> > > > |B| |8 9 10 11| | B |
> > > > |1.0|
> > > >
> > > > This is also the first colorop where we need a blob property to
> > > > program the property. For that we'll introduce a new DATA property
> > > > that can be used by all colorop TYPEs requiring a blob. The way a
> > > > DATA blob is read depends on the TYPE of the colorop.
> > > >
> > > > We only create the DATA property for property types that need it.
> > >
> > > Is there any value to adding pre-offsets [1] in the uapi?
> > >
> > > |R/Cr| | c0 c1 c2 | ( |R/Cr| |preoff0| ) |postoff0|
> > > |G/Y | = | c3 c4 c5 | x ( |G/Y | + |preoff1| ) + |postoff1|
> > > |B/Cb| | c6 c7 c8 | ( |B/Cb| |preoff2| ) |postoff2|
> > >
> > > Handling limited range values is one use case that I can think of.
> >
> > Hi,
> >
> > in the mathematical sense, no. A pre-offset can always be converted into a
> > post-offset by multiplying it with the 3x3 matrix (and adding to the existing
> > post-offset). This can be pre-computed, no need to do it separately for every
> > pixel.
> >
> > For hardware reasons, I have no idea.
>
> Thank you for the reply, Pekka. Our hardware does allow programming Pre-offsets separately.
> Currently I can't think of a particular advantage of that if mathematically a post-offset does the job but I will keep this thread posted if I find something out.
Just FYI we have three different kinds of hardware:
- 3x3 matrix
- 3x3 matrix + programmable pre offsets + hardcoded post offsets for limited range conversion
- 3x3 matrix + programmable pre and post offsets
--
Ville Syrjälä
Intel
next prev parent reply other threads:[~2025-06-17 15:25 UTC|newest]
Thread overview: 82+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-30 1:10 [PATCH V9 00/43] Color Pipeline API w/ VKMS Alex Hung
2025-04-30 1:10 ` [PATCH V9 01/43] drm: Add helper for conversion from signed-magnitude Alex Hung
2025-04-30 1:10 ` [PATCH V9 02/43] drm/vkms: Add kunit tests for VKMS LUT handling Alex Hung
2025-04-30 1:10 ` [PATCH V9 03/43] drm/doc/rfc: Describe why prescriptive color pipeline is needed Alex Hung
2025-05-15 9:30 ` Simon Ser
2025-04-30 1:10 ` [PATCH V9 04/43] drm/colorop: Introduce new drm_colorop mode object Alex Hung
2025-04-30 1:10 ` [PATCH V9 05/43] drm/colorop: Add TYPE property Alex Hung
2025-04-30 1:10 ` [PATCH V9 06/43] drm/colorop: Add 1D Curve subtype Alex Hung
2025-04-30 1:10 ` [PATCH V9 07/43] drm/colorop: Add BYPASS property Alex Hung
2025-04-30 1:10 ` [PATCH V9 08/43] drm/colorop: Add NEXT property Alex Hung
2025-04-30 1:10 ` [PATCH V9 09/43] drm/colorop: Add atomic state print for drm_colorop Alex Hung
2025-04-30 1:10 ` [PATCH V9 10/43] drm/plane: Add COLOR PIPELINE property Alex Hung
2025-04-30 1:10 ` [PATCH V9 11/43] drm/colorop: Introduce DRM_CLIENT_CAP_PLANE_COLOR_PIPELINE Alex Hung
2025-04-30 1:10 ` [PATCH V9 12/43] Documentation/gpu: document drm_colorop Alex Hung
2025-04-30 1:10 ` [PATCH V9 13/43] drm/colorop: Add destroy functions for color pipeline Alex Hung
2025-05-15 9:34 ` Simon Ser
2025-04-30 1:10 ` [PATCH V9 14/43] drm/vkms: Add enumerated 1D curve colorop Alex Hung
2025-04-30 1:10 ` [PATCH V9 15/43] drm/vkms: Add kunit tests for linear and sRGB LUTs Alex Hung
2025-05-07 10:03 ` kernel test robot
2025-04-30 1:10 ` [PATCH V9 16/43] drm/colorop: Add 3x4 CTM type Alex Hung
2025-06-16 11:30 ` Borah, Chaitanya Kumar
2025-06-16 13:32 ` Pekka Paalanen
2025-06-17 5:33 ` Borah, Chaitanya Kumar
2025-06-17 15:25 ` Ville Syrjälä [this message]
2025-04-30 1:10 ` [PATCH V9 17/43] drm/vkms: Use s32 for internal color pipeline precision Alex Hung
2025-04-30 1:10 ` [PATCH V9 18/43] drm/vkms: add 3x4 matrix in color pipeline Alex Hung
2025-04-30 1:10 ` [PATCH V9 19/43] drm/tests: Add a few tests around drm_fixed.h Alex Hung
2025-04-30 1:10 ` [PATCH V9 20/43] drm/vkms: Add tests for CTM handling Alex Hung
2025-04-30 1:10 ` [PATCH V9 21/43] drm/colorop: pass plane_color_pipeline client cap to atomic check Alex Hung
2025-04-30 1:10 ` [PATCH V9 22/43] drm/colorop: define a new macro for_each_new_colorop_in_state Alex Hung
2025-05-12 18:32 ` Melissa Wen
2025-04-30 1:10 ` [PATCH V9 23/43] drm/amd/display: Ignore deprecated props when plane_color_pipeline set Alex Hung
2025-04-30 1:10 ` [PATCH V9 24/43] drm/amd/display: Add bypass COLOR PIPELINE Alex Hung
2025-05-12 18:41 ` Melissa Wen
2025-04-30 1:10 ` [PATCH V9 25/43] drm/amd/display: Skip color pipeline initialization for cursor plane Alex Hung
2025-04-30 1:10 ` [PATCH V9 26/43] drm/amd/display: Add support for sRGB EOTF in DEGAM block Alex Hung
2025-05-12 18:50 ` Melissa Wen
2025-05-13 7:42 ` Pekka Paalanen
2025-05-13 15:36 ` Melissa Wen
2025-05-13 20:39 ` Harry Wentland
2025-05-15 10:57 ` Pekka Paalanen
2025-04-30 1:10 ` [PATCH V9 27/43] drm/amd/display: Add support for sRGB Inverse EOTF in SHAPER block Alex Hung
2025-04-30 1:10 ` [PATCH V9 28/43] drm/amd/display: Add support for sRGB EOTF in BLND block Alex Hung
2025-04-30 1:10 ` [PATCH V9 29/43] drm/colorop: Add PQ 125 EOTF and its inverse Alex Hung
2025-04-30 1:11 ` [PATCH V9 30/43] drm/amd/display: Enable support for PQ 125 EOTF and Inverse Alex Hung
2025-04-30 1:11 ` [PATCH V9 31/43] drm/colorop: add BT2020/BT709 OETF and Inverse OETF Alex Hung
2025-05-15 9:35 ` Simon Ser
2025-04-30 1:11 ` [PATCH V9 32/43] drm/amd/display: Add support for BT.709 and BT.2020 TFs Alex Hung
2025-05-12 19:37 ` Melissa Wen
2025-04-30 1:11 ` [PATCH V9 33/43] drm/colorop: Add 1D Curve Custom LUT type Alex Hung
2025-04-30 1:11 ` [PATCH V9 34/43] drm/amd/display: add shaper and blend colorops for 1D Curve Custom LUT Alex Hung
2025-04-30 1:11 ` [PATCH V9 35/43] drm/amd/display: add 3x4 matrix colorop Alex Hung
2025-05-07 12:08 ` kernel test robot
2025-04-30 1:11 ` [PATCH V9 36/43] drm/colorop: Add mutliplier type Alex Hung
2025-05-12 20:02 ` Melissa Wen
2025-04-30 1:11 ` [PATCH V9 37/43] drm/amd/display: add multiplier colorop Alex Hung
2025-04-30 1:11 ` [PATCH V9 38/43] drm/amd/display: Swap matrix and multiplier Alex Hung
2025-04-30 1:11 ` [PATCH V9 39/43] drm/colorop: Define LUT_1D interpolation Alex Hung
2025-04-30 1:11 ` [PATCH V9 40/43] drm/colorop: allow non-bypass colorops Alex Hung
2025-05-15 9:37 ` Simon Ser
2025-04-30 1:11 ` [PATCH V9 41/43] drm/colorop: Add 3D LUT support to color pipeline Alex Hung
2025-04-30 1:11 ` [PATCH V9 42/43] drm/amd/display: add 3D LUT colorop Alex Hung
2025-05-13 0:52 ` Melissa Wen
2025-05-13 3:29 ` Alex Hung
2025-05-13 15:52 ` Melissa Wen
2025-04-30 1:11 ` [PATCH V9 43/43] drm/amd/display: Add AMD color pipeline doc Alex Hung
2025-05-13 15:59 ` [PATCH V9 00/43] Color Pipeline API w/ VKMS Melissa Wen
2025-05-15 9:45 ` Simon Ser
2025-05-15 14:10 ` Harry Wentland
2025-05-15 14:15 ` Simon Ser
2025-05-15 17:19 ` Daniel Stone
2025-05-15 18:02 ` Harry Wentland
2025-05-15 18:39 ` Daniel Stone
2025-05-15 19:59 ` Leandro Ribeiro
2025-05-17 11:51 ` Xaver Hugl
2025-05-21 19:48 ` Harry Wentland
2025-05-22 7:57 ` Pekka Paalanen
2025-05-22 13:28 ` Harry Wentland
2025-05-22 13:49 ` Simon Ser
2025-05-22 13:54 ` Harry Wentland
2025-05-22 15:27 ` Pekka Paalanen
2025-05-22 15:49 ` Harry Wentland
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=aFGI6rPrV9OVJCZ9@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=Liviu.Dudau@arm.com \
--cc=agoins@nvidia.com \
--cc=aleixpol@kde.org \
--cc=alex.hung@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=chaitanya.kumar.borah@intel.com \
--cc=daniel@ffwll.ch \
--cc=daniels@collabora.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=harry.wentland@amd.com \
--cc=jadahl@redhat.com \
--cc=joshua@froggi.es \
--cc=leo.liu@amd.com \
--cc=louis.chauvet@bootlin.com \
--cc=marcan@marcan.st \
--cc=mdaenzer@redhat.com \
--cc=mwen@igalia.com \
--cc=pekka.paalanen@collabora.com \
--cc=quic_abhinavk@quicinc.com \
--cc=quic_cbraga@quicinc.com \
--cc=quic_naseer@quicinc.com \
--cc=sashamcintosh@google.com \
--cc=sebastian.wick@redhat.com \
--cc=shashank.sharma@amd.com \
--cc=uma.shankar@intel.com \
--cc=victoria@system76.com \
--cc=wayland-devel@lists.freedesktop.org \
--cc=xaver.hugl@gmail.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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.