Closed nulld closed 3 years ago
Ah yes, that is a bit unfortunate. It should be an unusual (but not unheard of) for the fonts to get recreated. I think the best approach would be to re-attach to the GC during the getBytes call from inside the NME dll. This would allow good operation most of the time.
Font.cpp has an AutoGCUnblocking object commented out. I think this was because I was waiting for 4.1 release. Putting this back in may solve the problem.
Thanks again! Seem it fixed my problem https://github.com/haxenme/nme/pull/684
Get used preemptive gc mode
stage.setPreemtiveGcFrequency(180);
And sometimes getting this crash:
Guess it's because of this function isn't really gc free: https://github.com/haxenme/nme/blob/master/src/nme/display/Stage.hx#L618
@hughsando, what do you think, will it be good idea to shrink gc free zone here? I meen something like this: