本文整理汇总了C#中IFont.drawInto方法的典型用法代码示例。如果您正苦于以下问题:C# IFont.drawInto方法的具体用法?C# IFont.drawInto怎么用?C# IFont.drawInto使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IFont
的用法示例。
在下文中一共展示了IFont.drawInto方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: drawString
/// <summary>
/// Submit a text string of sprites for drawing in the current batch.
/// </summary>
/// <param name="batcher">Batcher.</param>
/// <param name="font">Font.</param>
/// <param name="text">Text.</param>
/// <param name="position">Position.</param>
/// <param name="color">Color.</param>
/// <param name="rotation">Rotation.</param>
/// <param name="origin">Origin.</param>
/// <param name="scale">Scale.</param>
/// <param name="effects">Effects.</param>
/// <param name="layerDepth">Layer depth.</param>
public static void drawString( this Batcher batcher, IFont font, StringBuilder text, Vector2 position, Color color,
float rotation, Vector2 origin, Vector2 scale, SpriteEffects effects, float layerDepth )
{
Assert.isFalse( text == null );
if( text.Length == 0 )
return;
font.drawInto( batcher, text, position, color, rotation, origin, scale, effects, layerDepth );
}