Jump to content
This forum will be closing down. Please move to the respective dedicated project forums.

Creating text with a group


Jackal16
 Share

Recommended Posts

Yeah thats what I went for in the end.

 

Looking at the firefox canvas debugger the text seems to require a draw call for each bit of text - does grouping them stop this and make them draw together?

Well, to draw the text you have to draw each letter. It should only be drawn again after that only if you update the text (or some of it's properties).

Link to comment
Share on other sites

Phaser.Text uses a single canvas element to render the text to, so it's one texture and one draw call, regardless how much text there is.

 

However BitmapText uses one Sprite for each character within the text string. If the text isn't going to change you can cache it as a bitmap, but if you're using it for something that updates often like a score or health counter then this isn't a sensible option.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...