A possible chromatic font technology breakthrough

Please try to keep all the discussions in the main forums on topic! If you have anything else, related to fonts, you want to share, please post it here!
Post Reply
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

A possible chromatic font technology breakthrough

Post by William »

I am wondering whether I have achieved a breakthrough in chromatic font technology research.

There are various threads about the possibility of chromatic font technology.

viewtopic.php?t=1469

viewtopic.php?t=1805

viewtopic.php?t=1461

Up until now I have thought that introducing chromatic font technology would require an addition within the TrueType and OpenType specifications.

However, I now realize that that is not a necessary stage.

I have been studying again the Petra Sancta method of expressing colours in monochrome. The Petra Sancta method dates from the Seventeenth Century as a method for depicting colours on armorial bearings in black and white books on heraldry. It uses vertical line shading for red, horizontal line shading for blue, upper left to lower right diagonal shading for green, lower left to upper right diagonal shading for purple, a dotted fill for yellow or gold.

I have previously used such shadings for authoring-time glyphs for colour in my Quest text font.

http://www.users.globalnet.co.uk/~ngo/courtcol.htm

http://www.users.globalnet.co.uk/~ngo/QUESTTXT.TTF

Recently I have been thinking of making a font to assist art experiments where the monochrome glyphs representing colours use the Petra Sancta shadings yet in such a manner that the relative percentages of black and white in a glyph is proportional to the grey scale luminance of the colour represented by that glyph. Thus the glyph for blue would be about 90% black with contours of horizontal lines, the glyph for red would be about 70% black with contours of vertical lines, the glyph for green would be about 41% black with contours of upper left to lower right diagonals, the glyph for yellow would be about 11% black with contours of dots. The font could then be used to produce pictures. I am also thinking of having a wider choice of glyphs so that other colours could be represented in monochrome.

During the course of this, I thought of the idea that chromatic fonts could be produced using the existing TrueType and OpenType specifications using an existing TrueType font producing program such as FontCreator by specifying some rules for a font indicating to a rendering system that a chromatic contour was intended. Such rules would include adding a tiny counterclockwise contour onto any clockwise contour that was to be displayed in other than the foreground colour. I have thought that a good name for "a tiny counterclockwise contour intended to indicate the colour of the clockwise contour within which it is contained, both if that colour is indicated as an absolute colour and if that colour is indicated as a colour index in a colour palette" could be a cencontour. I thought of the name cencontour from the name cencharacter. It was the name of a proceduce call in the hardcopy plotter graphics package for the Elliott 803 mainframe computer upon which I first used computer graphics. A cencharacter is one of those small graphics drawn around a point on a scientific graph so that its position can be clearly noticed. There is a circle, a square, a triangle and so on. I remember that cencharacter(4) was a butterfly style design made up of four straight lines, two of which passed through the data point itself, whereas the circle, square and triangle did not actually connect with the data point itself.

It occurs to me that if cencontour shapes a few font units wide and tall in various shapes were specified and allocated in a list to have various meanings, then a chromatic rendering system could detect the cencontours and then for each cencontour assign colour information to the clockwise contour in which the cencontour was placed, before discarding the cencontour, so that the shape of the cencontour would not be rendered yet the colour information which it indicated could be used.

I am wondering how big a job it would be for a rendering system to extract this information from cencontours, bearing in mind that they are first detected by being counterclockwise and tiny, just a few font units wide or tall.

Using cencontour technology could mean that chromatic font technology could be implemented without needing any changes at all to the TrueType and OpenType specifications. Also, as a clockwise contour without a cencontour within it would be rendered in foreground colour, the cencontour invention can be used such that a rendering system for such chromatic fonts would display an existing monochrome font normally.

William Overington

23 November 2007
Erwin Denissen
Moderator
Moderator
Posts: 11155
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Post by Erwin Denissen »

Since a rasterizer decides how to display outlines, you better ask this question to Microsoft, FreeType, etc. Personally I don't think they will take your proposal very seriously, but it might lead to an interesting discussion.
Erwin Denissen
High-Logic
Proven Font Technology
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

Thank you for replying.

> Since a rasterizer decides how to display outlines, you better ask this question to Microsoft, FreeType, etc.

I had not heard of FreeType, but found it on the web.

http://www.freetype.org/

> Personally I don't think they will take your proposal very seriously, but it might lead to an interesting discussion.

I am wondering why you think that they will not take the cencontour invention very seriously.

In any case, what I regard as one of the key advantages of the cencontour invention is that it does not need any alterations to the TrueType or OpenType specifications, nor does it need any alterations to font making software.

It seems to me that someone who can start with the source code of the software of an existing rendering system and who also has software tools to do the job and who knows how to program using them could potentially implement a rendering system for cencontour-encoded chromatic fonts on an independent basis, so that a niche market could be produced.

Certainly, it would be nice if cencontour-based chromatic font technology were implemented in the Portable Document Format (pdf) specification, yet it appears to me at present that maybe great progress could be made by an independent implementer who could perhaps produce a desktop-publishing package which implements cencontour-based chromatic font technology.

I have been thinking of the design of cencontours. Polyominos may well be useful for many of them.

http://en.wikipedia.org/wiki/Polyomino

http://en.wikipedia.org/wiki/Image:Heptominoes.gif

Naturally, for cencontours orientation makes a difference, so there are more than one possible orientation for some of the polyominos shown in the picture. Also, the cencontours do not need all to have the same number of squares within them. A basic set of cencontours would not contain many designs, I am thinking in terms of maybe three for non-specific decoration colours and some for specific colours in order to get started. After that, the number of different cencontour designs in an enlarged set would depend upon such factors as the level of enthusiasm for the effects which could be produced and the level of difficulty in adding extra cencontour designs into the rendering software.

I am thinking of each square being 1 font unit by 1 font unit.

I am thinking that this is an exciting development involving aspects of physics, mathematics, software engineering and art.

William Overington

23 November 2007
Erwin Denissen
Moderator
Moderator
Posts: 11155
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Post by Erwin Denissen »

Personally I welcome all new inventions, but if I'm correct one of the basic principles of TrueType and OpenType font technology is, "a font does not contain colors".
William wrote:I am wondering why you think that they will not take the cencontour invention very seriously.
There is no gain for them.
How many people would benefit from this?
It might not be backwards compatible, or it breaks current specs.

PostScript Type 3 fonts can contain color information, but I've never looked into this as it seems that never really made it.
http://en.wikipedia.org/wiki/PostScript_fonts
http://kb.adobe.com/selfservice/viewCon ... &sliceId=2
Erwin Denissen
High-Logic
Proven Font Technology
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

Thank you for replying.

> .... , but if I'm correct one of the basic principles of TrueType and OpenType font technology is, "a font does not contain colors".

Well, that may well have been the case until today but that situation has now been, thus far only theoretically as far as I know, overtaken by progress since the invention of the cencontour invention and its publication.

> There is no gain for them.

Well, each person or organization may assess whether he, she or it may gain from implementing cencontour technology in a wordprocessor or a desktop-publishing package.

What he, she or it might wish to try gaining from trying to implement cencontour technology may vary greatly from person to person.

Each person or organization could potentially spend time and effort in trying to implement cencontour technology and make no gain, whatever gain may mean to him, her or it.

However, if he, she or it successfully implemented cencontour technology and made publicly available a wordprocessor or desktop-publishing package using it, then he, she or it would be involved in a forward step in font technology.

> How many people would benefit from this?

I do not know.

> It might not be backwards compatible, or it breaks current specs.

As far as I am aware it would be backwards compatible and would not break current specifications. A clockwise contour without a cencontour within it would be displayed in foreground colour with no recommendation for colour made by the font. If a wordprocessor or desktop-publishing package, herein called ChromaticOne for ease of discussion, were produced, then using it with an existing font would cause the font to be rendered exactly as it is now. Yet if ChromaticOne used a font with cencontours in it, it could utilize the information contained in the cencontours to decide whether the containing clockwise contours were displayed in foreground colour or a decoration colour. Which particular colours were used in a display would depend upon a combination of the end user colour settings for foreground colour and decoration colours together with colours recommended by the font together with the relative strength of the strength of the end user choice of whether to use end user chosen colours and the strength of the recommendations about colours made by the font.

For example, a font might have letters with holly leaves and berries decoration. The font could weakly recommend blue as the colour of the letters and strongly recommend green for the holly leaves and strongly recommend red for the berries. So, if the end user wanted font colours, there would be blue letters with green leaves and red berries. All of these colours could be overridden by the end user if desired, yet a medium level override would produce letters of another colour yet still keep green for the leaves and red for the berries.

William Overington

23 November 2007
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

The original post that was here and its supplements are now rewritten in the post of 26 November 2007.
Last edited by William on Mon Nov 26, 2007 9:43 am, edited 2 times in total.
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

The note that was here is now obsolete.
Last edited by William on Mon Nov 26, 2007 9:45 am, edited 1 time in total.
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

The note that was here is now obsolete.
Last edited by William on Mon Nov 26, 2007 9:44 am, edited 1 time in total.
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

Here is a rewritten version of the design for the structure for cencontours.

The first stage is for some cencontours which can be 6 font units tall and 2, 3, 4 or 5 font units wide.

The cencontours are drawn as counterclockwise contours, yet, although when viewed normally they are white upon a black background, please regard the pixels included within the cencontour as having a value of 1 and pixels not included within the cencontour as having a value of 0.

The general structure of the design which I have produced thus far is as follows in a 6 pixel tall by 5 pixel wide grid.

11gfe
01000
a1pru
b1qst
c1000
d1zyx

However, at present, c, d, e, u, x and y are all set to 0, so the structure is as follows.

11gf0
01000
a1pr0
b1qst
01000
01z00

The seven pixels which are always set at one provide a top left corner marker for a 6 x 5 matrix of Boolean states and a spine upon which to attach other pixels if such attachment is desired.

The pixels a and b define the class to which the contour within which the cencontour is placed belongs.

b a

0 0 the contour is displayed in foreground colour
0 1 the contour is displayed in decoration colour 1
1 0 the contour is displayed in decoration colour 2
1 1 the contour is displayed in decoration colour 3

All of the other pixels refer to colour suggestion. If they are all set at 0 then there is no colour suggestion being made.

f g
0 0 The colour suggestion is for this contour only.
0 1 The colour suggestion is for all contours of this class within the glyph except for those that have their own colour suggestion.
1 1 The colour suggestion is for all contours of this class within the font except for those that have their own colour suggestion or have a colour suggestion within their own glyph.

Please note that f cannot be set to 1 if g is set to 0.

z

0 The colour suggestion is just an ordinary suggestion.
1 The colour suggestion is a strong suggestion.

The pixels p, q, r, s, t are used to suggest specific colours, except that if they all have value 0 then no suggestion is being made.

Although there are five pixels, not all permutations of them are allowed as the resulting shape of the cencontour must be in one contiguous piece, corner joins not being sufficient. Thus the table does not contain any entries for when both p and q have values of 0.

The colours specified for the various shapes are based on the Petra Sancta system used for expressing colours in some black and white printed books about heraldry.

p q r s t

0 1 0 0 0 yellow, one dot, lower
0 1 0 0 1 not possible
0 1 0 1 0 light brown, horizontal line, lower
0 1 0 1 1 dark brown, horizontal line, lower plus tail
0 1 1 0 0 not possible
0 1 1 0 1 not possible
0 1 1 1 0 pink, lower right corner
0 1 1 1 1 orange, lower right corner plus tail
1 0 0 0 0 white, one dot, upper
1 0 0 0 1 not possible
1 0 0 1 0 not possible
1 0 0 1 1 not possible
1 0 1 0 0 blue, horizontal line, upper
1 0 1 0 1 not possible
1 0 1 1 0 magenta, upper right corner
1 0 1 1 1 cyan, upper right corner plus tail
1 1 0 0 0 red, vertical line
1 1 0 0 1 not possible
1 1 0 1 0 light grey, lower left corner
1 1 0 1 1 dark grey, lower left corner plus tail
1 1 1 0 0 green, upper left corner
1 1 1 0 1 not possible
1 1 1 1 0 dark green, two by two square
1 1 1 1 1 black, two by two square plus tail

This provides a total of fifteen colours.

Hopefully these notes will provide a basis for research and development.

My current thinking is that if the pixel, in row 2, column 1, which always has a value of 0 in the above were to have a value of 1, then that would indicate a larger cencontour structure, maybe as much as twelve pixels by twelve pixels or even more, in which much more detailed information about colour could be encoded. I am thinking that such an encoding could be quite orderly, with the cencontour having an appearance something like an aerial view of boats moored in a marina, where the boats correspond to the pixels of colour information. Typically only a few such large cencontours might be necessary in a font. They could set up the colours for foreground and the various decoration colours. Most cencontours could be small cencontours which simply identify whether the contour to which they refer is to be displayed in the foreground colour or one of the decoration colours.

A clockwise contour which does not contain a cencontour is regarded as if it contained a cencontour of the above design where all of the values a, b, g, f, z. p, q, r, s and t have a value of 0. This means that existing monochrome fonts would be displayed as they are now and also means that there is an efficiency in coding in that contours which are to be displayed in foreground colour do not necessarily need a cencontour within them: maybe in some fonts only one of the contours which are to be displayed in foreground colour would have a cencontour, that cencontour being used to suggest a colour to be used as foreground colour for the whole font.

Please note that the system, at present, does not specify a way to change background colour.

The above notes now allow that fonts containing cencontours can be produced using FontCreator. Any such fonts cannot, at the time of writing these notes, be displayed as chromatic fonts. At the present time I am unable to produce a rendering program. Whether someone else produces a rendering program is something for the future.

William Overington

26 November 2007
William
Top Typographer
Top Typographer
Posts: 2038
Joined: Tue Sep 14, 2004 6:41 pm
Location: Worcestershire, England
Contact:

Post by William »

A small chromatic font to the above specification is now available from a link in the following thread.

viewtopic.php?t=2011

There is only one glyph, encoded as a letter A. A space of the same width is also available. The glyph is of a holly leaf with some berries.

Small though the font is, it should be capable of being used as a demonstration of chromatic font technology if people choose to try to implement a chromatic wordprocessor application.

William Overington

22 December 2007
Post Reply