Aspose.Image.image to PDF


#1

Hi,
Is there any way I can get Aspose.pdf.image from Aspose.imaging.image.

My C# code like below:

pdfDocument = new Aspose.Pdf.Document();
pdfDocument.Pages.Add();

asposePdfImage = new Aspose.Pdf.Image();
using (Aspose.Imaging.Image image = Aspose.Imaging.Image.Load(OriginalFilePathName))
{
x = image.Width;
y = image.Height;

                    if (x > y) // landscape
                    {
                        image.Resize(792, 612, Aspose.Imaging.ResizeType.LanczosResample);
                    }
                    else     //
                    {
                        image.Resize(612, 792, Aspose.Imaging.ResizeType.LanczosResample);
                    }

                    image.Save();

                ?????
               // asposePdfImage.ImageStream = postFile.InputStream;

                pdfDocument.Pages[1].Paragraphs.Add(asposePdfImage);
                }

#2

@jeffreyshou,

I have observed your comments. I like to inform that Aspose.Imaging like other Aspose products does not include any other product dependencies in API, but you are free to save image to stream or to file and use it as per API of other products i.e. Pdf in such case.