src/share/classes/java/awt/image/LookupOp.java
Print this page
@@ -1,7 +1,8 @@
+
/*
- * Copyright (c) 1997, 2000, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
@@ -371,15 +372,15 @@
boolean hasAlpha = cm.hasAlpha();
boolean isPre = cm.isAlphaPremultiplied();
int trans = cm.getTransparency();
int[] nbits = null;
if (ltable instanceof ByteLookupTable) {
- if (db.getDataType() == db.TYPE_USHORT) {
+ if (db.getDataType() == DataBuffer.TYPE_USHORT) {
// Dst raster should be of type byte
if (hasAlpha) {
nbits = new int[2];
- if (trans == cm.BITMASK) {
+ if (trans == java.awt.Transparency.BITMASK) {
nbits[1] = 1;
}
else {
nbits[1] = 8;
}
@@ -391,14 +392,14 @@
}
// For byte, no need to change the cm
}
else if (ltable instanceof ShortLookupTable) {
transferType = DataBuffer.TYPE_USHORT;
- if (db.getDataType() == db.TYPE_BYTE) {
+ if (db.getDataType() == DataBuffer.TYPE_BYTE) {
if (hasAlpha) {
nbits = new int[2];
- if (trans == cm.BITMASK) {
+ if (trans == java.awt.Transparency.BITMASK) {
nbits[1] = 1;
}
else {
nbits[1] = 16;
}