Hi Guys
Im using the Aspose.Imaging.HEIC.Adapter as well as the updated the openize.heic dll although the that dll has been deprecated in favour of FileFormat.heic
I have tried both dll’s
I always get an exception
image.png (29.5 KB)
I have also attempted to sign the dll’s but still get the same error
Aspose imaging seems to only want the deprecated dll’
Here is some sample code im using
Imports Aspose.Imaging.HEIC.Adapter
Imports Aspose.Imaging.ImageOptions
HEICImage.Register()
Dim image = Aspose.Imaging.Image.Load(File) ’ Always fails here
Dim image As HEICImage = Aspose.Imaging.Image.Load(File) also always fails
’ Save the HEIC image as a PNG (or other formats if needed)
Dim pngFilePath1 As String = Path.GetTempFileName()
image.Save(pngFilePath, New PngOptions())
This code is similar to that offered on NuGet Gallery | Aspose.Imaging.HEIC.Adapter 24.6.0
I have tried both net standard and net 4.0 framework of Aspose Imaging dll
I must be missing something Please advise
Hello, @Andre123 ,
I have created a test project targeting net8. Could you try it using your input HEIC image and give a feedback? Note that Aspose.Imaging.HEIC.Adapter only supports NetStandard 2 & net6+.
Hi Denis,
Really Appreciate the fast response. Unfortunately, we only have cause to use the heic conversion options in a framework app eg 4.8
I have tried a number of approaches , using net. Standard versions of the aspose dll’s and whilst there seems to be no issue with other functionality of the dll the same cannot be said of the heic options.
Windows 11, Net Framework 4.8 VB.net 2022
PS Id like to offer some feed back on your project but am not able to see from where or how to download it
@Andre123 , excuse me for a confusion. Here is the test project:
HeicAdapterTest.zip (741 Bytes)
Thanks Again
I can confirm that your project does do the conversion however after modifying my code in line with yours in our framework application it does not work.
Aspose documentation advises the following
Dim image = Aspose.Imaging.Image.Load(File)
your code advises
Dim image = HEICImage.Load(File)
May I suggest that the documentation be updated
@Andre123 , I did not fully understand why does your app not work after you apply the described change.
@Andre123,
I added a project for NetStandard 3.1 where the call is used:
Aspose.Imaging.Image.Load
This works for me. If you have any other questions, do not hesitate to ask.
HeicAdapterTest.zip (824 Bytes)
Thank you for your response
Id like to stress that we have a frame work 4.8 app and it most definitely does not work.
So far I have been shown a net8 and a net 3.1 working but not a framework 4.8 using different techniques. Could I please be shown how to make the converter work in a frame work winform 4.8 application
@Andre123 , we will review your request and give a feedback shortly!
@Andre123
We have opened the following new ticket(s) in our internal issue tracking system to investigate Net48 compatibility and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): IMAGINGNET-7299
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
@Andre123, We have released a new version of Heic.Adapter with NetFramework support, please update to version 24.7.1 and try it.
Hi There
I appreciate the prompt response to my query. Unfortunately the new version also does not work.
Im using code to similar to the below (net 8 code) however the framework version does not have file path as an override, so i have read the file to a memory and or file stream but with no success.
To shortcut any further problems could you supply code that uses the framework 4.8 version , that you have tested and know to work. It would be preferable if the framwork 4.8 version also supported a file path as a parameter
namespace HeicAdapterTest
{
internal class Program
{
static void Main(string[] args)
{
HEICImage.Register();
var inputPath = @"input.HEIC";
using var image = HEICImage.Load(@"C:\Users\ack.VA\OneDrive - Visual Approvals\Documents\HeicAdapterTest\Front house photo left.HEIC");
image.Save(@"C:\Users\ack.VA\OneDrive - Visual Approvals\Documents\HeicAdapterTest\Front house photo left" + ".png");
}
}
}
@Andre123, hello!
I have created an empty console .NET Framework 4.8 project, connected Aspose.Imaging.HEIC.Adapter 24.7.1 via NuGet package manager and this code worked for me:
using Aspose.Imaging.HEIC.Adapter;
namespace ConsoleApp1
{
internal class Program
{
static void Main(string[] args)
{
HEICImage.Register();
string inputPath = "input.heic";
using (var image = HEICImage.Load(inputPath))
{
image.Save(inputPath + ".png");
}
}
}
}
Please try it and let us know if something won’t work.