Hi, im trying to convert the attached TIFF to PDF using the following code:
Dim pdf1 As Pdf = New Pdf()
Dim sec As Section = pdf1.Sections.Add()
Dim ms As MemoryStream = New MemoryStream(<File>)
Dim myimage As New Bitmap(ms)
Dim imageht As Aspose.Pdf.Generator.Image = New Aspose.Pdf.Generator.Image(sec)
imageht.ImageInfo.ImageFileType = ImageFileType.Tiff
imageht.ImageInfo.ImageStream = ms
imageht.ImageInfo.IsBlackWhite = false
sec.Paragraphs.Add(imageht)
Dim tifstream = New MemoryStream()
pdf1.Save(tifstream)
---
The tif size is 285 kb
The converted PDF file is 954kb
When I set the "IsBlackWhite" to "true", the PDF filesize drops to 300kb.
But im not intererested in converting the tiff to BlackWhite.
How can I convert the TIFF to PDF without the filesize getting much bigger?
Dim pdf1 As Pdf = New Pdf()
Dim sec As Section = pdf1.Sections.Add()
Dim ms As MemoryStream = New MemoryStream(<File>)
Dim myimage As New Bitmap(ms)
Dim imageht As Aspose.Pdf.Generator.Image = New Aspose.Pdf.Generator.Image(sec)
imageht.ImageInfo.ImageFileType = ImageFileType.Tiff
imageht.ImageInfo.ImageStream = ms
imageht.ImageInfo.IsBlackWhite = false
sec.Paragraphs.Add(imageht)
Dim tifstream = New MemoryStream()
pdf1.Save(tifstream)
---
The tif size is 285 kb
The converted PDF file is 954kb
When I set the "IsBlackWhite" to "true", the PDF filesize drops to 300kb.
But im not intererested in converting the tiff to BlackWhite.
How can I convert the TIFF to PDF without the filesize getting much bigger?