jpeg/jfif for DOS?

jpeg/jfif for DOS?

Post by Matt Rognl » Sat, 12 Mar 1994 22:35:50



Is there a program to view JPEG/JFIF files on a DOS machine (or convert to a
TIFF or GIF, etc)?  Thanks for any help.

Matthew Rognlie                  |

Marsh Lab                        | phone: 406-994-6379
Montana State University         |   FAX: 406-994-4303
Bozeman, MT  59717-0360          |

 
 
 

jpeg/jfif for DOS?

Post by Frans Rip (Wageningen Agric.U., Netherlands, 08370-820 » Tue, 15 Mar 1994 18:36:57



Quote: (Matt Rognlie) writes:
>Is there a program to view JPEG/JFIF files on a DOS machine (or convert to a
>TIFF or GIF, etc)?  Thanks for any help.

in the JPEG-faq by Tom Lane, Image Alchemy is said to do so.
This faq is available by FTP from rtfm.mit.edu ,
/pub/usenet/news.answers/jpeg-faq.
Good luck.

Frans Rip          Wageningen Agricultural University (WAU), the Netherlands
****************************************************************************
Department of Physical Planning&Rural Development (RPV)  - Landscape Section

FAX:31 8370 82166 -TEL:31 8370 82098 -Gen.Foulkesweg 13, 6703 BJ, Wageningen
============================================================================

 
 
 

1. JPEG JFIF baseline file format question

JPEG JFIF file format question for all the JPEG wizards out there.

I have figured out what the JFIF JPEG headers look like and how to decode
them and have written code that actually seems to successfully do so.  What
I am not sure of is how the scan blocks are laid out when you have color and
when your H and V sampling factors are not all 1.

Ok, so let's assume that there are the three standard color components YCbCr
and that Y has an H=2 V=2 and that Cb has H=1 V=1 and Cr has H=1 V=1.  So
there are four times as many Y samples as Cb samples right?  Now, how are
the samples laid out?  Is it:

|----- 256 Ys ------|---- 64 Cbs -----------|---- 64 Crs ------|
YYYYYY...YYYYCbCbCbCbCb...CbCrCrCr...CrCrCr

or is it

|--------------- 64 times ----------------------|
YYCbCrYYCbCrYYCbCr .... YYCbCr

or something else?

What if it were V=3 H=1 for Y and V=1 H=2 for Cb, or some strange
combination?

An essentially related question.  If my image size is 300x500 and I have the
V and H values given above, does this mean I should expect 300x500 Y values
and 150x250 Cb and Cr values? or does it mean I should expect 600x1000 Y
values and 300x500 Cb and Cr values?

Any help would be greatly appreciated.

Q. Why not just use the IJG C library?
A. Well it doesn't do what I want I also I need it in Java.

Q. Why not just look at the IJG library and see what they do?
A. Well I did, and I will resort to that again if I have to, but I find the
code very difficult to follow.

Thanks.

Ian


2. AVI Component

3. Extracting non-image data from a JPEG/JFIF

4. eps question

5. Converting JPEG-TIFF --> JFIF

6. Way to get pixel format descriptors for other resolutions/color depths?

7. p-jpeg to jpeg in ms-dos 6.22

8. mel mode for emacs?

9. JPEG/JFIF reader supporting SOF3 ?

10. JPEG/JFIF date from header?

11. Extracting JPEG image from a JFIF file

12. JPEG-JFIF Caption in file

13. IPTC IIM data extraction from JPEG/JFIF