AWARE [SYSTEMS] Imaging expertise for the Delphi developer
AWare Systems, Imaging expertise for the Delphi developer, Home TIFF and LibTiff Mailing List Archive

LibTiff Mailing List

TIFF and LibTiff Mailing List Archive
November 1996

Previous Thread
Next Thread

Previous by Thread
Next by Thread

Previous by Date
Next by Date

Contact

The TIFF Mailing List Homepage
This list is run by Frank Warmerdam
Archive maintained by AWare Systems



Valid HTML 4.01!



1996.11.07 15:26 "Re: Tiff file informations", by Tom Lane

> But this type of ordering is in contradiction with the way we store the
> YCbCr datas with YCbCrSubSampling Values of [2,2].
> We have video images YCbCr in the format 4:2:2 (corresponding to
> ChromaSubSampleHoriz = 2 and ChromaSubSampleVert = 2) and the data are
> stored this way (the same that we read them) Y1, Cb1, Y2,Cr1, Y3, Cb2,
> Y4,Cr2 etc...
> in fact two values of luma for one couple of chroma (Cb,Cr).
> Could someone ask this question : is the specification documentation false
> especially on page 93 or is the way we are storing datas wrong ? It's very
> important for us to know, because we want to import TIFF files to our
> system. 

4:2:2 is not [2,2] sampling, it is [2,1] sampling.  You have chroma
downsampled 2x relative to luma horizontally, but the same resolution
vertically.  A lot of people make this mistake, because the a:b:c
notation is very unintuitive.  (For reference, the other common sampling
ratios are 4:1:1 == [4,1] and 4:2:0 == [2,2].)

If you are storing YCbCr data in that order in a TIFF file, then your
TIFF file is unquestionably erroneous.  Section 21 is perfectly clear
that the TIFF sample order for [2,1] sampling is Y00,Y01,Cb,Cr.

If you are storing YCbCr data in that order in some format of your own
devising, that's certainly a choice you can make.  You will have to
reorder the samples when converting to or from TIFF.

			regards, tom lane