Quantcast
Channel: Aspose.Pdf Product Family
Viewing all articles
Browse latest Browse all 3131

Problem stamping GIF image with transparent background on a PDF

$
0
0
Hello,

I have the following code:

       //Open document               Aspose.Pdf.Document pdfDocument = new Aspose.Pdf.Document(inputPdfFile);               //Create image stamp               Aspose.Pdf.ImageStamp imageStamp = new Aspose.Pdf.ImageStamp(imageFile);               imageStamp.Background = background;               imageStamp.XIndent = lowerLeftX;               imageStamp.YIndent = lowerLeftY;               imageStamp.Height = upperRightY - lowerLeftY;               imageStamp.Width = upperRightX - lowerLeftX;               //Add stamp to particular page               pdfDocument.Pages[pageNumber].AddStamp(imageStamp);               //Save output document               pdfDocument.Save(outputPdfFile);
My problem is that when the GIF has transparent background, this code puts a BLACK background on the image.
Stamping the same files with iTextSharp does the job perfectly.


Viewing all articles
Browse latest Browse all 3131

Trending Articles