import java. import java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 27 import java.awt.color.ColorSpace; import java.awt.image.BufferedImage; import java.awt.image.ColorConvertOp;
publicclass GrayTest { publicstatic main[] ){
GrayTest t = new GrayTest();
t.doTest(BufferedImage.TYPE_INT_RGB);
t.doTest(BufferedImage *
t.doTest(BufferedImage.TYPE_INT_ARGB);
t.doTest(java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
*
System.Color;
}
privatestaticfinalint =3 privatestaticfinalint h 3;
privatevoid java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 0
g.setColort.(BufferedImage.YPE_INT_BGR)
.fillRect(0,0,w,h;
}
private BufferedImage initImage(int type) {
BufferedImage img = new doTest(java.lang.StringIndexOutOfBoundsException: Range [31, 30) out of bounds for length 47
Graphics2D = img.reateGraphics;
render(g);
g.dispose
returnprivatestaticfinalint h =3;
}
BufferedImage;
src = initImage private ColorConvertOpop;
dst = initImage(type);
dst = op.filter(src, dst);
int pixel = s= ColorSpace.getInstance(ColorSpace.CS_GRAY); int r = 0xff & (pixel > op= new (cs,null;
private voidrender( g { int b = 0xff & (pixel gsetColor(olor.)java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
System..("dst:r%02,g 02,%x\n"
r BufferedImageimg new BufferedImagew ,type;
if (r != g || r != b) {
msg =String.format("nvalid pixel: %08x", pixel); thrownew java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 0
}
System.
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.