<li><ahref="../../../org/libjpegturbo/turbojpeg/TJCompressor.html"title="class in org.libjpegturbo.turbojpeg"><spanclass="strong">Next Class</span></a></li>
<divclass="block">For the given pixel format, returns the number of bytes that the red
component is offset from the start of the pixel.</div>
</td>
</tr>
<trclass="rowColor">
<tdclass="colFirst"><code>static <ahref="../../../org/libjpegturbo/turbojpeg/TJScalingFactor.html"title="class in org.libjpegturbo.turbojpeg">TJScalingFactor</a>[]</code></td>
<divclass="block">The number of chrominance subsampling options</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMSAMP">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_444">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_444</h4>
<pre>public static final int SAMP_444</pre>
<divclass="block">4:4:4 chrominance subsampling (no chrominance subsampling). The JPEG
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_444">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_422">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_422</h4>
<pre>public static final int SAMP_422</pre>
<divclass="block">4:2:2 chrominance subsampling. The JPEG or YUV image will contain one
chrominance component for every 2x1 block of pixels in the source image.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_422">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_420">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_420</h4>
<pre>public static final int SAMP_420</pre>
<divclass="block">4:2:0 chrominance subsampling. The JPEG or YUV image will contain one
chrominance component for every 2x2 block of pixels in the source image.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_420">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_GRAY">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_GRAY</h4>
<pre>public static final int SAMP_GRAY</pre>
<divclass="block">Grayscale. The JPEG or YUV image will contain no chrominance components.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_440">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_440</h4>
<pre>public static final int SAMP_440</pre>
<divclass="block">4:4:0 chrominance subsampling. The JPEG or YUV image will contain one
Note that 4:4:0 subsampling is not fully accelerated in libjpeg-turbo.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_440">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="SAMP_411">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>SAMP_411</h4>
<pre>public static final int SAMP_411</pre>
<divclass="block">4:1:1 chrominance subsampling. The JPEG or YUV image will contain one
chrominance component for every 4x1 block of pixels in the source image.
JPEG images compressed with 4:1:1 subsampling will be almost exactly the
same size as those compressed with 4:2:0 subsampling, and in the
aggregate, both subsampling methods produce approximately the same
perceptual quality. However, 4:1:1 is better able to reproduce sharp
horizontal features. Note that 4:1:1 subsampling is not fully accelerated
in libjpeg-turbo.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.SAMP_411">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="NUMPF">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>NUMPF</h4>
<pre>public static final int NUMPF</pre>
<divclass="block">The number of pixel formats</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMPF">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_RGB">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_RGB</h4>
<pre>public static final int PF_RGB</pre>
<divclass="block">RGB pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_BGR">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_BGR</h4>
<pre>public static final int PF_BGR</pre>
<divclass="block">BGR pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_RGBX">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_RGBX</h4>
<pre>public static final int PF_RGBX</pre>
<divclass="block">RGBX pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGBX">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_BGRX">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_BGRX</h4>
<pre>public static final int PF_BGRX</pre>
<divclass="block">BGRX pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGRX">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_XBGR">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_XBGR</h4>
<pre>public static final int PF_XBGR</pre>
<divclass="block">XBGR pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_XBGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_XRGB">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_XRGB</h4>
<pre>public static final int PF_XRGB</pre>
<divclass="block">XRGB pixel format. The red, green, and blue components in the image are
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_XRGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_GRAY">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_GRAY</h4>
<pre>public static final int PF_GRAY</pre>
<divclass="block">Grayscale pixel format. Each 1-byte pixel represents a luminance
(brightness) level from 0 to 255.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_RGBA">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_RGBA</h4>
<pre>public static final int PF_RGBA</pre>
<divclass="block">RGBA pixel format. This is the same as <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGBX"><code>PF_RGBX</code></a>, except that when
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_RGBA">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_BGRA">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_BGRA</h4>
<pre>public static final int PF_BGRA</pre>
<divclass="block">BGRA pixel format. This is the same as <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_BGRX"><code>PF_BGRX</code></a>, except that when
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_BGRA">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_ABGR">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_ABGR</h4>
<pre>public static final int PF_ABGR</pre>
<divclass="block">ABGR pixel format. This is the same as <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XBGR"><code>PF_XBGR</code></a>, except that when
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_ABGR">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_ARGB">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_ARGB</h4>
<pre>public static final int PF_ARGB</pre>
<divclass="block">ARGB pixel format. This is the same as <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_XRGB"><code>PF_XRGB</code></a>, except that when
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_ARGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="PF_CMYK">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>PF_CMYK</h4>
<pre>public static final int PF_CMYK</pre>
<divclass="block">CMYK pixel format. Unlike RGB, which is an additive color model used
primarily for display, CMYK (Cyan/Magenta/Yellow/Key) is a subtractive
color model used primarily for printing. In the CMYK color model, the
value of each color component typically corresponds to an amount of cyan,
magenta, yellow, or black ink that is applied to a white background. In
order to convert between CMYK and RGB, it is necessary to use a color
management system (CMS.) A CMS will attempt to map colors within the
printer's gamut to perceptually similar colors in the display's gamut and
vice versa, but the mapping is typically not 1:1 or reversible, nor can it
be defined with a simple formula. Thus, such a conversion is out of scope
for a codec library. However, the TurboJPEG API allows for compressing
CMYK pixels into a YCCK JPEG image (see <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html#CS_YCCK"><code>CS_YCCK</code></a>) and
decompressing YCCK JPEG images into CMYK pixels.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.PF_CMYK">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="NUMCS">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>NUMCS</h4>
<pre>public static final int NUMCS</pre>
<divclass="block">The number of JPEG colorspaces</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.NUMCS">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="CS_RGB">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>CS_RGB</h4>
<pre>public static final int CS_RGB</pre>
<divclass="block">RGB colorspace. When compressing the JPEG image, the R, G, and B
components in the source image are reordered into image planes, but no
colorspace conversion or subsampling is performed. RGB JPEG images can be
decompressed to any of the extended RGB pixel formats or grayscale, but
they cannot be decompressed to YUV images.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_RGB">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="CS_YCbCr">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>CS_YCbCr</h4>
<pre>public static final int CS_YCbCr</pre>
<divclass="block">YCbCr colorspace. YCbCr is not an absolute colorspace but rather a
mathematical transformation of RGB designed solely for storage and
transmission. YCbCr images must be converted to RGB before they can
actually be displayed. In the YCbCr colorspace, the Y (luminance)
component represents the black & white portion of the original image, and
the Cb and Cr (chrominance) components represent the color portion of the
original image. Originally, the analog equivalent of this transformation
allowed the same signal to drive both black & white and color televisions,
but JPEG images use YCbCr primarily because it allows the color data to be
optionally subsampled for the purposes of reducing bandwidth or disk
space. YCbCr is the most common JPEG colorspace, and YCbCr JPEG images
can be compressed from and decompressed to any of the extended RGB pixel
formats or grayscale, or they can be decompressed to YUV planar images.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_YCbCr">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="CS_GRAY">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>CS_GRAY</h4>
<pre>public static final int CS_GRAY</pre>
<divclass="block">Grayscale colorspace. The JPEG image retains only the luminance data (Y
component), and any color data from the source image is discarded.
Grayscale JPEG images can be compressed from and decompressed to any of
the extended RGB pixel formats or grayscale, or they can be decompressed
to YUV planar images.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_GRAY">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="CS_CMYK">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>CS_CMYK</h4>
<pre>public static final int CS_CMYK</pre>
<divclass="block">CMYK colorspace. When compressing the JPEG image, the C, M, Y, and K
components in the source image are reordered into image planes, but no
colorspace conversion or subsampling is performed. CMYK JPEG images can
only be decompressed to CMYK pixels.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_CMYK">Constant Field Values</a></dd></dl>
</li>
</ul>
<aname="CS_YCCK">
<!---->
</a>
<ulclass="blockList">
<liclass="blockList">
<h4>CS_YCCK</h4>
<pre>public static final int CS_YCCK</pre>
<divclass="block">YCCK colorspace. YCCK (AKA "YCbCrK") is not an absolute colorspace but
rather a mathematical transformation of CMYK designed solely for storage
and transmission. It is to CMYK as YCbCr is to RGB. CMYK pixels can be
reversibly transformed into YCCK, and as with YCbCr, the chrominance
components in the YCCK pixels can be subsampled without incurring major
perceptual loss. YCCK JPEG images can only be compressed from and
decompressed to CMYK pixels.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.CS_YCCK">Constant Field Values</a></dd></dl>
<divclass="block">The uncompressed source/destination image is stored in bottom-up (Windows,
OpenGL) order, not top-down (X11) order.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_BOTTOMUP">Constant Field Values</a></dd></dl>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCEMMX">Constant Field Values</a></dd></dl>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE">Constant Field Values</a></dd></dl>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE2">Constant Field Values</a></dd></dl>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FORCESSE3">Constant Field Values</a></dd></dl>
order to reduce upsampling artifacts in the decompressed image.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FASTUPSAMPLE">Constant Field Values</a></dd></dl>
when decompressing, because this has been shown to have a larger effect.</div>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_FASTDCT">Constant Field Values</a></dd></dl>
<dl><dt><spanclass="strong">See Also:</span></dt><dd><ahref="../../../constant-values.html#org.libjpegturbo.turbojpeg.TJ.FLAG_ACCURATEDCT">Constant Field Values</a></dd></dl>
<divclass="block">Returns the maximum size of the buffer (in bytes) required to hold a JPEG
image with the given width, height, and level of chrominance subsampling.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>width</code> - the width (in pixels) of the JPEG image</dd><dd><code>height</code> - the height (in pixels) of the JPEG image</dd><dd><code>jpegSubsamp</code> - the level of chrominance subsampling to be used when
generating the JPEG image (one of <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html"title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>the maximum size of the buffer (in bytes) required to hold a JPEG
<divclass="block">Returns the size of the buffer (in bytes) required to hold a YUV planar
image with the given width, height, and level of chrominance subsampling.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>width</code> - the width (in pixels) of the YUV image</dd><dd><code>pad</code> - the width of each line in each plane of the image is padded to
the nearest multiple of this number of bytes (must be a power of 2.)</dd><dd><code>height</code> - the height (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV
image (one of <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html"title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>the size of the buffer (in bytes) required to hold a YUV planar
<divclass="block">Returns the size of the buffer (in bytes) required to hold a YUV image
plane with the given parameters.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
2 = V/Cr)</dd><dd><code>width</code> - width (in pixels) of the YUV image. NOTE: this is the width
of the whole image, not the plane width.</dd><dd><code>stride</code> - bytes per line in the image plane.</dd><dd><code>height</code> - height (in pixels) of the YUV image. NOTE: this is the
height of the whole image, not the plane height.</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV
image (one of <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html"title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<dt><spanclass="strong">Returns:</span></dt><dd>the size of the buffer (in bytes) required to hold a YUV planar
<divclass="block">Returns the plane width of a YUV image plane with the given parameters.
Refer to <ahref="../../../org/libjpegturbo/turbojpeg/YUVImage.html"title="class in org.libjpegturbo.turbojpeg"><code>YUVImage</code></a> for a description of plane width.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
2 = V/Cr)</dd><dd><code>width</code> - width (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV image
(one of <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html"title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<divclass="block">Returns the plane height of a YUV image plane with the given parameters.
Refer to <ahref="../../../org/libjpegturbo/turbojpeg/YUVImage.html"title="class in org.libjpegturbo.turbojpeg"><code>YUVImage</code></a> for a description of plane height.</div>
<dl><dt><spanclass="strong">Parameters:</span></dt><dd><code>componentID</code> - ID number of the image plane (0 = Y, 1 = U/Cb,
2 = V/Cr)</dd><dd><code>height</code> - height (in pixels) of the YUV image</dd><dd><code>subsamp</code> - the level of chrominance subsampling used in the YUV image
(one of <ahref="../../../org/libjpegturbo/turbojpeg/TJ.html"title="class in org.libjpegturbo.turbojpeg"><code>TJ.SAMP_*</code></a>)</dd>
<pre>public static <ahref="../../../org/libjpegturbo/turbojpeg/TJScalingFactor.html"title="class in org.libjpegturbo.turbojpeg">TJScalingFactor</a>[] getScalingFactors()</pre>
<li><ahref="../../../org/libjpegturbo/turbojpeg/TJCompressor.html"title="class in org.libjpegturbo.turbojpeg"><spanclass="strong">Next Class</span></a></li>