Java doc: TJ.pixelSize --> TJ.getPixelSize()
TJ.pixelSize isn't actually a thing. Oops.
This commit is contained in:
@@ -487,13 +487,15 @@ public TJCompressor(byte[] srcImage,
|
||||
the JPEG or YUV image should be compressed/encoded</dd><dd><code>y</code> - y offset (in pixels) of the region in the source image from which
|
||||
the JPEG or YUV image should be compressed/encoded</dd><dd><code>width</code> - width (in pixels) of the region in the source image from
|
||||
which the JPEG or YUV image should be compressed/encoded</dd><dd><code>pitch</code> - bytes per row in the source image. Normally this should be
|
||||
<code>width * TJ.pixelSize(pixelFormat)</code>, if the source image is
|
||||
unpadded. However, you can use this parameter to, for instance, specify
|
||||
that the rows in the source image are padded to the nearest multiple of 4
|
||||
bytes or to compress/encode a JPEG or YUV image from a region of a larger
|
||||
source image. You can also be clever and use this parameter to skip rows,
|
||||
etc. Setting this parameter to 0 is the equivalent of setting it to
|
||||
<code>width * TJ.pixelSize(pixelFormat)</code>.</dd><dd><code>height</code> - height (in pixels) of the region in the source image from
|
||||
<code>width *
|
||||
</code><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getPixelSize(int)"><code>TJ.getPixelSize</code></a><code>(pixelFormat)</code>,
|
||||
if the source image is unpadded. However, you can use this parameter to,
|
||||
for instance, specify that the rows in the source image are padded to the
|
||||
nearest multiple of 4 bytes or to compress/encode a JPEG or YUV image from
|
||||
a region of a larger source image. You can also be clever and use this
|
||||
parameter to skip rows, etc. Setting this parameter to 0 is the
|
||||
equivalent of setting it to <code>width *
|
||||
</code><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getPixelSize(int)"><code>TJ.getPixelSize</code></a><code>(pixelFormat)</code>.</dd><dd><code>height</code> - height (in pixels) of the region in the source image from
|
||||
which the JPEG or YUV image should be compressed/encoded</dd><dd><code>pixelFormat</code> - pixel format of the source image (one of
|
||||
<a href="../../../org/libjpegturbo/turbojpeg/TJ.html#PF_RGB"><code>TJ.PF_*</code></a>)</dd>
|
||||
<dt><span class="strong">Throws:</span></dt>
|
||||
|
||||
@@ -837,17 +837,19 @@ public void setJPEGImage(byte[] jpegImage,
|
||||
it to the width of the JPEG image. (In other words, the width will not be
|
||||
considered when determining the scaled image size.) This parameter is
|
||||
ignored if the source image is a YUV image.</dd><dd><code>pitch</code> - bytes per row in the destination image. Normally this should
|
||||
be set to <code>scaledWidth * TJ.pixelSize(pixelFormat)</code>, if the
|
||||
destination image will be unpadded. However, you can use this to, for
|
||||
instance, pad each row of the destination image to the nearest multiple of
|
||||
4 bytes or to decompress/decode the source image into a region of a larger
|
||||
image. NOTE: if the source image is a JPEG image, then
|
||||
be set to <code>scaledWidth *
|
||||
</code><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getPixelSize(int)"><code>TJ.getPixelSize</code></a><code>(pixelFormat)</code>,
|
||||
if the destination image will be unpadded. However, you can use this to,
|
||||
for instance, pad each row of the destination image to the nearest
|
||||
multiple of 4 bytes or to decompress/decode the source image into a region
|
||||
of a larger image. NOTE: if the source image is a JPEG image, then
|
||||
<code>scaledWidth</code> can be determined by calling
|
||||
<code>scalingFactor.</code><a href="../../../org/libjpegturbo/turbojpeg/TJScalingFactor.html#getScaled(int)"><code>getScaled</code></a><code>(jpegWidth)</code>
|
||||
or by calling <a href="../../../org/libjpegturbo/turbojpeg/TJDecompressor.html#getScaledWidth(int,%20int)"><code>getScaledWidth(int, int)</code></a>. If the source image is a YUV
|
||||
image, then <code>scaledWidth</code> is the width of the YUV image.
|
||||
Setting this parameter to 0 is the equivalent of setting it to
|
||||
<code>scaledWidth * TJ.pixelSize(pixelFormat)</code>.</dd><dd><code>desiredHeight</code> - If the source image is a JPEG image, then this
|
||||
<code>scaledWidth *
|
||||
</code><a href="../../../org/libjpegturbo/turbojpeg/TJ.html#getPixelSize(int)"><code>TJ.getPixelSize</code></a><code>(pixelFormat)</code>.</dd><dd><code>desiredHeight</code> - If the source image is a JPEG image, then this
|
||||
specifies the desired height (in pixels) of the decompressed image (or
|
||||
image region.) If the desired destination image dimensions are different
|
||||
than the source image dimensions, then TurboJPEG will use scaling in the
|
||||
|
||||
Reference in New Issue
Block a user