public void DrawImageUnscaled(Bitmap2 image, float x, float y) { // TODO reduce the resolution to fit (?) try { Image img = Image.GetInstance(GraphUtils.ToBitmap(image), System.Drawing.Imaging.ImageFormat.Tiff); img.SetAbsolutePosition(x, currentHeight - img.ScaledHeight - y); template.AddImage(img); } catch { } }
public void DrawImage(Bitmap2 image, float x, float y, float width, float height) { Image img = null; try { img = Image.GetInstance(GraphUtils.ToBitmap(image), System.Drawing.Imaging.ImageFormat.Tiff); } catch (Exception ex) { Console.Error.WriteLine(ex.Message); } if (img != null) { img.ScaleAbsolute(width, height); img.SetAbsolutePosition(x, currentHeight - img.ScaledHeight - y); template.AddImage(img); } }
public void DrawImageUnscaled(Bitmap2 image, float x, float y) { gc.DrawImageUnscaled(GraphUtils.ToBitmap(image), (int)x, (int)y); }
public void DrawImage(Bitmap2 image, float x, float y, float width, float height) { gc.DrawImage(GraphUtils.ToBitmap(image), x, y, width, height); }