首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > 移动开发 >

转:AndEngine中的字体加载及使用

2012-08-11 
转:AndEngine中的字体加载及应用AndEngine中的字体加载及应用???AndEngine中的字体加载及应用public void

转:AndEngine中的字体加载及应用

AndEngine中的字体加载及应用

?

?

?

AndEngine中的字体加载及应用public void onLoadResources() {this.mTexture1 = new Texture(256, 256, TextureOptions.BILINEAR_PREMULTIPLYALPHA);FontFactory.setAssetBasePath("font/");this.mPlokFont = FontFactory.createFromAsset(this.mTexture1, this, "Plok.ttf", 30, true, Color.BLACK);this.mEngine.getTextureManager().loadTexture(this.mTexture1);this.mEngine.getFontManager().loadFonts(this.mPlokFont);}public Scene onLoadScene() {this.mEngine.registerUpdateHandler(new FPSLogger());final Scene scene = new Scene(1);scene.setBackground(new ColorBackground(0.09804f, 0.6274f, 0.8784f));scene.getTopLayer().addEntity(new Text(140, 300, this.mPlokFont, "hello!"));return scene;}

?

?

?

转自:http://361tg.net/read.php?17

热点排行