Re: Google's NotoColorEmoji-Regular.ttf not rending
> Thanks, ftview is a great help. However it does not display > NotoColorEmoji-Regular.ttf Well, this font contains a 'COLR' v1 table, which `ftview` doesn't support – you have to render the layers by yourself.[*] Note that 'COLR' v1 support in FreeType is not complete yet (but Dominik is working on it). It also contains an 'SVG' table, and this gets displayed with the current git version of FreeType, assuming that you are linking to 'librsvg'. However, there is a problem somewhere, since a simple ``` ftview 100 NotoColorEmoji-Regular.ttf ``` takes 24s to display the first few glyphs, which is unacceptably slow. This is with my system's librsvg version 2.52.6. Using `kcachegrind` to look at the output from ``` valgrind --tool=callgrind ftview -k q -f 5 400 NotoColorEmoji-Regular.ttf ``` (from a `make devel` build, which includes the FreeType library statically) to display the glyph with index 5 at a resolution of 400px (attached), it seems that most time gets used in 'librsvg' (51%) and 'libcairo' (30%). Moazin, please have a look! Werner [*] That FreeType supports rendering of 'COLR' v0 is just a convenience and not recommended for all use cases. ftview.callgrind.out.xz Description: Binary data
Re: Google's NotoColorEmoji-Regular.ttf not rending
Hi Werner, Thanks, ftview is a great help. However it does not display NotoColorEmoji-Regular.ttf Here is the origin of the file exactly: paul@paul-LinuxBox:~/git/fonts$ cat .git/config [core] repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true [remote "origin"] url = https://github.com/google/fonts.git fetch = +refs/heads/*:refs/remotes/origin/* [branch "main"] remote = origin merge = refs/heads/main paul@paul-LinuxBox:~/git/fonts$ ls -la ofl/notocoloremoji total 23540 drwxr-xr-x2 paul paul 4096 Sep 13 11:01 . drwxr-xr-x 1532 paul paul49152 Sep 13 11:02 .. -rw-r--r--1 paul paul 200 Sep 13 11:01 DESCRIPTION.en_us.html -rw-r--r--1 paul paul11963 Sep 13 11:01 METADATA.pb -rw-r--r--1 paul paul 24066744 Sep 13 11:01 NotoColorEmoji-Regular.ttf -rw-r--r--1 paul paul 4386 Sep 13 11:01 OFL.txt -rw-r--r--1 paul paul 167 Sep 13 11:01 upstream.yaml Paul On 9/19/22, Werner LEMBERG wrote: >> >> I have had great success with Google's older NotoColorEmoji.ttf and >> NotoEmoji-Regular.ttf released by Google in 2019. >> >> However they have since updated their fonts. They now have a font >> NotoColorEmoji-Regular.ttf > > They have? Looking at > > > https://github.com/googlefonts/noto-emoji/blob/main/fonts/NotoColorEmoji.ttf > > the most recent color emoji font (v2.038 from 2022-Sept-16) is still > called `NotoColorEmoji.ttf`. Whence did you get the font? > >> I use the code below to load 😀 0x1f600. Further below is the gdb dump >> of the glyph struct with the non-working and working font when trying >> to load the same unicode code-point. >> >> As you can see the bitmap struct is not populated. >> >> Can anyone help? > > Please have a look how `ftview` is doing this. > > > https://gitlab.freedesktop.org/freetype/freetype-demos/-/blob/master/src/ftview.c > > The abovementioned font from the git repository gets loaded just fine. > > > Werner >
Re: Google's NotoColorEmoji-Regular.ttf not rending
Maybe Paul downloaded that font from https://fonts.google.com/noto/specimen/Noto+Color+Emoji? That version of the font does not contain CBDT/CBLC *bitmap* color tables, but only COLRv1 and OT-SVG *vector* color tables. On Mon, Sep 19, 2022 at 4:57 PM Werner LEMBERG wrote: > > > > I have had great success with Google's older NotoColorEmoji.ttf and > > NotoEmoji-Regular.ttf released by Google in 2019. > > > > However they have since updated their fonts. They now have a font > > NotoColorEmoji-Regular.ttf > > They have? Looking at > > > https://github.com/googlefonts/noto-emoji/blob/main/fonts/NotoColorEmoji.ttf > > the most recent color emoji font (v2.038 from 2022-Sept-16) is still > called `NotoColorEmoji.ttf`. Whence did you get the font? > > > I use the code below to load 😀 0x1f600. Further below is the gdb dump > > of the glyph struct with the non-working and working font when trying > > to load the same unicode code-point. > > > > As you can see the bitmap struct is not populated. > > > > Can anyone help? > > Please have a look how `ftview` is doing this. > > > https://gitlab.freedesktop.org/freetype/freetype-demos/-/blob/master/src/ftview.c > > The abovementioned font from the git repository gets loaded just fine. > > > Werner >
Re: Google's NotoColorEmoji-Regular.ttf not rending
> > I have had great success with Google's older NotoColorEmoji.ttf and > NotoEmoji-Regular.ttf released by Google in 2019. > > However they have since updated their fonts. They now have a font > NotoColorEmoji-Regular.ttf They have? Looking at https://github.com/googlefonts/noto-emoji/blob/main/fonts/NotoColorEmoji.ttf the most recent color emoji font (v2.038 from 2022-Sept-16) is still called `NotoColorEmoji.ttf`. Whence did you get the font? > I use the code below to load 😀 0x1f600. Further below is the gdb dump > of the glyph struct with the non-working and working font when trying > to load the same unicode code-point. > > As you can see the bitmap struct is not populated. > > Can anyone help? Please have a look how `ftview` is doing this. https://gitlab.freedesktop.org/freetype/freetype-demos/-/blob/master/src/ftview.c The abovementioned font from the git repository gets loaded just fine. Werner
