Hi
I try to render a PDF page on a bitmap with a defined background color (red) but I always get a white page background. This the code I use:
var lDoc := TPdfDocument.Create;
try
lDoc.LoadFromFile('d:\downloads\test_text_back.pdf');
var bmp := TIEBItmap.Create(200, 400, clRed, 255);
try
IERenderPDFToBMP(bmp.VclBitmap, lDoc, 0, 200, 400, pw, ph, dpiX, dpiY, prNormal, clRed);
bmp.DrawToCanvasWithAlpha(self.Canvas, 100, 100);
finally
bmp.Free;
end;
finally
lDoc.Free;
end;
The PDF self has just some text on a single page without background. So what am I doing wrong here?
kind regards,
Ulrich