"Object reference not set to an instance of an object." exception when converting obj to gif

Using your sample code:

var document = Aspose.CAD.Image.Load(@“C:\Users\niels\Desktop\Workspace\keanu.obj”);
// Create Instance of GIF Options
var options = new Aspose.CAD.ImageOptions.GifOptions();
// save OBJ as a GIF
document.Save(@“C:\concierge\foo.gif”, options);

I’m getting:

image.png (22.9 KB)

I’ve tried with several difference obj files.

@nielsbosma

Can you please share the source file reproducing the issue on your end. Please also first try using latest Aspose.CAD for .NET as well on your end.

I’m using the latest version from nuget.

keanu.zip (629.0 KB)

@nielsbosma

Using Aspose.CAD for .NET 21.1, I am unable to reproduce the issue on my end by using the sample code shared over this link.

example-580-W_custom.pdf (365.8 KB)

That’s great but I’m trying to convert to gif not pdf.

@nielsbosma

I have created a ticket with ID CADNET-1333 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 notified once the issue will be fixed.