Esempio n. 1
0
 public void AddChar(char c, float x, float y, LColor color)
 {
     this.charCurrent = c;
     if (charCurrent < totalCharSet)
     {
         intObject = charArray[charCurrent];
     }
     else
     {
         intObject = (IntObject)CollectionUtils.Get(customChars, (char)charCurrent);
     }
     if (intObject != null)
     {
         if (color != null)
         {
             SetImageColor(color);
         }
         if (antiAlias)
         {
             fontBatch.Draw(colors, x, y, intObject.width * fontScale,
                            intObject.height * fontScale, intObject.storedX, intObject.storedY,
                            intObject.storedX + intObject.width, intObject.storedY
                            + intObject.height);
         }
         else
         {
             fontBatch.Draw(colors, x, y, intObject.width,
                            intObject.height, intObject.storedX, intObject.storedY,
                            intObject.storedX + intObject.width, intObject.storedY
                            + intObject.height);
         }
         if (colors != null)
         {
             colors = null;
         }
     }
 }
Esempio n. 2
0
 public void Draw(float x, float y, float width, float height)
 {
     if (isBatch)
     {
         batch.Draw(colors, x, y, width, height);
     }
     else
     {
         GLEx.Self.DrawTexture(this, x, y, width, height);
     }
 }