473,394 Members | 1,306 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Which image file formats does Image/Bitmap support?

The Image class allows loading a bitmap from a graphic file. So far I've
gotten it to work with JPG and BMP files.

What other graphic file formats are supported in this way? Is this fixed
based on the .NET Framework used (e.g., the Image class defines which
formats can be used), or can different file formats be added after-the-fact
(end-user capability in contrast to developer implementation)?

Also, is it possible to save an image in BMP or JPG or etc. graphic formats
natively (part of the language in contrast to written code or 3rd party
stuff)?

Thanks in advance for responses!

[==Peter==]

Oct 21 '07 #1
2 2893
I am not clear which image library you are talking about. C++ does not have
any built-in keywords for image processing.
If you are talking about GDI+, yes, it is the same in System.Drawing.
If you want to extend your image format support at runtime, write your own
image processing engines as plugins.
--
Regards
Sheng Jiang
Microsoft MVP in VC++
"Peter Oliphant" <pe********@hotmail.comwrote in message
news:BA**********************************@microsof t.com...
The Image class allows loading a bitmap from a graphic file. So far I've
gotten it to work with JPG and BMP files.

What other graphic file formats are supported in this way? Is this fixed
based on the .NET Framework used (e.g., the Image class defines which
formats can be used), or can different file formats be added
after-the-fact (end-user capability in contrast to developer
implementation)?

Also, is it possible to save an image in BMP or JPG or etc. graphic
formats natively (part of the language in contrast to written code or 3rd
party stuff)?

Thanks in advance for responses!

[==Peter==]
Oct 24 '07 #2
OK, sorry, I will try to be a bit clearer.

The following code will work, and successfully loads the image stored in an
image file into a Bitmap:

Bitmap^ image_bm = gcnew Bitmap( "image.JPG" ) ;

and this works as well:

Bitmap^ image_bm = gcnew Bitmap( "image.BMP" ) ;

but this DOESN'T work:

Bitmap^ image_bm = gcnew Bitmap( "image.TXT" ) ;

Thus, I know the language supports READING both JPG and BMP, and seems to do
so on every computer, thus it appears to accept these particular image file
formats natively (without having to install anything first).

What I'm interested in knowing is which OTHER image formats does this work
with? Equivalently, for which extensions .XYZ will the following also work:

Bitmap^ image_bm = gcnew Bitmap( "image.XYZ" ) ;

[==Peter=]
"Sheng Jiang[MVP]" <sh*********@hotmail.com.discusswrote in message
news:A7**********************************@microsof t.com...
>I am not clear which image library you are talking about. C++ does not have
any built-in keywords for image processing.
If you are talking about GDI+, yes, it is the same in System.Drawing.
If you want to extend your image format support at runtime, write your own
image processing engines as plugins.
--
Regards
Sheng Jiang
Microsoft MVP in VC++
"Peter Oliphant" <pe********@hotmail.comwrote in message
news:BA**********************************@microsof t.com...
>The Image class allows loading a bitmap from a graphic file. So far I've
gotten it to work with JPG and BMP files.

What other graphic file formats are supported in this way? Is this fixed
based on the .NET Framework used (e.g., the Image class defines which
formats can be used), or can different file formats be added
after-the-fact (end-user capability in contrast to developer
implementation)?

Also, is it possible to save an image in BMP or JPG or etc. graphic
formats natively (part of the language in contrast to written code or 3rd
party stuff)?

Thanks in advance for responses!

[==Peter==]
Oct 25 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: deko | last post by:
I have a table that contains a bunch of pictures. When the user selects a particular image in a form, I need a way to extract the selected bitmap image (stored in an OLE Object table field) to the...
8
by: Dave Quigley | last post by:
Hello everyone.... Im currently starting my targa support project again for ..NET and I am wondering if there are any particular interfaces or classes that Im supposed to extend in order to do this...
6
by: Peder Y | last post by:
Surely, anyone can read it's attributes and methods... Now, how does Image store the image data? How does it discern between e.g. jpg, gif and bmp. Does it know it's own size, or does one need to...
7
by: Scott Schluer | last post by:
Is there a way to use the Image class to convert a color photo (GIF or JPEG) to a B&W photo? Thanks, Scott
8
by: Christopher Kurtis Koeber | last post by:
Dear All, Recently I created a thread about trying to load a particular ICON image that GDI plus could not load. I realized that GDI plus definitely does not support it because it had a certain...
1
by: Hardy Wang | last post by:
Hi, I found a piece of code to add drop shadow to a photo like below, after I save the image, it is actually a BMP file even though I specify a JPG file extension (see...
0
by: info | last post by:
For fingerprint images WSQ (Wavelet Scalar Quantization) is superior to other lossy compression methods, such as JPEG, and was chosen by FBI (U.S. Federal Bureau of Investigation) as the...
1
by: Stedak | last post by:
I have the following class I use to save Tiff's. The problem I have with it is that the final size of the images are very large. If we scan directly to a file the final tiff may be 600-900 kb.s but...
8
by: platinumhimani | last post by:
-How to convert any image(8,16,24,32 or 64-bit) to 8-bit grayscale -i have tried to convert a 24-bit image to grayscale using setpixel and getpixel functions, in vb.net but i am unable to save...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.