Isn't the bitmap text of 'starling' sharing the same bitmap data?

.
Isn’t the bitmap text of ‘starling’ sharing the same bitmap data?
.
I just conducted a test to batch modify the display content of bitmap text in frame update events. On my computer, I can only run 120 bitmap texts simultaneously at 60fps, which is stable. Judging from the number of draws, it seems that multiple bitmap texts do not share the same bitmap data.
.
Is this the main reason for the performance bottleneck of bitmap text?
.
I conducted the same test using ‘creatjs’ again, and surprisingly, the bitmap text of’ creatjs’ can run stably at 3500 60fps. As far as I know, the bitmap text of ‘creatjs’ can share a copy of sprite table data.
.

openfl starling 60fps 120
createjs 60fps 3500

Perhaps share your code, so we can test and review ourselves?

Most likely, the reason for the number draw calls is because the TextField’s batchable property defaults to false. Try setting it to true.

.
Yes, I have set “batchable” to “true”, and the drawing is only done once. I tested again and batch modified the content of the created bitmap text in a frame update event. The bitmap text increased from 120 to 150, which is a small improvement, but still cannot compare with the bitmap text performance of “creatjs”. This is the result of testing on my computer (an old computer from over 10 years ago)
.

.

.
Is there anyone like me? In order to improve the distortion of bitmap fonts when displaying very small fonts, I have doubled the width and height of “Starling. current. viewPort”
.
May I ask if the larger the ‘starling’ viewport, the more performance it consumes?
.
Is anyone doing the same thing as me?
.

.
After reading the “API” instructions, there is a character limit for “batchable”! The explanation states that batch processing can only handle up to 15 characters, so I changed the random number to “Int” type, displaying 10 characters, and increased the number of bitmap text to 200
.

Yes, a larger view port will likely require more resources to render.

1 Like