Gdevelop: Overflowing text outline

Created on 22 Jul 2019  路  9Comments  路  Source: 4ian/GDevelop

Describe the bug

It seems that the text outline feature has a minor bug with some letters.
Here, I'm using the default font (black) and a 5 px white outline.
image

GD5b75

Most helpful comment

I'll look into this at the weekend.

All 9 comments

This is an pixiJS problem, but it's not fix in last v5.1.0
https://jsfiddle.net/3nrk51js/
This issue need to be report on pixi repo

A anwser from pixiJS issue

@Bouh That's related to your settings. Miter limit has to be a greater than zero value, zero itself is ignored by the canvas API. Change that (3 seems to look good), or use a different lineJoin type.

Miter limit is a parameters for outline in PixiJS

I'll look into this at the weekend.

Thanks keep me updated with your findings :)
EDIT: And thanks @Bouh for making a test and asking on Pixi.js github. I guess miterLimit can be increased safely, but would great to test on a few different texts/effects - or changing the join type.

I'll test different miter values on different sized text objects. I'd really like to use a hard coded value for this so we don't need to clutter the actions list with stuff that people don't understand at first sight (like the padding action).

Yes we almost certainly want to use a value that works for all/very large majority of texts

So it looks like the miterLimit is adding some kind of bevel to the letters:
grafik
grafik

A value of "3" like suggested in the pixijs issue indeed seems to work well.
I'll do some more testing with different font files and create a PR.

EDIT:
Looks like I can't get rid of it entirely by setting a hard coded value. Depending on the used font the spikes sometimes appear. Even though less often. (see the top of the "W" and the left side of the "M")
grafik

The issue should be solved with #1180 (or at least be greatly reduced)

Looks good to me
image
Thanks

Was this page helpful?
0 / 5 - 0 ratings

Related issues

4ian picture 4ian  路  3Comments

BWPanda picture BWPanda  路  4Comments

giusreds picture giusreds  路  4Comments

Jose-Moreno picture Jose-Moreno  路  5Comments

4ian picture 4ian  路  4Comments