Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Aug 2014 21:02:21 +0200
From:      =?windows-1252?Q?Jean-S=E9bastien_P=E9dron?= <dumbbell@FreeBSD.org>
To:        freebsd-current@freebsd.org
Subject:   Re: r269471 make unusable VT console
Message-ID:  <53F39F3D.9010104@FreeBSD.org>
In-Reply-To: <53F38D8E.8090605@freebsd.org>
References:  <20140812232807.0f3aa02570becec15e056af2@fbsd.es>	<20140816011444.301a98d6187aca27e3a2481b@ddteam.net> <CAJ-Vmon3OS3fY1VoHu1n_T=N9NN64U7ZsxdbCkWsXAGbdMhp0g@mail.gmail.com> <53EE9CFF.4080607@freebsd.org> <53F30DF3.1090301@dumbbell.fr> <53F37B2D.3070807@FreeBSD.org> <53F38D8E.8090605@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--0fIubDe0HAdUSj8MTWbQH5HohUs4Q8MbP
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

On 19.08.2014 19:46, Nathan Whitehorn wrote:
> On 08/19/14 09:28, Jean-S=E9bastien P=E9dron wrote:
>>      o  vt_vga introduces a new callback, vd_bitblt_text_t, which take=
s
>>         as argument the text buffer, the dirty area, the font and the
>>         cursor (position, map, colors).
>
> Why is this necessary? I'd really prefer to avoid complicating this API=
=2E
> One of the great things about writing newcons drivers is that there is
> basically only one function you need to implement. If the current API
> does not provide enough information to do this efficiently, I'd much
> rather change it than add new callbacks.

I don't want to have two callbacks for the same feature either, and I'd
like to transition other drivers to this new one.

The current bitbltchr callback only knows about one character. In the
case of vt_vga, if this character (or the cursor) isn't aligned on
8-pixels boundaries, it needs to redraw several "blocks" of pixels. With
this character-centric approach, if a block needs a redraw, it'll be
refreshed for the character on its left side, then refreshed again for
the character on its right side.

The advantage of giving the callback the whole text/area is that it
allows the driver to manipulate the pixels block by block, instead of
character by character.

The patch isn't finished yet. Meanwhile, I'll commit the bug fixes I
made (especially the cursor handling in vt_flush()). But eventually, the
plan is to convert all drivers to this new callback, if you find the new
API sensible.

--=20
Jean-S=E9bastien P=E9dron


--0fIubDe0HAdUSj8MTWbQH5HohUs4Q8MbP
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQJ8BAEBCgBmBQJT859DXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz
OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMgw8QAIWZf3jQwF3/MI4aR3V3jwlD
nCXjftGehdZOStr/hju0a5dAMtNkgfuPSCBR7A/RfMGp2S/Kq8jue/p2a77fWrE5
UjtgwnIS3TWxbek1p8+KaVz+zTCAaVRYoMTlOs8HNERzUuV1xi625R2V0VIoeDNA
0uIqg62N9waBVpFqTmWXXfmWdSU12G7sHDZkWHzuE7/I1vtom707KOgYAIdqJ/l+
adxmkizkSGUSmWP7Vm3k+GTl3l7zg+kqgBy0ov7N3v8YX/jy4UIrBCYSdJlnEK9W
4SBiktEopu0BIfUuFTeBu+L5GmJgfI7hOPkFCm4GHhdbH9s2GsQJESjNARwp/+fZ
u5ju+qluaanxYiNS4Qy9Lacxkd0iq4hxgtSlofXvXIaRpgzAlrnktW3MQU6Ur8iL
XBXx9rqf8u1QXD3HNyXxILfQnIpxsFLgRfkgpN7GeXK+pvAsNp6P5CLThy21Offs
l2dJmb3jtkeWJuWM7u3z9GdVSf1AttUQcQI03ZonqKdspnmxI3delIGzyQq+XZza
z8QcoWr1pjOm9ZThTp2W/0/b1NqEqrU6Gj+a1acdLnLwncBy4DfikDLNWNC9aXxU
BxNoH5VdjhHbyW4ZUdB3G9Ds4SMuNXh1d9Meo6sds10doUaWduYD19H5WhHzw/eO
P1wSk2P+MXdxVEJ0JAc7
=OCUa
-----END PGP SIGNATURE-----

--0fIubDe0HAdUSj8MTWbQH5HohUs4Q8MbP--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?53F39F3D.9010104>