| FBA The Creator http://www.fbacreator.com/fbaforum/ |
|
| Is the print function 'slow'? http://www.fbacreator.com/fbaforum/viewtopic.php?f=5&t=73 |
Page 1 of 1 |
| Author: | Boiled Sweets [ Tue Jul 01, 2008 7:48 am ] |
| Post subject: | Is the print function 'slow'? |
I kind of like the little text output from the print command but wondering if it's 'slow' compared to using gfx fonts? |
|
| Author: | evilmaio [ Tue Jul 01, 2008 8:10 am ] |
| Post subject: | Re: Is the print function 'slow'? |
Well, the print function uses same technique of gfx fonts; actually it caches all calls with different colors when you call it with a new one, then it creates several font-set and finally it's drawed like a gfx font. So there shouldn't be any overhead (caching time is very fast). Be aware, if you 'print' a small text but with several different hundred colors, it will have to cache lot of font-set so you may experience slowdowns and higher memory requirements; for example this should be avoided: Code: function onmainloop() If you print "hello" with a 5x5 font or 50x50 font, you'll have same script processing overhead, but, of course, the 50x50 one will have higher gfx overhead because the higher area to draw. This doesn't means that printing 10000 small chars with 'print' will be always good (usually not). My suggestion is to keep font output and, in general, all draw steps reduced to minimun possibile, then testing performances live on your devices |
|
| Author: | Boiled Sweets [ Tue Jul 01, 2008 8:26 am ] |
| Post subject: | Re: Is the print function 'slow'? |
OK so imagine this scenario... In my menu I have a HELP page, that needs to contain a load of text and images that explain how to play the game. Would it be better (faster) to create the page with print and drawimage(s) or just design a simgle masked image (containing the text and images) in PhotoShop and render that? Ta. |
|
| Author: | evilmaio [ Tue Jul 01, 2008 8:30 am ] |
| Post subject: | Re: Is the print function 'slow'? |
IMHO: if you haven't to show animated objects or similar while opening your help section, i think you could use the 'print' statement because a slow down in framerate won't be noticeable while looking a static menu (of course if you reach 1 fps, you'll have troubles also to get input from stylus Instead, if you have to show also animations, using a pre-created image with photoshop, could be better! Just my opinion btw, usually the only way to answer these questions is testing on a real PDA |
|
| Page 1 of 1 | All times are UTC |
| Powered by phpBB® Forum Software © phpBB Limited https://www.phpbb.com/ |
|