Page 1 of 1

Image Type Detection?

Posted: Fri Jan 12, 2018 6:10 pm
by tfierens2
Hi,

Is there a way to detect the supported image types at run-time? For example, I'd like to check the file being currently processed and ensure it is supported by GdPicture before attempting to process it.

Something like this:

if (gdPictureImaging.IsValidImageType(fileName))
{
... convert to pdf
}

Thanks.

Thierry

Re: Image Type Detection?

Posted: Tue Jan 16, 2018 9:25 am
by David
Hi Thierry,

I'm sorry we do not have such a specific function. In my opinion, the best way is try and load the file.

Regards,

David

Re: Image Type Detection?

Posted: Tue Jan 16, 2018 1:27 pm
by tfierens2
Thanks David.

I'll probably find the list of files GdPicture supports and create a function to check the extension as it will be more efficient and less resource intensive than opening the file. Not perfect but it will do.

Thanks.

Re: Image Type Detection?

Posted: Wed Jan 17, 2018 9:55 am
by David
Hi Thierry,

Please create a ticket to our support platform with your license number. I will thus be able to provide the list of raster image format extensions you can load with your license.

I'm looking forward to hearing from you.

David

Re: Image Type Detection?

Posted: Wed Jan 17, 2018 11:04 am
by tfierens2
Will do. Thanks David.