Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / November 2006

Tip: Looking for answers? Try searching our database.

JPEG Compression

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Brian - 09 Nov 2006 12:57 GMT
Is there anyway I can retrieve the information on the quailty setting of a
jpeg.

In my project I can optimize the image by setting the width and height and
the quality setting.

I use the EncoderParameters to set the jpeg quality.

To avoid optimizing the same image twice I would like to get the information
about the quailty setting that has been applied to the image, is this
possible? or is there another way of checking..
Carl Daniel [VC++ MVP] - 09 Nov 2006 17:26 GMT
> Is there anyway I can retrieve the information on the quailty setting of a
> jpeg.
[quoted text clipped - 8 lines]
> about the quailty setting that has been applied to the image, is this
> possible? or is there another way of checking..

That information is not stored in the JPEG file, at least not overtly.  In
fact, there's no concept of "quality setting" in the JPEG standard at all.
Rather, that quality setting is used to initialize a set of tables of
"quantization coefficients" which are used during the compression and
decompression.  It's probably possible to determine the quality setting for
a given image if you know exactly what software produced the image, but
there's not one single standard algorithm that's used to transform the
quality setting into the coefficient tables, so without know how the image
was made it'd just be a guess.

If the image is from a camera, then it's likely to be an "EXIF" image, which
is simple a standard JFIF (aka JPEG) image with additional tags embedded
that contain information about the camera settings, date, time, etc.  It's
possible that there's an EXIF tag for compression quality - I don't have the
EXIF standard here to check.  Even if there is such a tag, there's no
guarantee that any given image willl contain that tag.

In short, what you ask is impossible in the general case, but might be
possible in some special cases.

-cd

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.