Convert WebP image to pdf
Contents
[
Hide
]
Convert WebP image to pdf
Using Aspose.Imaging we can convert single paged or animated WebP image to pdf.
The following code snippet shows you how to convert WebP to pdf.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.aspose.imaging.Image; | |
import com.aspose.imaging.imageoptions.PdfOptions; | |
try (com.aspose.imaging.fileformats.webp.WebPImage image = | |
(com.aspose.imaging.fileformats.webp.WebPImage)Image.load("Animation.webp")) | |
{ | |
PdfOptions options = new PdfOptions(); | |
options.setPdfDocumentInfo(new com.aspose.imaging.fileformats.pdf.PdfDocumentInfo()); | |
image.save("Animation.gif", options); | |
} |