internal PdfImage(int id, Bitmap bitmap, bool transparent) { this.id = id; this.bmp = bitmap; this.width = bmp.Width; this.height = bmp.Height; if (transparent) { this.mask = new PdfImageMask(bmp); } }
internal PdfImage(int id, string file) { this.id = id; this.file = file; try { this.bmp = new Bitmap(file); this.width = bmp.Width; this.height = bmp.Height; this.mask = new PdfImageMask(bmp); } catch { throw new Exception("Error Loading Image File"); } }