/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
int bWidth;
int bHeight;
int maxWidth;
double xOrg;
double yOrg;
double incXAcross;
double incYAcross;
double incXDown;
double incYDown;
int colincx;
int colincy;
int colincxerr;
int colincyerr;
int rowincx;
int rowincy;
int rowincxerr;
int rowincyerr;
boolean filter =
if (raster instanceof IntegerInterleavedRaster &&
{
}
} else if (raster instanceof ByteInterleavedRaster) {
if (filter) {
if (isFilterableICM(cm)) {
}
} else {
}
}
}
}
if (cm instanceof IndexColorModel) {
return true;
}
}
return false;
}
if (cm instanceof DirectColorModel) {
}
return false;
}
return true;
}
return (mask == 0xff ||
mask == 0xff00 ||
mask == 0xff0000 ||
mask == 0xff000000);
}
return xrgbmodel;
}
return argbmodel;
}
return cm;
}
try {
} catch (NoninvertibleTransformException e) {
}
this.colincx = (int) incXAcross;
this.colincy = (int) incYAcross;
}
static int fractAsInt(double d) {
}
if (num < 0) {
// For very small negative numerators, the answer might
// be such a tiny bit less than den that the difference
// is smaller than the mantissa of a double allows and
// the result would then be rounded to den. If that is
// the case then we map that number to 0 as the nearest
// modulus representation.
num = 0;
}
}
return num;
}
/**
* Release the resources allocated for the operation.
*/
public void dispose() {
}
/**
* Return the ColorModel of the output.
*/
return colorModel;
}
/**
* Return a Raster containing the colors generated for the graphics
* operation.
* @param x,y,w,h The area in device space for which colors are
* generated.
*/
{
// If h==1, we will probably get lots of "scanline" rects
}
return outRas;
}
int w, int h)
{
if (xrgbRasRef != null) {
xrgbRasRef = null;
return wr;
}
}
// If we are going to cache this Raster, make it non-tiny
if (w <= 32 && h <= 32) {
w = h = 32;
}
if (argbRasRef != null) {
argbRasRef = null;
return wr;
}
}
// If we are going to cache this Raster, make it non-tiny
if (w <= 32 && h <= 32) {
w = h = 32;
}
}
return srcRas.createCompatibleWritableRaster(w, h);
} else {
return cm.createCompatibleWritableRaster(w, h);
}
}
return;
}
}
}
int w, int h)
{
if (byteRasRef != null) {
byteRasRef = null;
return wr;
}
}
// If we are going to cache this Raster, make it non-tiny
if (w <= 32 && h <= 32) {
w = h = 32;
}
return srcRas.createCompatibleWritableRaster(w, h);
}
return;
}
}
int colincx, int colincxerr,
int colincy, int colincyerr,
int rowincx, int rowincxerr,
int rowincy, int rowincyerr);
/*
* Blends the four ARGB values in the rgbs array using the factors
* described by xmul and ymul in the following ratio:
*
* rgbs[0] * (1-xmul) * (1-ymul) +
* rgbs[1] * ( xmul) * (1-ymul) +
* rgbs[2] * (1-xmul) * ( ymul) +
* rgbs[3] * ( xmul) * ( ymul)
*
* xmul and ymul are integer values in the half-open range [0, 2^31)
* where 0 == 0.0 and 2^31 == 1.0.
*
* Note that since the range is half-open, the values are always
* logically less than 1.0. This makes sense because while choosing
* pixels to blend, when the error values reach 1.0 we move to the
* next pixel and reset them to 0.0.
*/
// shift them to 12 bits wide, (0 => 2^12-1)
for (int i = 0; i < 4; i++) {
// The complement of the [xy]mul values (1-[xy]mul) can result
// in new values in the range (1 => 2^12). Thus for any given
// loop iteration, the values could be anywhere in (0 => 2^12).
if ((i & 1) == 0) {
}
// xmul and ymul are each 12 bits (0 => 2^12)
// factor is thus 24 bits (0 => 2^24)
if (factor != 0) {
// accum variables will accumulate 32 bits
// bytes extracted from rgb fit in 8 bits (0 => 255)
// byte * factor thus fits in 32 bits (0 => 255 * 2^24)
}
}
}
int inData[];
int inOff;
int inSpan;
int outData[];
int outOff;
int outSpan;
boolean filter;
{
}
return ras;
}
int colincx, int colincxerr,
int colincy, int colincyerr,
int rowincx, int rowincxerr,
int rowincy, int rowincyerr) {
int rowx = x;
int rowy = y;
if (normalx) {
outSpan -= w;
}
for (int j = 0; j < h; j++) {
if (normalx) {
out += w;
if (bWidth >= 32) {
int i = w;
while (i > 0) {
int copyw = (i < x) ? i : x;
copyw);
i -= copyw;
if ((x -= copyw) == 0) {
x = bWidth;
}
}
} else {
for (int i = w; i > 0; i--) {
if (--x == 0) {
x = bWidth;
}
}
}
} else {
x = rowx;
y = rowy;
for (int i = 0; i < w; i++) {
if (filter) {
nextx = 0;
}
nexty = 0;
}
} else {
}
x++;
}
x -= bWidth;
}
y++;
}
y -= bHeight;
}
}
}
rowx++;
}
}
rowy++;
}
}
}
}
}
byte inData[];
int inOff;
int inSpan;
byte outData[];
int outOff;
int outSpan;
{
}
return ras;
}
public void dispose() {
}
int colincx, int colincxerr,
int colincy, int colincyerr,
int rowincx, int rowincxerr,
int rowincy, int rowincyerr) {
int rowx = x;
int rowy = y;
if (normalx) {
outSpan -= w;
}
for (int j = 0; j < h; j++) {
if (normalx) {
out += w;
if (bWidth >= 32) {
int i = w;
while (i > 0) {
int copyw = (i < x) ? i : x;
copyw);
i -= copyw;
if ((x -= copyw) == 0) {
x = bWidth;
}
}
} else {
for (int i = w; i > 0; i--) {
if (--x == 0) {
x = bWidth;
}
}
}
} else {
x = rowx;
y = rowy;
for (int i = 0; i < w; i++) {
x++;
}
x -= bWidth;
}
y++;
}
y -= bHeight;
}
}
}
rowx++;
}
}
rowy++;
}
}
}
}
}
int inPalette[];
byte inData[];
int inOff;
int inSpan;
int outData[];
int outOff;
int outSpan;
{
this.inPalette = new int[256];
}
// Note that we do not pass srcRas to makeRaster since it
// is a Byte Raster and this colorModel needs an Int Raster
return ras;
}
int colincx, int colincxerr,
int colincy, int colincyerr,
int rowincx, int rowincxerr,
int rowincy, int rowincyerr) {
int rowx = x;
int rowy = y;
int rgbs[] = new int[4];
for (int j = 0; j < h; j++) {
x = rowx;
y = rowy;
for (int i = 0; i < w; i++) {
nextx = 0;
}
nexty = 0;
}
inSpan * y]];
inSpan * y]];
x++;
}
x -= bWidth;
}
y++;
}
y -= bHeight;
}
}
rowx++;
}
}
rowy++;
}
}
}
}
}
boolean filter;
{
}
}
int colincx, int colincxerr,
int colincy, int colincyerr,
int rowincx, int rowincxerr,
int rowincy, int rowincyerr) {
int rowx = x;
int rowy = y;
for (int j = 0; j < h; j++) {
x = rowx;
y = rowy;
for (int i = 0; i < w; i++) {
if (filter) {
nextx = 0;
}
nexty = 0;
}
int rgb =
}
x++;
}
x -= bWidth;
}
y++;
}
y -= bHeight;
}
}
rowx++;
}
}
rowy++;
}
}
}
}
}
}