Operating system or device, Godot version, GPU Model and driver (if graphics related):
Windows, Godot 2.1.4
Issue description:
Godot does not render many emojis. I attempted to use a RichTextLabel containing the text:
te๐x๐t๐ผแดฅโป๐โโฎโฏ๐๐ก๐ข๐ญ๐ฆ๐ป
And instead what renders is:

I did this using a dynamic font for the node and I tried loading EmojiOneColor-SVGinOT.ttf, OpenSansEmoji.ttf, and unifont-10.0.06.ttf all with very limited success. The EmojiOneColor comes with a demo which, when opened in Chrome, renders just fine in B&W including many of the symbols I'm looking to use. Finding an adequate demo of the other fonts is a bit more difficult than I imagined.
Maybe related to #6834 , 3 have better support of fonts with special characters.
allow using them in code editor too like variables ๐จ
@curly-brace well, if you manage to get a font with emoji in the format supported by the editor it should be possible (settings uses a .font, I have no idea what is that).
You can now use any TTF font in the editor itself (code editor included) and in games, so this should work fine.
If a TTF font contains glyphs and Godot doesn't render them, that needs to be investigated.
You can now use any TTF font in the editor itself (code editor included) and in games, so this should work fine.
Note that colored fonts aren't currently supported, though (this is important as most emoji fonts make use of colors).
Is working in editor, labels, node names, gdscript, debugger, terminal output.
Tested with https://github.com/eosrei/twemoji-color-font (of course, color does not work).
I did not even know color fonts existed, I suppose we could detect this
somehow and render to color?
On Mon, Jan 15, 2018 at 1:58 PM, eon-s notifications@github.com wrote:
Is working in editor, labels, node names, gdscript, debugger, terminal
output.Tested with https://github.com/eosrei/twemoji-color-font (of course,
color does not work).โ
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/issues/10873#issuecomment-357738745,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AF-Z2xlXISG7Dcfw-umuc_FmV6JfHmNzks5tK4OxgaJpZM4PKmOP
.
I'm trying on this.
I don't know why but it works only with Google Noto Emoji font... :cry:

I'm amazed, how are you detecting that the font needs to use a RGB texture
and raster to it?
On Mon, Jan 15, 2018 at 9:45 PM, volzhs notifications@github.com wrote:
I'm trying on this.
I don't know why but it works only with Google Noto Emoji font... ๐ข[image: screenshot from 2018-01-16 09-43-34]
https://user-images.githubusercontent.com/8281454/34966795-d05abee0-faa1-11e7-8648-bbf41bf5a0f0.pngโ
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/issues/10873#issuecomment-357821492,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AF-Z29pDTA5OX5FmojSWM4l7O4Ck6tQEks5tK_E0gaJpZM4PKmOP
.
detecting color
bool has_color = FT_HAS_COLOR(face);
int error = FT_Load_Char(face, p_char, has_color ? FT_LOAD_COLOR : FT_LOAD_DEFAULT);
to raster
case FT_PIXEL_MODE_BGRA:
wr[ofs + 2] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 0];
wr[ofs + 1] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 1];
wr[ofs + 0] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 2];
wr[ofs + 3] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 3];
break;
need to take care of DynamicFontAtSize::textures though...
I'm not sure that fonts downloaded from internet is really colored font beside google noto color emoji...
or I missed something to do with freetype to render rest colored fonts.
ah yeah, you need to find out if at least one of the chars uses color so
you create a color texture... either that or use a separate texture for
chars with colors, not sure.
On Mon, Jan 15, 2018 at 10:33 PM, volzhs notifications@github.com wrote:
detecting color
bool has_color = FT_HAS_COLOR(face);int error = FT_Load_Char(face, p_char, has_color ? FT_LOAD_COLOR : FT_LOAD_DEFAULT);
to raster
case FT_PIXEL_MODE_BGRA:
wr[ofs + 2] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 0];
wr[ofs + 1] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 1];
wr[ofs + 0] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 2];
wr[ofs + 3] = slot->bitmap.buffer[i * slot->bitmap.pitch + (j << 2) + 3];
break;need to take care of DynamicFontAtSize::textures though...
โ
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/issues/10873#issuecomment-357828031,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AF-Z28fKVYrp33ZvFSwnGQGrNahEQgTYks5tK_xjgaJpZM4PKmOP
.
yeah. i've done that too so far.
problem is checking and loading colored font correctly.

as my research, freetype supports only CBDT format color font which Google supports also.
if font is CBDT format, it works fine.
now need to handle size of font rendering.

:sunglasses: finally....
need to clean up codes, but also need to go to bed...
will make a PR, maybe tomorrow
Most helpful comment
:sunglasses: finally....
need to clean up codes, but also need to go to bed...
will make a PR, maybe tomorrow