From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jesse Barnes Subject: Re: [PATCH 2/2] drm: add an fb creation ioctl that takes a pixel format v4 Date: Mon, 14 Nov 2011 13:35:57 -0800 Message-ID: <20111114133557.1b2a353f@jbarnes-desktop> References: <1321302115-23159-1-git-send-email-jbarnes@virtuousgeek.org> <1321302115-23159-2-git-send-email-jbarnes@virtuousgeek.org> <20111114212455.GI3477@intel.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1947321861==" Return-path: Received: from oproxy7-pub.bluehost.com (oproxy7-pub.bluehost.com [67.222.55.9]) by gabe.freedesktop.org (Postfix) with SMTP id EE2859F071 for ; Mon, 14 Nov 2011 13:35:19 -0800 (PST) In-Reply-To: <20111114212455.GI3477@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Ville =?ISO-8859-1?B?U3lyauRs5A==?= Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============1947321861== Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/xZKzprZjHznXY1xlu0NHQe8"; protocol="application/pgp-signature" --Sig_/xZKzprZjHznXY1xlu0NHQe8 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Mon, 14 Nov 2011 23:24:55 +0200 Ville Syrj=E4l=E4 wrote: > On Mon, Nov 14, 2011 at 12:21:55PM -0800, Jesse Barnes wrote: > > +struct drm_mode_fb_cmd2 { > > + __u32 fb_id; > > + __u32 width, height; > > + __u32 pixel_format; /* fourcc code from videodev2.h */ > > + > > + /* > > + * In case of planar formats, this ioctl allows up to 4 > > + * buffer objects with offets and pitches per plane. > > + * The pitch and offset order is dictated by the fourcc, > > + * e.g. NV12 (http://fourcc.org/yuv.php#NV12) is described as: > > + * > > + * YUV 4:2:0 image with a plane of 8 bit Y samples > > + * followed by an interleaved U/V plane containing > > + * 8 bit 2x2 subsampled colour difference samples. > > + * > > + * So it would consist of Y as offset[0] and UV as > > + * offeset[1]. Note that offset[0] will generally > > + * be 0. > > + */ > > + __u32 handles[4]; > > + __u32 pitches[4]; /* pitch for each plane */ > > + __u32 offsets[4]; /* offset of each plane */ > > +}; >=20 > Hey, what about those interlaced buffers? We talked privately about > adding a '__u32 flags' member to both drm_mode_fb_cmd2 and > drm_mode_set_plane. >=20 > We could stick something like these to those flags: > fb_cmd2.flags: > #define DRM_MODE_FB_INTERLACED 0x1 >=20 > set_plane.flags: > #define DRM_MODE_PRESENT_TOP_FIELD 0x1 > #define DRM_MODE_PRESENT_BOTTOM_FIELD 0x2 Oh sorry I lost track of the internal discussion. Are those attributes of the fb or of each object? E.g. could you mix interlaced and non-interlaced buffers in a planar format? Maybe I need to rename this ioctl to addfb_swissarmyknife :) --=20 Jesse Barnes, Intel Open Source Technology Center --Sig_/xZKzprZjHznXY1xlu0NHQe8 Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAEBAgAGBQJOwYm9AAoJEIEoDkX4Qk9hQEYP/2M1DkHhg3qTzZAmzlZeDTmY 2ezwyUaGdNY8r05OGrxVfs9IcuASBzvwau+60KVsQN1sv5KDbhpPhXC7kWduAXs0 1YBR3KcOckQrtFG13SGnMCoFFXqAFG1yvIr5snJZ2h2Jbmwc5QW0aNv63jP1XAs0 fAa2tK+3k4YDpmpNn6TO9M3TOl1X3Rs8mEQKoEPIwMEFk4dXmBvGO+x+6HGBW9zH kt/RmIQkOEf+gXr3p9qxb/qz1d3NtMX0E/+rRpxseoXlNnSs2PvPwU2XydBDRYq/ 31d+RObaKDYt4Bgr52VuhGrVpoAmd4YQ6oXHTm/9ZIh/yIDc2nOgUkL0IiOFHsII NMSEP1Iz13IabOdEqMPd//a2eFPp4cluu6ItX//OSWRBYGHAz4oZK0FHcJE7k9AN UqubuvUvde7qxfhUQfHIUPjqEX7UaDasUWXL4zLnvhU7QjLmbgKqgt1IMNW8rRMG LysMBgHw7fRNodc4EZkYwuVcA3SDjOyD40gyrGL8muF4eo4rCt+o05aHdU8NwlVh XWTKEiyfnpGL+mHdAzKK6aln/XyKnezH+PZz2F+ferb57fSN7eZJddtWGIILtcNC ZOA4BE5HIuou2V/s1N6kmpnEg4tny97NKzFjuyJJPU5ue4B78Y4Wt9cGpumysJ/U VkGbWeFhmavI2tFhTNAk =nRbs -----END PGP SIGNATURE----- --Sig_/xZKzprZjHznXY1xlu0NHQe8-- --===============1947321861== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/dri-devel --===============1947321861==--