POV-Ray : Newsgroups : povray.off-topic : musical notation font : Re: musical notation font Server Time
4 Jun 2024 08:48:03 EDT (-0400)
  Re: musical notation font  
From: clipka
Date: 18 Jun 2018 12:38:48
Message: <5b27e018$1@news.povray.org>
Am 18.06.2018 um 17:07 schrieb jr:
> hi,
> 
> Le_Forgeron <jgr### [at] freefr> wrote:
>> You would like support of unicode 1D100...1D1FF like in freeserif
> 
> I wrote a little test scene to see but cannot access that range.
> 
> the docs (3.3.1.9.4 + 3.3.2.7.2) specify a 64K limit on the chr() function, as
> well as for the corresponding literal ("\uNNNN").
> 
> how does one access font glyphs located after the limit?

At present you simply can't: POV-Ray's innards have never grown beyond
the old UCS-2 standard (yet); in other words, it only supports
characters from the Basic Multilingual Plane, period.

Here are the key components that have to be changed to get there:

(1a) The `\uNNNN` escape sequence has to be extended to allow for 6 hex
digits; in the current parser update, I'm implementing this as
`\Unnnnnn` (note the uppercase U); or

(1b) the `\uNNNN` escape sequence has to be re-defined to specify UTF-16
code units (rather than UCS-2 code points).

(2) The internal string representation in the parser has to be changed
from UCS-2 to /something/ else; I'm leaning towards UTF-32 encoded UCS-4
because it means keeping string length related stuff simple and
unambiguous. (This would also extend the numeric range of the `chr()`
and `asc()` functions.)

(3) The TrueType handling code needs to be extended to look for `cmap`
types 0/4 and 3/10 (currently: 0/3, 1/0, 3/0 and 3/1), and support
`cmap` format 12.0 (currently: 0, 4 and 6).


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.