src/share/classes/javax/imageio/ImageTypeSpecifier.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 2000, 2003, 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
--- 1,7 ----
/*
! * Copyright (c) 2000, 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
*** 294,304 ****
dataType != DataBuffer.TYPE_DOUBLE) {
throw new IllegalArgumentException
("Bad value for dataType!");
}
this.colorSpace = colorSpace;
! this.bandOffsets = (int[])bandOffsets.clone();
this.dataType = dataType;
this.hasAlpha = hasAlpha;
this.isAlphaPremultiplied = isAlphaPremultiplied;
this.colorModel =
--- 294,304 ----
dataType != DataBuffer.TYPE_DOUBLE) {
throw new IllegalArgumentException
("Bad value for dataType!");
}
this.colorSpace = colorSpace;
! this.bandOffsets = bandOffsets.clone();
this.dataType = dataType;
this.hasAlpha = hasAlpha;
this.isAlphaPremultiplied = isAlphaPremultiplied;
this.colorModel =
*** 447,458 ****
throw new IllegalArgumentException
("bandOffsets.length is wrong!");
}
this.colorSpace = colorSpace;
! this.bankIndices = (int[])bankIndices.clone();
! this.bandOffsets = (int[])bandOffsets.clone();
this.dataType = dataType;
this.hasAlpha = hasAlpha;
this.isAlphaPremultiplied = isAlphaPremultiplied;
this.colorModel =
--- 447,458 ----
throw new IllegalArgumentException
("bandOffsets.length is wrong!");
}
this.colorSpace = colorSpace;
! this.bankIndices = bankIndices.clone();
! this.bandOffsets = bandOffsets.clone();
this.dataType = dataType;
this.hasAlpha = hasAlpha;
this.isAlphaPremultiplied = isAlphaPremultiplied;
this.colorModel =
*** 767,781 ****
greenLUT.length != len ||
blueLUT.length != len ||
(alphaLUT != null && alphaLUT.length != len)) {
throw new IllegalArgumentException("LUT has improper length!");
}
! this.redLUT = (byte[])redLUT.clone();
! this.greenLUT = (byte[])greenLUT.clone();
! this.blueLUT = (byte[])blueLUT.clone();
if (alphaLUT != null) {
! this.alphaLUT = (byte[])alphaLUT.clone();
}
this.bits = bits;
this.dataType = dataType;
if (alphaLUT == null) {
--- 767,781 ----
greenLUT.length != len ||
blueLUT.length != len ||
(alphaLUT != null && alphaLUT.length != len)) {
throw new IllegalArgumentException("LUT has improper length!");
}
! this.redLUT = redLUT.clone();
! this.greenLUT = greenLUT.clone();
! this.blueLUT = blueLUT.clone();
if (alphaLUT != null) {
! this.alphaLUT = alphaLUT.clone();
}
this.bits = bits;
this.dataType = dataType;
if (alphaLUT == null) {