Earcut with createText

Hi all, I’m trying to use the nice new createText method, but I see it requires earcut.

In theory that’s no problem, as I do this elsewhere in my project like here when I create a polygon this way:

import * as earcut from “earcut”;

const roundedPlane = CreatePolygon(
shape: shape,
sideOrientation: Mesh.DEFAULTSIDE,

But I see that createText doesn’t take earcut as an argument. So I’m not really sure how to make createText recognize the earcut dependency. Any ideas? I looked in the constructor and didn’t see any other obvious places.

In the create polygon method it’s documented clearly where earcut goes in the constructor: BABYLON | Babylon.js Documentation (babylonjs.com)

You are right! Let me fix that and add an entry point for earcut

Here we are:
Add earcut entry point by deltakosh · Pull Request #13902 · BabylonJS/Babylon.js (github.com)


Thank you kindly @Deltakosh ! Soon to make 3d text a Frame asset. :slight_smile:


@Deltakosh , any estimate on when the next release will be cut? Nothing urgent on our side, just for our planning purposes!

Thursday evening but I can generate a patch if you need it before ?

1 Like

Would be really nice @sebavan !! Then we could include it in our Frame release later this week, I think!

Here we are:)

1 Like

Amazing, thanks so much @Deltakosh and @sebavan , importing that in now!

1 Like

Please share some pics when done :smiley:

starry text

Here’s a sneak peek haha. Users are going to have a blast with this @Deltakosh !

Ohh!! Excellent:)