Free Support Forum - aspose.com

Error converting TIF to PNG (C# .NET)

Hi.
I´m having problems with some TIF files when converting them to PNG extension.
Print and file.tif attached.
TifToPng.zip (250.8 KB)

Don´t know if Im missing something on PngOptions…

Here is the code:

class Program
{
static void Main(string[] args)
{
using (MemoryStream msOut = new MemoryStream()){

            using (var image = Aspose.Imaging.Image.Load("C:\\Users\\Eduardo\\Desktop\\Nova pasta\\Original\\Exemplo C-2320.tif"))
            {
                image.Save(msOut, new Aspose.Imaging.ImageOptions.PngOptions());                

            }
        }
    }

}

Thanks in advance,

Eduardo

@EduardoDoria

Your query is related to Aspose.Imaging. We are moving this forum thread to Aspose.Imaging forum where you will be guided appropriately.

@EduardoDoria,

I have worked with the source file shared by you and have been able to observe the issue. An issue with ID IMAGINGNET-3633 has been created in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be automatically notified once the issue will be fixed. We will share good news with you soon.

1 Like

Hi.
I´ve just entered the forum and saw that the Issue Status is set to closed… .
No solution was found for my problem?

@EduardoDoria,

Can you please try using following sample code using latest version 20.1 on your end.

using Aspose.Imaging;
using Aspose.Imaging.FileFormats.Tiff;
using Aspose.Imaging.ImageOptions;

class Program
{
   static void Main(string[] args)
   {
       using (MemoryStream msOut = new MemoryStream())
       {
           using (TiffImage image = (TiffImage)Image.Load("Exemplo C-2320.tif"))
           {
               image.Save(msOut, new PngOptions());
           }
       }
   }
}

Thank you for answering. I still got the problem.
erro persistente.jpg (135.7 KB)

@EduardoDoria,

I have worked source Tiff file on my end using Aspose.Imaging for .NET 20.1. I have not been able to observe the issue on loading the TIFF. Can you please try using the specified version and provided sample code.
TiffTest.png (66.0 KB)

I´ve tried with Aspose Total 20.2.0 and before that with Aspose Imaging 19.12.0 . Both downloaded via NuGet.
Could not find an specific Imaging 20.1 version

THX again.

@EduardoDoria,

I have observed your comments and like to share that at present Aspose.Imaging for .NET 19.12 is latest available version to date. We will share the notification of new launch with you as soon as it will be made available online.

1 Like

The issues you have found earlier (filed as IMAGINGNET-3633) have been fixed in this update.