LEADTOOLS Support
Imaging
Imaging SDK Questions
How do I get available sub types for a RasterSaveDialogFileFormat?
This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Thursday, May 15, 2008 11:27:25 AM(UTC)
Groups: Registered
Posts: 5
I am using the FastTwainDemo to put together an application that imports from a twain device and saves into our document file structure. I need to make available to the users an options dialog similar to the RasterSaveDialog, but without the Save As file field because the users will not be able to pick a path in my application. So I have created my own options controls, but I am falling short on a couple areas. I can use this to get a list of available formats:
RasterSaveDialogFileFormatsList _rasterFormatList = new RasterSaveDialogFileFormatsList(RasterDialogFileFormatDataContent.Default);
But I need ot be able to get the sub types for each type so I can make them available for selection. How do I do this? Also, what is the allowed qfactor for each type? I can see how to get the BitsPerPixelList and the default.
I guess another option form me would be if there is a way to make the built in save dialog not show the file path.
Thanks for any help,
Glenn
#2
Posted
:
Friday, May 16, 2008 1:16:32 PM(UTC)
Groups: Tech Support
Posts: 366
Thanks: 1 times
Was thanked: 4 time(s) in 4 post(s)
Are you looking to support a lot of file types through your dialog or just a select few with the different sub types? The sub-types are enumerated in the Leadtools.WinForms.CommonDialogs.File namespace.
Using RasterSaveDialogFileFormatsList will allow you to create a list of formats. Have you looked at the RasterSaveDialogFileFormat class? You can declare a file format to be of a specific type, i.e. RasterDialogFileTypesIndex.Tiff
I would also suggest checking out the topic "Compression Quality Factors" in the documentation. This should help with your issues with qFactor.
Walter Bates
Senior Support Engineer
LEAD Technologies, Inc.
#3
Posted
:
Friday, May 23, 2008 7:59:45 AM(UTC)
Groups: Registered
Posts: 5
Thanks for the response. I found what I needed the following way:
My list of available types case from:
RasterSaveDialogFileFormatsList _rasterFormatList = new RasterSaveDialogFileFormatsList(RasterDialogFileFormatDataContent.Default);
From a specific type I could get the available BitsPerPixel from:
_rasterFormatList[i].BitsPerPixelList
For a specific BitsPerPixelList, I can get the subtype like this:
format.BitsPerPixelList[_cmbBitsPerPixel.SelectedIndex].SubFormatsList[i].Name
LEADTOOLS Support
Imaging
Imaging SDK Questions
How do I get available sub types for a RasterSaveDialogFileFormat?
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.