[PATCH v4 1/1] Documentation: drm: describing plane alpha and color blending property

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Sagar Kamble <sagar.a.kamble@xxxxxxxxx>

v2: Added description for "src-color" and "constant-alpha" property.
    [Review by Laurent Pinchart]

v3: Fixed typos. [Review by David Herrmann]

v4: Additional formatting and modified description. [Review by David Herrmann]

Cc: rob@xxxxxxxxxxx
Cc: airlied@xxxxxxxxxx
Cc: daniel.vetter@xxxxxxxx
Cc: laurent.pinchart@xxxxxxxxxxxxxxxx
Cc: dh.herrmann@xxxxxxxxx
Cc: alexander.deucher@xxxxxxx
Cc: ville.syrjala@xxxxxxxxxxxxxxx
Cc: sagar.a.kamble@xxxxxxxxx
Cc: vijay.a.purushothaman@xxxxxxxxx
Cc: linux-doc@xxxxxxxxxxxxxxx
Cc: dri-devel@xxxxxxxxxxxxxxxxxxxxx
Signed-off-by: Sagar Kamble <sagar.a.kamble@xxxxxxxxx>
---
 Documentation/DocBook/drm.tmpl | 32 +++++++++++++++++++++++++++++++-
 1 file changed, 31 insertions(+), 1 deletion(-)

diff --git a/Documentation/DocBook/drm.tmpl b/Documentation/DocBook/drm.tmpl
index 104402a..dd2ae67 100644
--- a/Documentation/DocBook/drm.tmpl
+++ b/Documentation/DocBook/drm.tmpl
@@ -2264,6 +2264,20 @@ void intel_crt_init(struct drm_device *dev)
       </variablelist>
     </para>
     <para>
+      In addition to above types, properties can be constrained by supplying additional
+      flags while creating the property. Supported flags are
+      <variablelist>
+        <varlistentry>
+          <term>DRM_MODE_PROP_32BIT_PAIR</term>
+          <listitem><para>This flag is applicable to Bitmask enum properties. It creates
+	    Pair-properties that store two packed 32 bit values as 64bit unsigned integer
+	    (often used as key-value pair). The lower 32 bits contain the first value (also: key),
+	    while the upper 32 bits contain the second value.
+	    Written as: ({key (LSB 32 bits), value (MSB 32 bits)}).</para></listitem>
+        </varlistentry>
+      </variablelist>
+    </para>
+    <para>
       To create a property drivers call one of the following functions depending
       on the property type. All property creation functions take property flags
       and name, as well as type-specific arguments.
@@ -2336,7 +2350,7 @@ void intel_crt_init(struct drm_device *dev)
 	</tr>
 	<tr>
 	<td rowspan="19" valign="top" >DRM</td>
-	<td rowspan="2" valign="top" >Generic</td>
+	<td rowspan="3" valign="top" >Generic</td>
 	<td valign="top" >“EDID”</td>
 	<td valign="top" >BLOB | IMMUTABLE</td>
 	<td valign="top" >0</td>
@@ -2351,6 +2365,22 @@ void intel_crt_init(struct drm_device *dev)
 	<td valign="top" >Contains DPMS operation mode value.</td>
 	</tr>
 	<tr>
+	<td valign="top" >“blend”</td>
+	<td valign="top" >BITMASK | 32BIT_PAIR</td>
+	<td valign="top" >{ "zero" = 0, "one" = 1, "src-color" = 2, "one-minus-src-color" = 3
+	, "dst-color" = 4, "one-minus-dst-color" = 5, "src-alpha"= 6, "one-minus-src-alpha" = 7, "dst-alpha" = 8
+	, "one-minus-dst-alpha" = 9, "constant-color" = 10, "one-minus-constant-color" = 11, "constant-alpha" = 12
+	, "one-minus-constant-alpha" = 13, "alpha-saturate" = 14 }</td>
+	<td valign="top" >Plane</td>
+	<td valign="top" >Contains plane alpha/color blending operation values. These are modeled after the glBlendFunc API
+	in OpenGL. Not all modes are supported by all drivers. The first value of the 32BIT_PAIR describes the blending mode
+	of the source plane, the second value describes the blending factors of the source plane.
+	<para>
+	For e.g. to apply constant alpha of 0xFF on source plane, the first value of this property for source plane should
+	be set to 2^10 and second value to value of alpha(0xFF).
+	</para></td>
+	</tr>
+	<tr>
 	<td rowspan="2" valign="top" >DVI-I</td>
 	<td valign="top" >“subconnector”</td>
 	<td valign="top" >ENUM</td>
-- 
1.8.5

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel

[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux