Project

General

Profile

Actions

Feature #13876

closed

tem: we should support CSI 38 and 48 sequences for RGB colors

Added by Toomas Soome almost 2 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
kernel
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Hard
Tags:
Gerrit CR:
External Bug:

Description

Add support for CSI 38;2 and CSI 48;2 sequences to use RGB colors.

We already do support 256 color mode (CSI 38;5;X m, and CSI 48;5;X m, where X is value from range 0-255). When we are using framebuffer mode with depth 15/16/24 or 32, we could use more colors. To achieve this, add support for CSI 38;2;r;g;b m and CSI 48;5;r;g;b m, with r, g and b being values from 0-255.

This implementation does cover both boot loader and kernel tem. The initial install does not implement support for tem default colors as RGB values (adding such support in certainly possible, but will also require update of early start kernel code).

This feature does require version up of visual_io protocol, which is used to send data from tem (console terminal emulator) to gfx_private (low level driver for console hardware), this is because the current visual_io interface is using 8-bit color values.

when CSI 38/48 is used with unsupported framebuffer mode, the sequences are ignored and the console color will not be changed.

Testing done: tested both loader and kernel console in text mode but also depths 8, 16 and 32.
Tested with intel gfx by myself and nvidia by Reginald Beardsley:

Toomas,

I just typed in the corrected string to a mate-term and got green text on a white background :-) I think it works. Now confirmed by killing X and rebooting to a text console. I got green text. "svcadm enable lightdm' starts X and brings up lightdm properly. In doing this I've exercised X and MATE a good bit. I think everything is OK.

Actions #1

Updated by Electric Monk almost 2 years ago

  • Gerrit CR set to 1550
Actions #2

Updated by Toomas Soome almost 2 years ago

  • Description updated (diff)
Actions #3

Updated by Electric Monk almost 2 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

git commit fa9eb22261c7b7a35c7a6957acb3c2b26c39e15b

commit  fa9eb22261c7b7a35c7a6957acb3c2b26c39e15b
Author: Toomas Soome <tsoome@me.com>
Date:   2021-06-23T20:38:00.000Z

    13876 tem: we should support CSI 38 and 48 sequences for RGB colors
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Approved by: Joshua M. Clulow <josh@sysmgr.org>

Actions #4

Updated by Electric Monk almost 2 years ago

git commit 6a8b10fec05a8e99fc3f7ca1dc0f8962a075a165

commit  6a8b10fec05a8e99fc3f7ca1dc0f8962a075a165
Author: Toomas Soome <tsoome@me.com>
Date:   2021-06-24T15:05:55.000Z

    13876 tem: we should support CSI 38 and 48 sequences for RGB colors (fix SPARC)
    Reviewed by: Andrew Stormont <andyjstormont@gmail.com>
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Reviewed by: Andy Fiddaman <andy@omnios.org>
    Approved by: Garrett D'Amore <garrett@damore.org>

Actions

Also available in: Atom PDF