示例#1
0
 public void DrawChar(string txt, int color, DrawFont font, float x, float y, int angle, IDrawEffect[] effects)
 {
     Brush br = new SolidBrush(Color.FromArgb(color));
     Font sysFont = this.DrawFontToSharpFont(font);
     this.m_graphics.DrawString(
         txt,
         sysFont,
         br,
         new PointF(x, y)
         );
 }
示例#2
0
 public void FillRectangle(int color, float x, float y, float width, float height, IDrawEffect[] effects)
 {
     this.m_graphics.FillRectangle(new SolidBrush(Color.FromArgb(color)), x, y, width, height);
 }
示例#3
0
 public void DrawRectangleLine(int lineWidth, int color, float x, float y, float width, float height, DrawLineStyle lineStyle, IDrawEffect[] effects)
 {
     this.m_graphics.DrawRectangle(new Pen(Color.FromArgb(color)), x, y, width, height);
 }
示例#4
0
 public void DrawLine(int width, int color, float x1, float y1, float x2, float y2, DrawLineStyle lineStyle, IDrawEffect[] effects)
 {
     throw new NotImplementedException();
 }
示例#5
0
 public void DrawImage(Image img, float srcX, float srcY, float srcWidth, float srcHeight,float destX,float destY, float destWidth, float destHeight, int angle, IDrawEffect[] effects)
 {
     this.m_graphics.DrawImage(img, new RectangleF(destX, destY, destWidth, destHeight), new RectangleF(srcY, srcY, srcWidth, srcHeight),GraphicsUnit.Pixel);
 }
示例#6
0
 /// <summary>
 /// Prepares a model to be rendered using the associated effect
 /// </summary>
 /// <param name="model"></param>
 public static void PrepModel(this IDrawEffect effect, Model model)
 {
     PrepModel(effect.AsEffect(), model);
 }