From: Antonino Daplas <adaplas@pol.net>
To: fbdev <linux-fbdev-devel@lists.sourceforge.net>
Subject: Console Rotation
Date: 09 Sep 2002 22:20:58 +0800 [thread overview]
Message-ID: <1031580513.632.3.camel@daplas> (raw)
Hi,
Since Xfbdev is able to rotate the display, I guess it's also reasonable
for the console to have the ability to rotate the display too.
I have added 3 new flags to var->vmode:
FB_VMODE_ROTATE_CW 0x010000 /* 90 degree rotation */
FB_VMODE_ROTATE_CCW 0x020000 /* 270 degree rotation */
FB_VMODE_ROTATE_UD 0x040000 /* 180 degree rotation */
FB_ROTATE_MASK 0xFF0000
Rotating the display is done using console wrappers similar to
fbcon-accel. Depending on the rotation flag, dispsw is pointed to the
appropriate wrapper in gen_set_disp.
As for driver support, the minimum requirement is for the driver to
recognize these flags, and set the var->xres, var->yres,
var->xres_virtual, and var->yres_virtual fields to the appropriate
logical values. Ie, if display is rotated CW or CCW, then logical xres
is physical yres, etc.
For drivers that support panning, the viewport and direction of the
panning must be appropriate for the orientation. Ie, if display is
rotated 180 degrees, the viewport must be flushed to the 'right' and
'bottom' edge of the framebuffer when xoffset and yoffset are zero. Then
logical pan_down is physical pan_up, etc.
The option is configurable under 'Advanced Low Level Driver Options',
and is dependent on CONFIG_FB_ACCEL being set since the wrapper depends
on xxximageblit, xxxfillrect and xxxcopyarea.
As a testbed, I modified vesafb to support console rotation.
The following patches will follow (against linux-2.5.33):
a. fb_rotate.diff
b. fb_drawing.diff
c. vesafb_rotate.diff
d. fbset_rotate.diff
If the patches are mangled, please get them at:
http://i810fb.sourceforge.net/fb_rotate.tar.gz
Tony
-------------------------------------------------------
This sf.net email is sponsored by: OSDN - Tired of that same old
cell phone? Get a new here for FREE!
https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
reply other threads:[~2002-09-09 14:20 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1031580513.632.3.camel@daplas \
--to=adaplas@pol.net \
--cc=linux-fbdev-devel@lists.sourceforge.net \
/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;
as well as URLs for NNTP newsgroup(s).