mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Werner Sembach <wse@tuxedocomputers.com>
To: Andri Yngvason <andri@yngvason.is>
Cc: "Maxime Ripard" <mripard@kernel.org>,
	"Harry Wentland" <harry.wentland@amd.com>,
	"Leo Li" <sunpeng.li@amd.com>,
	"Rodrigo Siqueira" <Rodrigo.Siqueira@amd.com>,
	"Alex Deucher" <alexander.deucher@amd.com>,
	"Christian König" <christian.koenig@amd.com>,
	"Pan, Xinhui" <Xinhui.Pan@amd.com>,
	"David Airlie" <airlied@gmail.com>,
	"Daniel Vetter" <daniel@ffwll.ch>,
	"Maarten Lankhorst" <maarten.lankhorst@linux.intel.com>,
	"Thomas Zimmermann" <tzimmermann@suse.de>,
	"Jani Nikula" <jani.nikula@linux.intel.com>,
	"Joonas Lahtinen" <joonas.lahtinen@linux.intel.com>,
	"Rodrigo Vivi" <rodrigo.vivi@intel.com>,
	"Tvrtko Ursulin" <tvrtko.ursulin@linux.intel.com>,
	amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
	linux-kernel@vger.kernel.org, intel-gfx@lists.freedesktop.org,
	"Simon Ser" <contact@emersion.fr>,
	"Dan Carpenter" <dan.carpenter@oracle.com>
Subject: Re: [PATCH 5/7] drm/uAPI: Add "preferred color format" drm property as setting for userspace
Date: Wed, 10 Jan 2024 15:54:19 +0100	[thread overview]
Message-ID: <231df657-270c-478f-9076-3f5dedb195da@tuxedocomputers.com> (raw)
In-Reply-To: <CAFNQBQxnMh4aPfm+U8vEfxoTdQ+FByfqwUUDnMTzgkrW2+ZZqw@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 3516 bytes --]

Hi,

Am 10.01.24 um 14:42 schrieb Andri Yngvason:
> mið., 10. jan. 2024 kl. 13:09 skrifaði Werner Sembach<wse@tuxedocomputers.com>:
>> Hi,
>>
>> Am 10.01.24 um 11:11 schrieb Andri Yngvason:
>>> Hi,
>>>
>>> mið., 10. jan. 2024 kl. 09:27 skrifaði Maxime Ripard<mripard@kernel.org>:
>>>> On Tue, Jan 09, 2024 at 06:11:02PM +0000, Andri Yngvason wrote:
>>>>> From: Werner Sembach<wse@tuxedocomputers.com>
>>>>>
>>>>> Add a new general drm property "preferred color format" which can be used
>>>>> by userspace to tell the graphic drivers to which color format to use.
>>>>>
>>>>> Possible options are:
>>>>>       - auto (default/current behaviour)
>>>>>       - rgb
>>>>>       - ycbcr444
>>>>>       - ycbcr422 (not supported by both amdgpu and i915)
>>>>>       - ycbcr420
>>>>>
>>>>> In theory the auto option should choose the best available option for the
>>>>> current setup, but because of bad internal conversion some monitors look
>>>>> better with rgb and some with ycbcr444.
>>>> I looked at the patch and I couldn't find what is supposed to happen if
>>>> you set it to something else than auto, and the driver can't match that.
>>>> Are we supposed to fallback to the "auto" behaviour, or are we suppose
>>>> to reject the mode entirely?
>>>>
>>>> The combination with the active output format property suggests the
>>>> former, but we should document it explicitly.
>>> It is also my understanding that it should fall back to the "auto"
>>> behaviour. I will add this to the documentation.
>> Yes, that was the intention, and then userspace can check, but it wasn't well
>> received:https://gitlab.freedesktop.org/drm/amd/-/issues/476#note_964530
>>
>> Actually a lot of the thoughts that went into the original patch set can be
>> found in that topic.
>>
>> There was another iteration of the patch set that I never finished and sent to
>> the LKML because I got discouraged by this:
>> https://lore.kernel.org/dri-devel/20210623102923.70877c1a@eldfell/
> Well, I've implemented this for sway and wlroots now and Simon has
> reacted positively, so this does appear likely to end up as a feature
> in wlroots based compositors.
>
>> I can try to dig it up, but it is completely untested and I don't think I still
>> have the respective TODO list anymore, so I don't know if it is a better or
>> worst starting point than the last iteration I sent to the LKML.
>>
> You can send the patches to me if you want and I can see if they're
> useful. I'm really only interested in the color format part though.
> Alternatively, you can continue your work and post it to LKML and I
> can focus on the userspace side and testing. By the way, I have an
> HDMI analyzer that can tell me the actual color format.

Searched for what I still had in my private repo, see attachments, filename is 
the branch name I used and like I said: I don't know which state these branches 
are in.

The hacking_ branch was based on 25fe90f43fa312213b653dc1f12fd2d80f855883 from 
linux-next and the rejected_ one on 132b189b72a94328f17fd70321bfe63e5b4208e9 
from drm-tip.

And the rejected_ one is 2 weeks newer.

To pick it up again I would first need to allocate some time for it, ... which 
could take some time.

With a HDMI analyzer at hand you are better equipped then me already. I was 
working with printf statements, Monitor OSD's and test patterns like 
https://media.extron.com/public/technology/landing/vector4k/img/scalfe-444Chroma.png 
and http://www.lagom.nl/lcd-test/ while being red blind xD.

>
> Thanks,
> Andri

[-- Attachment #1.2: Type: text/html, Size: 5492 bytes --]

[-- Attachment #2: hacking_drm_color_management_no_immutable_flag.tar.gz --]
[-- Type: application/gzip, Size: 10913 bytes --]

[-- Attachment #3: rejected_drm_color_management.tar.gz --]
[-- Type: application/gzip, Size: 19541 bytes --]

  reply	other threads:[~2024-01-10 14:54 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-09 18:10 [PATCH 0/7] New DRM properties for output color format Andri Yngvason
2024-01-09 18:10 ` [PATCH 1/7] drm/amd/display: Remove unnecessary SIGNAL_TYPE_HDMI_TYPE_A check Andri Yngvason
2024-01-09 18:10 ` [PATCH 2/7] drm/uAPI: Add "active color format" drm property as feedback for userspace Andri Yngvason
2024-01-09 22:32   ` Daniel Stone
     [not found]     ` <CAFNQBQwiqqSRqzXAnC035UWCGF3=GGFR5SpDd=biPTOEA+cWbQ@mail.gmail.com>
2024-01-09 23:21       ` Andri Yngvason
2024-01-10 10:44       ` Daniel Vetter
2024-01-10 13:26         ` Daniel Stone
2024-01-11 17:17           ` Andri Yngvason
2024-01-15 15:01             ` Sebastian Wick
2024-01-10 13:39   ` Werner Sembach
2024-01-09 18:11 ` [PATCH 3/7] drm/amd/display: Add handling for new "active color format" property Andri Yngvason
2024-01-10 11:10   ` Daniel Vetter
2024-01-10 12:52     ` Andri Yngvason
2024-01-10 13:09       ` Daniel Vetter
2024-01-10 13:14         ` Werner Sembach
2024-01-10 17:15           ` Andri Yngvason
2024-01-11 23:54             ` Werner Sembach
2024-01-09 18:11 ` [PATCH 4/7] drm/i915/display: " Andri Yngvason
2024-01-09 18:11 ` [PATCH 5/7] drm/uAPI: Add "preferred color format" drm property as setting for userspace Andri Yngvason
2024-01-10  9:27   ` Maxime Ripard
2024-01-10 10:11     ` Andri Yngvason
2024-01-10 13:09       ` Werner Sembach
2024-01-10 13:42         ` Andri Yngvason
2024-01-10 14:54           ` Werner Sembach [this message]
2024-01-09 18:11 ` [PATCH 6/7] drm/amd/display: Add handling for new "preferred color format" property Andri Yngvason
2024-01-09 18:11 ` [PATCH 7/7] drm/i915/display: " Andri Yngvason

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=231df657-270c-478f-9076-3f5dedb195da@tuxedocomputers.com \
    --to=wse@tuxedocomputers.com \
    --cc=Rodrigo.Siqueira@amd.com \
    --cc=Xinhui.Pan@amd.com \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=andri@yngvason.is \
    --cc=christian.koenig@amd.com \
    --cc=contact@emersion.fr \
    --cc=dan.carpenter@oracle.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=harry.wentland@amd.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=rodrigo.vivi@intel.com \
    --cc=sunpeng.li@amd.com \
    --cc=tvrtko.ursulin@linux.intel.com \
    --cc=tzimmermann@suse.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®