From: Damien Lespiau <damien.lespiau@intel.com>
To: Sagar Arun Kamble <sagar.a.kamble@intel.com>
Cc: David Airlie <airlied@linux.ie>,
Daniel Vetter <daniel.vetter@ffwll.ch>,
intel-gfx@lists.freedesktop.org, "Srinivas,
Vidya" <vidya.srinivas@intel.com>
Subject: Re: [PATCH 3/4] drm/i915: Enabling pre-multiplied alpha drm property
Date: Thu, 20 Mar 2014 11:38:18 +0000 [thread overview]
Message-ID: <20140320113818.GL6912@strange.amr.corp.intel.com> (raw)
In-Reply-To: <1395309582.2740.9.camel@sagar-desktop>
On Thu, Mar 20, 2014 at 03:29:42PM +0530, Sagar Arun Kamble wrote:
> Hi Damien,
>
> On Wed, 2014-03-19 at 15:10 +0000, Damien Lespiau wrote:
> > On Sat, Mar 08, 2014 at 01:51:18PM +0530, sagar.a.kamble@intel.com wrote:
> > > From: Sagar Kamble <sagar.a.kamble@intel.com>
> > >
> > > This patch enables property for changin the pixel format
> > > of plane to enable/disable pre-multiplied alpha format.
> > > Client has to set BIT(DRM_BLEND_PREMULTIPLIED_ALPHA) | 0x0/0x1
> > > to disable/enable pre-multiplied alpha format.
> > >
> > > Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> > > Cc: Jani Nikula <jani.nikula@linux.intel.com>
> > > Cc: David Airlie <airlied@linux.ie>
> > > Signed-off-by: Srinivas, Vidya <vidya.srinivas@intel.com>
> > > Signed-off-by: Sagar Kamble <sagar.a.kamble@intel.com>
> >
> > Huum, the alpha being premultiplied or not seems to be a property of the
> > framebuffer to me, not of the plane. It seems to me that we should
> > define alternative premultiplied DRM_FORMATs and make the sprite planes
> > advertise support for premultiplied fbs in the format list when the
> > hardware indeed supports them.
> This is what i think of usage of this property:
>
> Composer/user mode starts using plane with XRGB format and then it wants
> to add transparency to the plane. So it will set the format to ARGB
> format and provide buffer for that plane that will have pixels with
> pre-multiplied alpha (a*r, a*g, a*b, a).
> This can be done with primary plane(CRTC) as well, however I have
> not added this as CRTC property since CRTCs are going to be drm_plane
> soon.
>
> Will this kind of interface for usermode to toggle the pixel format's
> alpha be useful?
I don't think so, nop.
Besides being a convoluted apocalyptic scenario, one cannot simply
change the format of the FB without re-adding it with AddFB2().
There's a usage model for the compositor to add a plane-global alpha to
a plane (fades the client provided render target) and that's indeed a
plane property.
As far I as can tell, the premultiplied alpha format ban be sued support
scanning out OpenGL blended fbs.
--
Damien
next prev parent reply other threads:[~2014-03-20 11:38 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-19 10:08 [RFC 1/1] drm/i915: Added support for setting plane alpha through drm property sagar.a.kamble
2014-02-24 15:44 ` Sagar Arun Kamble
2014-03-06 12:03 ` Damien Lespiau
2014-03-06 12:09 ` Damien Lespiau
2014-02-25 18:18 ` Ville Syrjälä
2014-03-04 9:42 ` [Intel-gfx] " Daniel Vetter
2014-03-04 12:06 ` Ville Syrjälä
2014-03-06 10:28 ` [Intel-gfx] " Sagar Arun Kamble
2014-03-06 11:24 ` Daniel Vetter
2014-03-08 8:21 ` [PATCH 0/4] Adding support for plane alpha/color blending " sagar.a.kamble
2014-03-08 8:21 ` [PATCH 1/4] drm: Added plane alpha and color blending property sagar.a.kamble
2014-03-20 11:58 ` Damien Lespiau
2014-03-20 14:21 ` [Intel-gfx] " Damien Lespiau
2014-03-08 8:21 ` [PATCH 2/4] drm/i915: Enabling constant alpha drm property sagar.a.kamble
2014-03-20 13:51 ` Damien Lespiau
2014-03-25 14:32 ` [PATCH v2 1/4] drm: Adding new flag to restrict bitmask drm properties as 32 bit type and 32 bit value pair sagar.a.kamble
2014-03-25 14:32 ` [PATCH v2 2/4] drm: Added plane alpha and color blending property sagar.a.kamble
2014-03-25 14:32 ` [PATCH v2 3/4] drm/i915: Enabling constant alpha drm property sagar.a.kamble
2014-04-01 4:51 ` Sagar Arun Kamble
2014-04-02 6:12 ` Sagar Arun Kamble
2014-04-03 5:43 ` Sagar Arun Kamble
2014-04-15 9:44 ` Sagar Arun Kamble
2014-04-15 10:35 ` Ville Syrjälä
2014-04-15 11:23 ` Sagar Arun Kamble
2014-04-15 11:44 ` Ville Syrjälä
2014-03-25 14:32 ` [PATCH v2 4/4] Documentation: drm: describing plane alpha and color blending property sagar.a.kamble
2014-03-26 12:30 ` David Herrmann
2014-03-27 9:03 ` [PATCH v3 1/1] " sagar.a.kamble
2014-03-27 9:50 ` sagar.a.kamble
2014-03-27 12:38 ` David Herrmann
2014-03-27 17:31 ` [PATCH v4 " sagar.a.kamble
2014-04-10 10:39 ` [PATCH v2 1/4] drm: Adding new flag to restrict bitmask drm properties as 32 bit type and 32 bit value pair Sagar Arun Kamble
2014-03-08 8:21 ` [PATCH 3/4] drm/i915: Enabling pre-multiplied alpha drm property sagar.a.kamble
2014-03-19 15:10 ` Damien Lespiau
2014-03-20 9:59 ` Sagar Arun Kamble
2014-03-20 11:38 ` Damien Lespiau [this message]
2014-03-20 13:51 ` Daniel Vetter
2014-03-20 14:00 ` Damien Lespiau
2014-03-08 8:21 ` [PATCH 4/4] Documentation: drm: describing plane alpha and color blending property sagar.a.kamble
2014-03-10 14:43 ` Laurent Pinchart
2014-03-20 14:11 ` [PATCH 0/4] Adding support for plane alpha/color blending through drm property Damien Lespiau
2014-03-20 14:45 ` Damien Lespiau
2014-03-21 13:36 ` Sagar Arun Kamble
2014-03-21 19:23 ` Damien Lespiau
2014-04-02 19:36 ` Ville Syrjälä
2014-03-25 10:03 ` Sagar Arun Kamble
2014-03-25 10:51 ` Daniel Vetter
2014-03-25 12:26 ` Damien Lespiau
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=20140320113818.GL6912@strange.amr.corp.intel.com \
--to=damien.lespiau@intel.com \
--cc=airlied@linux.ie \
--cc=daniel.vetter@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.org \
--cc=sagar.a.kamble@intel.com \
--cc=vidya.srinivas@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox