(I said I'd write fewer 'stupid programming tricks' articles, but that didn't mean I'd stop completely. )
I was asked about getting started with PlayStation Mobile. They've already beaten me to it at Games From Scratch, and I used some of their tutorials to get up-and-running. Nice work over there.
The biggest tip I could give right now - I've tried three different ways to render text on the Vita with PSM: UIComposer, emulating some of their demos, and using the FontMap stuff from their GameEngine2D. UIComposer was unusably slow - it may be fine for a front end but not an in-game HUD. Some of their demos render text - apparently on the CPU - to a texture, then render that texture to the screen. Better, because you can cache what you're doing, but still not great. The fastest result was the FontMap. Even if you weren't planning on using their 2D engine (I wasn't, since this is a port of sixty second shooter we're talking about) it's probably worth using it just as a quick way to get fonts in your game that run quite fast ... and some UI sprites.
You can use the 2D engine on top of the 3D easily, by setting it to update manually and setting the scene to not clear. There's some sample code here. I've ended up using the 2D engine for my entire UI.
The problem with FontMap right now seems to be the font is packed a little tightly in its bitmap, and depending on your choice of font size and rendering size you can see bleed from one glyph into the next. Messing with sizes let me work around that.
(Update 8/31/12:) Also - be sure to use the Label() class to draw your fonts, rather than the DrawTextWithFontMap, which currently can make the text appear squished.
(Update 9/1/12:) Also - your font may appear fine on some resolution devices but on others show the glyph-bleed. Messing around with the FontMap size and width can fix that. Your font may appear fine with half the width - mine did.
Comments